-
Notifications
You must be signed in to change notification settings - Fork 600
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
Expose dispatch result to be used by other implementations #5481
Expose dispatch result to be used by other implementations #5481
Conversation
/assign @matzew , I need this as well kind of missed it. |
Err error | ||
Info *channel.DispatchExecutionInfo |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer if you create getters for these two: Err()
and Info()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done added a New.. func and getters, keeping it immutable for now (no setters) as it is a result that should not change.
func (d DispatchResult) GetDispatchResultError() error { | ||
return d.err | ||
} | ||
|
||
func (d DispatchResult) GetDispatchResultInfo() *channel.DispatchExecutionInfo { | ||
return d.info | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Too verbose :) just Info and Err are fine
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok :P
The following is the coverage report on the affected files.
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: skonto, slinkydeveloper The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Codecov Report
@@ Coverage Diff @@
## main #5481 +/- ##
==========================================
- Coverage 82.78% 82.71% -0.07%
==========================================
Files 197 197
Lines 6093 6098 +5
==========================================
Hits 5044 5044
- Misses 724 729 +5
Partials 325 325
Continue to review full report at Codecov.
|
…venting-kafka (#1311) * make eventing metrics generic * Expose dispatch result to be used by other implementations (knative#5481) * expose dispatch result to be used by other implementations * expose fields * add getters etc * less verbose
…ka (#1318) * make eventing metrics generic (knative#5478) * Expose dispatch result to be used by other implementations (knative#5481) * expose dispatch result to be used by other implementations * expose fields * add getters etc * less verbose * Use transformers efficiently for extracting info for metrics in Kafka Channel (knative#5505) * use transformers for extracting event type for metrics * fix * fix * pass transformers to executeRequest (knative#5512)
Proposed Changes
Expose the dispatch result info struct to be able to be used externally.
Pre-review Checklist
Not applicable.