-
Notifications
You must be signed in to change notification settings - Fork 10
Description
In #15 a set of typical HTTP response codes was documented, however, in working on the PHP functions framework we have found there's a lot that remains undefined in how errors should be handled.
GoogleCloudPlatform/functions-framework-php#60 demonstrates the only definition is triangulating against the behaviors of other functions frameworks, which include some behaviors in the name of backwards compatibility that are not intended as part of the functions framework specification.
Actual
Each language makes independent decisions around error handling, including:
- Handling the
X-Google-Status
custom HTTP header - What error message is returned in the body of the response
- Reliable use of error status codes in all edge cases
- Generation of a stack trace/integration with Error Reporting
Expected
Functions frameworks provide a consistent experience in surfacing errors such as HTTP Functions and CloudEvent Functions present a language agnostic programming paradigm for service-to-service communications.