-
Notifications
You must be signed in to change notification settings - Fork 4
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 producer implementation. #49
Conversation
@@ -148,6 +148,10 @@ tasks.withType(JacocoReport).configureEach { | |||
getExecutionData().from(fileTree(buildDir).include("/jacoco/*.exec")) | |||
} | |||
|
|||
tasks.withType(Copy).configureEach { |
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.
why is this required?
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.
gradle/gradle#17236
Moved it to ProcessResource task and WARN strategy for Pulsar module alone.
common/src/main/java/com/flipkart/varadhi/exceptions/MessagingException.java
Show resolved
Hide resolved
entities/src/main/java/com/flipkart/varadhi/entities/CapacityPolicy.java
Show resolved
Hide resolved
entities/src/main/java/com/flipkart/varadhi/entities/Message.java
Outdated
Show resolved
Hide resolved
pulsar/src/main/java/com/flipkart/varadhi/pulsar/entities/PulsarProducer.java
Outdated
Show resolved
Hide resolved
pulsar/src/main/java/com/flipkart/varadhi/pulsar/entities/PulsarProducer.java
Outdated
Show resolved
Hide resolved
pulsar/src/main/java/com/flipkart/varadhi/pulsar/entities/PulsarProducer.java
Show resolved
Hide resolved
return 0; | ||
if (null == o) { | ||
throw new ArgumentException("Can not compare null ProducerResult."); | ||
} | ||
if (o instanceof PulsarProducerResult) { | ||
return messageId.compareTo(((PulsarProducerResult) o).messageId); | ||
} else { | ||
throw new ArgumentException(String.format( | ||
"Can not compare different ProducerResult types. Expected ProducerResult is %s, given %s.", | ||
PulsarProducerResult.class.getName(), o.getClass().getName() | ||
)); | ||
} |
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.
auto-generated?
Also, there is no requirement for ProduceResult to be comparable. Is there?
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.
U mean ProduceResult or ProducerResult ?
For former comparable is not required as it is more then message offset. Renamed this class to be Offset and PulsarOffset, however retained the Comparable for Offset.
TODO:: will add tests after first review.