Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
feat: bulksubscribe http #478
base: main
Are you sure you want to change the base?
feat: bulksubscribe http #478
Changes from 10 commits
3f5bcd8
1c45f4e
2193f47
5d4e498
f19a505
fdd425a
cb26d03
597c099
10d2c67
e218130
5131387
81b72ef
203d31c
068ef1c
36b78f5
38bc154
35c37bc
fb4138a
0b41a28
d05856f
92e7eef
f315c9e
0f2d9bb
f4a3b65
3577081
5e1f64d
de720d9
05f3ad7
300e5ac
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
nit: break this comment up so it doesn't wrap/exceed a reasonable character count (~140ish)
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.
As my previous review - the validation of arguments passed to these parameters should be implemented as per the implementation spec. I do think that this is something we need to address both sdk-side and in the runtime explicitly as part of best practice.
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.
what default values you suggest if nil values are given?
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.
Error-out if either are
X <= 0
this would prevent a negative value, a nil value is not possible for the int type.Check warning on line 43 in service/grpc/topic.go
Codecov / codecov/patch
service/grpc/topic.go#L40-L43
Check warning on line 45 in service/grpc/topic.go
Codecov / codecov/patch
service/grpc/topic.go#L45
Check warning on line 93 in service/grpc/topic.go
Codecov / codecov/patch
service/grpc/topic.go#L89-L93
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.
Please reuse the type provided
go-sdk/service/common/type.go
Lines 106 to 113 in de720d9
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.
A string value type should be 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.
Move these to
go-sdk/service/common/type.go
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.
Likewise with the grpc implementation I would like to see validation of the
maxMessagesCount
andmaxAwaitDurationMs
paramsThere 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.
This exported function should have a comment quickly outlining the use
Check warning on line 353 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L351-L353
Check warning on line 374 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L372-L374
Check warning on line 380 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L378-L380
Check warning on line 386 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L385-L386
Check warning on line 422 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L411-L422
Check warning on line 431 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L429-L431
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.
There is no unhandled error at this point, could you clarify that if a single event is dropped it will be replayed/retried at a later date?
Check warning on line 451 in service/http/topic.go
Codecov / codecov/patch
service/http/topic.go#L450-L451
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.
It's fine to create a new function as it is manifestly different or is idiomatic, do you think this is better or would it be better to pass the slice to your function as an argument and wrap it within the function?