-
Notifications
You must be signed in to change notification settings - Fork 5.4k
Closed
Labels
Milestone
Description
We intentionally do not set file version information for apphost and singlefilehost, since they represent the user's application. With apphost, we can still see the version and commit hashes in traces - for example:
--- Invoked apphost [version: 7.0.0, commit hash: d099f075e45d2aa6007a22b71b45a08758559f80] main = {
--- Invoked hostfxr_main_startupinfo [commit hash: d037e070ebe5c83838443f869d5800752b0fcb13]
--- Invoked hostpolicy [commit hash: d037e070ebe5c83838443f869d5800752b0fcb13] [runtime.win-x64.Microsoft.NETCore.DotNetHostPolicy,7.0.2,runtimes/win-x64/native][x64] corehost_main = {
For singlefilehost, we explicitly set this information to static:
runtime/src/native/corehost/setup.cmake
Lines 4 to 14 in ff12237
| if(CLR_SINGLE_FILE_HOST_ONLY) | |
| # CLR partition builds only the single file host where hosting components are all statically linked. | |
| # the versioning information is irrelevant and may only come up in tracing. | |
| # so we will use "static" | |
| add_definitions(-DHOST_POLICY_PKG_VER="static") | |
| add_definitions(-DHOST_FXR_PKG_VER="static") | |
| add_definitions(-DHOST_PKG_VER="static") | |
| add_definitions(-DCOMMON_HOST_PKG_VER="static") | |
| add_definitions(-DHOST_POLICY_PKG_NAME="static") | |
| add_definitions(-DHOST_POLICY_PKG_REL_DIR="static") | |
| add_definitions(-DREPO_COMMIT_HASH="static") |
So all we have is:
--- Invoked apphost [version: static, commit hash: static] main = {
--- Invoked hostfxr_main_bundle_startupinfo [commit hash: static]
--- Invoked hostpolicy [commit hash: static] [static,static,static][x64] corehost_main = {
There doesn't seem to be any reasonable way to get at the version of the host is running. It is probably worth having a real value for at least either the version or commit so we can better understand what is being used when customers hit issues.
Reactions are currently unavailable