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

[BEAM-716] Use AutoValue in JmsIO #1577

Closed
wants to merge 3 commits into from
Closed

Conversation

jbonofre
Copy link
Member

Be sure to do all of the following to help us incorporate your contribution
quickly and easily:

  • Make sure the PR title is formatted like:
    [BEAM-<Jira issue #>] Description of pull request
  • Make sure tests pass via mvn clean verify. (Even better, enable
    Travis-CI on your fork and ensure the whole test matrix passes).
  • Replace <Jira issue #> in the title with the actual Jira issue
    number, if there is one.
  • If this contribution is large, please file an Apache
    Individual Contributor License Agreement.

@jbonofre
Copy link
Member Author

R: @lukecwik
CC: @davorbonaci

@asfbot
Copy link

asfbot commented Dec 11, 2016

@davorbonaci
Copy link
Member

From me, this is LGTM, but I know @jkff is the AutoValue "police", so I'd optionally let him take a peek if he wants to.

R: @jkff

Copy link
Contributor

@jkff jkff left a comment

Choose a reason for hiding this comment

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

Neat, thanks! (my requests to Read transform extend to Write - other than that, LGTM)

@AutoValue
public abstract static class Read extends PTransform<PBegin, PCollection<JmsRecord>> {

/**
Copy link
Contributor

Choose a reason for hiding this comment

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

Makes more sense to put javadoc on the publicly visible members - in this case, withBlah() methods

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, good idea.

}

return input.getPipeline().apply(transform);
}

@Override
public void validate(PBegin input) {
checkNotNull(connectionFactory, "ConnectionFactory not specified");
checkArgument((queue != null || topic != null), "Either queue or topic not specified");
checkNotNull(getConnectionFactory(), "ConnectionFactory not specified");
Copy link
Contributor

Choose a reason for hiding this comment

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

Might as well to fix these error messages to be in line with those you have in MqttIO etc?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yup, I planed to do this in a separate PR but it makes sense to do it in this one.

Copy link
Member Author

Choose a reason for hiding this comment

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

FYI, I planned to do this as part of BEAM-959 (PR related to this Jira).

@asfbot
Copy link

asfbot commented Dec 13, 2016

Refer to this link for build results (access rights to CI server needed):
https://builds.apache.org/job/beam_PreCommit_Java_MavenInstall/5849/
--none--

@jbonofre
Copy link
Member Author

Rebased

@asfbot
Copy link

asfbot commented Dec 14, 2016

Refer to this link for build results (access rights to CI server needed):
https://builds.apache.org/job/beam_PreCommit_Java_MavenInstall/5898/
--none--

@jbonofre
Copy link
Member Author

@davorbonaci @jkff do you mind to take a last review and LGTM if good ? I will merge as soon as you give my the green light.

@davorbonaci
Copy link
Member

Huge LGTM from me.

I think the title of the PR is selling it short. There's plenty of other improvements here, such as Javadoc documentation, other cleanup, etc.

Thanks @jbonofre!

@jbonofre
Copy link
Member Author

Thanks ! Merging.

@asfgit asfgit closed this in 1e148cd Dec 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants