KafkaSinkTaskPut method improvement, pasrsingMessageKeyfield type specified as Array. #1
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.
Type Of PR
Improving readability of KafkaSinkTask class code
Change
I created these two private methods to be used in the relevant class.
In Korean
한국어 버전
Type Of PR
KafkaSinkTask 클래스 코드의 가독성 향상
Change
KafkaSinkTaskPut
클래스의 put 메서드를 보시면 samplingEnabled를 검사 후 true, false인 경우 두 가지에 if문에서 같은 records를 순외하며 조건을 보고 sendRecord를 할지 말지 정했는데 이러한 검증 부분에 대한 가독성을 향상시키기 위해 한 순회에서 검증을 마치도록 수정했습니다.다음과 같은 두 가지의 private 메서드를 만들었습니다. 관련 클래스에서 활용하도록 수정했습니다.