-
Notifications
You must be signed in to change notification settings - Fork 889
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issues with FaaS semantic conventions (too AWS-specific, faas.id/version unclear) #1778
Comments
@skonto might have some input too |
I think faas attributes are generally meant to be supportive - faas is an execution model not anything quite semantic in itself. So it means almost all spans generated by faas will be primarily covered by http, rpc, or messaging conventions. Even for those that don't there is overlap with the code namespace. Looking at use cases, the big one that comes to mind is measuring cold vs warm start time. I think that is the intent of the instance / execution attributes. That being said, perhaps host or process conventions can actually help cover this without needing additional conventions may simplify things. If anything seems too cloud specific we should definitely consider moving to cloud provider namespaces, and if nothing happens to be left the faas namespace may not be that necessary.For example,
|
There is also the |
The goal of FaaS aka "serverless" is to hide away the server, so it should not semantically matter which host the function runs on. On the other hand, new semantic concepts like that of the "function" (with a name, possibly revisions, ...) is introduced. So I would say, it has to be something semantic otherwise we are not able meaningfully group monitored function invocations, e.g. by "function". |
Providing some more context, regarding Google Cloud Functions I see that there are at least four attributes when deploying (same for Cloud run):
Maybe a combination of the above attributes could be used as the id here, it seems that these define a func uniquely (same for Azure). Execution ids are a separate thing as expected.
Check this answer for Azure (the api version could be linked to faas there) and the link above for Cloud functions. Regarding the I think what is missing here to move the work to GA and post-GA, is a doc mapping the faas specification to each provider's implementation (Azure, AWS, Google Cloud). Could be also put directly into the spec as examples.If a vendor does not provide some attribute it is fine as long as spans and metrics make sense and are unambiguous. Also, there are non cloud offerings that run functions on-premise to be considered eg. OCP functions. |
I created PR #1781 that should address some of the points. |
Probably this issue should be closed and a follow-up could be opened to have somebody with actual knowledge of Google Cloud Platform or Azure take another look. |
The current FaaS conventions were developed with AWS Lambda in mind and have several issues. All in all, I think they are not GA-ready yet (good thing all semantic conventions are still experimental). At least some of
should also be well-supported by them (except if someone knows that the market share of one of them insignificant?), or they should be moved to an
aws
(sub-)namespace.Some issues:
faas.id
attribute is very nice but it is not clear to me how it applies to other providers. The current note on what to use for Azure (FunctionDirectory) seems wrong, we probably want something like https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/resource-name-rules#microsoftweb. For Google Cloud, there seems to be https://cloud.google.com/iam/docs/full-resource-names though I couldn't find how function IDs in particular would look like.faas.id
,faas.version
andfaas.invoked_id
is not very clear, if you consider that you can call an AWS Lambda by invokingarn:aws:lambda:us-east-1:12345:function:somefunction:somealias
which may invoke the function versionarn:aws:lambda:us-east-1:12345:function:somefunction:12
. Probablyfaas.invoked_id
at the client side should contain the ARN ending in:somefunction:somealias
, but what shouldfaas.id
contain? And wouldn't it be nice to have thefaas.invoked_arn
also on the server side? Note that the function name including alias cannot be used asfaas.id
since the same running instance could be invoked with multiple aliases andfaas.id
is a resource attribute, so there can only be one.CC:
The text was updated successfully, but these errors were encountered: