[Serverless] add isError flag to channelMessage
What does this PR do?
This PR adds IsError field to the ChannelMessage structure.
Before all message were set with status info but in some case, we want to tag message as error right away, for instance if we know that these are coming from stderr
Motivation
Set the correct level in message
Describe how to test/QA your changes
Unit test
Reviewer's Checklist
- [ ] If known, an appropriate milestone has been selected; otherwise the
Triagemilestone is set. - [ ] Use the
major_changelabel if your change either has a major impact on the code base, is impacting multiple teams or is changing important well-established internals of the Agent. This label will be use during QA to make sure each team pay extra attention to the changed behavior. For any customer facing change use a releasenote. - [ ] A release note has been added or the
changelog/no-changeloglabel has been applied. - [ ] Changed code has automated tests for its functionality.
- [ ] Adequate QA/testing plan information is provided if the
qa/skip-qalabel is not applied. - [ ] At least one
team/..label has been applied, indicating the team(s) that should QA this change. - [ ] If applicable, docs team has been notified or an issue has been opened on the documentation repo.
- [ ] If applicable, the
need-change/operatorandneed-change/helmlabels have been applied. - [ ] If applicable, the
k8s/<min-version>label, indicating the lowest Kubernetes version compatible with this feature. - [ ] If applicable, the config template has been updated.
Would it make sense to instead expose the full status field, so that any of the available levels can be set?
Would it make sense to instead expose the full
statusfield, so that any of the available levels can be set?
Sure! I can do the modification, the only downside of that is we could pass invalid status such as 'blablabla' WDYT?
Good point! If there is no foreseeable need for more status options, what you have now in the PR might be better.