How can I know the version of the called service?

When canary release for aliases is enabled, the Function Compute system distributes traffic based on the specified weights. You can determine the version of the called service by using the following methods:
  • Check the log

    You can view the request for each function call in the configured log service. The isDarkLaunch field in the log indicates the canary release version that hits the current call. The externalServiceVersion field in the log indicates the specific service version used in the current call.

  • Check context parameters
    In each function call, among context parameters, the service parameter contains the qualifier and versionId fields.
    • qualifier: indicates the version information that is passed in when the function is called. It can be a version number or an alias.
    • versionId: indicates the specific version number that is parsed out based on the qualifier during function execution.
  • Check the response to a synchronous function call

    The response to a synchronous function call contains the x-fc-invocation-service-version header that indicates the version of the called service.