Issue #159 Added support for binary data in request and response
Adds support for binary data in requests and responses. https://github.com/openfaas/templates/issues/159
Description
Added IResponse.setBody(byte[]), IResponse.getBodyData() and implemented them in Response Added IRequest.getInputStream() and implemented it in Request Changed entrypoint App to use these new methods.
Motivation and Context
https://github.com/openfaas/templates/issues/159
- [x] I have raised an issue to propose this change (required)
Which issue(s) this PR fixes
Fixes https://github.com/openfaas/templates/issues/159
How Has This Been Tested?
Added tests to RequestTest and ResponseTest. Verified that my original problem described in https://github.com/openfaas/templates/issues/159 is fixed.
Types of changes
- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
Checklist:
- [x] My code follows the code style of this project.
- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.
- [x] I've read the CONTRIBUTION guide
- [x] I have signed-off my commits with
git commit -s - [x] I have added tests to cover my changes.
- [x] All new and existing tests passed.
Thank you for your contribution. I've just checked and your commit doesn't appear to be signed-off. That's something we need before your Pull Request can be merged. Please see our contributing guide.
Tip: if you only have one commit so far then run: git commit --amend --signoff and then git push --force.
Please could you squash both commits into one? You should be able to get help from Google as this is a common practice. Failing that route, the community is active on Slack and always ready to help contributors.
Thank you for your PR
/msg: slack
-- Join Slack to connect with the community https://docs.openfaas.com/community
@erlendv please take a look at the comments and squash down your commits into one, when you are ready. This is a good change so I would like to get it in soon.
Sorry for late feedback @alexellis and @kameshchauhan. Im on vacation so a bit online/offline. I will fix shortly!
Thank you @erlendv - please could you sign-off your commits? If you need help, please ask on Slack.
Perhaps we can squash the 5 commits with git reset HEAD~5 and then add / commit them again?
I think I (finally) managed to squash the commits and have the one signed off @alexellis. All requested changes have been implemented.
@alexellis I think til PR is all good now? All requested changes have been done, all commits squashed and the one commit is signed off.