The return status code should be returned along with the body message.
Current Behaviour
The return 'statusCode' is currently seems to be completely ignored when using curl on an OpenFaas function endpoint. There doesn't seem to be a mechanism to retrieve the statusCode (maybe I'm missing something in the documentation).
Modify one of the template handler.py return status codes to be something other than 200 (e.g. 500)
build, push, deploy a container using the template modified
execute the function and check the return status
Context
I'm a graduate student working on a masters capstone comparing performance and cost of cloud native applications running with open sourced software to proprietary solutions from cloud vendors.
Your Environment
FaaS-CLI version ( Full output from: faas-cli version ):
* Code example or link to GitHub repo or gist to reproduce problem:
* Other diagnostic information / logs from [troubleshooting guide](https://docs.openfaas.com/deployment/troubleshooting)
My actions before raising this issue
Expected Behaviour
The return status code should be returned along with the body message.
Current Behaviour
The return 'statusCode' is currently seems to be completely ignored when using curl on an OpenFaas function endpoint. There doesn't seem to be a mechanism to retrieve the statusCode (maybe I'm missing something in the documentation).
Possible Solution
Include the status code in the return body so it can be parsed by end users. As suggested here, https://github.com/openfaas/faas-netes/issues/147#issuecomment-367953472
i.e. in handler.py
Steps to Reproduce (for bugs)
Context
I'm a graduate student working on a masters capstone comparing performance and cost of cloud native applications running with open sourced software to proprietary solutions from cloud vendors.
Your Environment
faas-cli version
):CLI: commit: 0074051aeb837f5f160ee8736341460468b5c190 version: 0.15.4
Client: Docker Engine - Community Version: 20.10.21
NAME="Ubuntu" VERSION="20.04.5 LTS (Focal Fossa)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 20.04.5 LTS" VERSION_ID="20.04" HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" VERSION_CODENAME=focal UBUNTU_CODENAME=focal