Skip to content
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

pulsar connector accepts auth params #22028

Closed
wants to merge 2 commits into from
Closed

Conversation

nlu90
Copy link
Member

@nlu90 nlu90 commented Jun 23, 2022

Please add a meaningful description for your change here


Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

  • Choose reviewer(s) and mention them in a comment (R: @username).
  • Mention the appropriate issue in your description (for example: addresses #123), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, comment fixes #<ISSUE NUMBER> instead.
  • Update CHANGES.md with noteworthy changes.
  • If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.

To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md

GitHub Actions Tests Status (on master branch)

Build python source distribution and wheels
Python tests
Java tests

See CI.md for more information about GitHub Actions CI.

@asf-ci
Copy link

asf-ci commented Jun 23, 2022

Can one of the admins verify this patch?

4 similar comments
@asf-ci
Copy link

asf-ci commented Jun 23, 2022

Can one of the admins verify this patch?

@asf-ci
Copy link

asf-ci commented Jun 23, 2022

Can one of the admins verify this patch?

@asf-ci
Copy link

asf-ci commented Jun 23, 2022

Can one of the admins verify this patch?

@asf-ci
Copy link

asf-ci commented Jun 23, 2022

Can one of the admins verify this patch?

Copy link
Contributor

@johnjcasey johnjcasey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we handle bad auth in pulsar correctly? i.e. if we pass nulls to a pulsar that requires auth, or pass auth to a pulsar that doesn't?

this.pulsarClientSerializableFunction = transform.getPulsarClient();
}

// Open connection to Pulsar clients
@Setup
// TODO add auth related
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is TODO here?

@MarcoRob
Copy link
Contributor

MarcoRob commented Jun 24, 2022

Do we handle bad auth in pulsar correctly? i.e. if we pass nulls to a pulsar that requires auth, or pass auth to a pulsar that doesn't?

I don't think it is being handled the bad auth scenario but we could add a pre-validation for the auth like in SpannerIO to validate if contains the correct parameters.

Copy link
Contributor

@aromanenko-dev aromanenko-dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I left a couple of comments

public static PulsarSourceDescriptor of(
String topic,
Long startOffsetTimestamp,
Long endOffsetTimestamp,
MessageId endMessageId,
String clientUrl,
String adminUrl) {
String adminUrl,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is a public method then it would be better to provide another an overloaded method with the same name and additional arguments.

If this class and method are not supposed to be used by user then it should be private or package private to avoid potential breaking changes like this.

@@ -77,7 +77,7 @@ public void testInitialRestrictionWhenHasStartOffset() throws Exception {
OffsetRange result =
dofnInstance.getInitialRestriction(
PulsarSourceDescriptor.of(
TOPIC, expectedStartOffset, null, null, SERVICE_URL, ADMIN_URL));
TOPIC, expectedStartOffset, null, null, SERVICE_URL, ADMIN_URL, null, null));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please, add the tests with non-null auth values.

@robertwb
Copy link
Contributor

What is the status of this PR?

@github-actions
Copy link
Contributor

This pull request has been marked as stale due to 60 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the [email protected] list. Thank you for your contributions.

@github-actions github-actions bot added the stale label Jan 30, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Mar 2, 2023

This pull request has been closed due to lack of activity. If you think that is incorrect, or the pull request requires review, you can revive the PR at any time.

@hpvd
Copy link

hpvd commented Apr 24, 2024

added this to [Parent issue] Support for Apache Pulsar #31078

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants