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

Implement comparable on EventData #395

Merged
merged 3 commits into from Dec 21, 2018

Conversation

Projects
None yet
2 participants
@Fokko
Copy link
Contributor

Fokko commented Nov 9, 2018

Description

I would like to implement the Comparable interface, so we can easily sort the messages based on the sequence.

This will give us the possibility to just use .sort, instead of implementing .sortWith:
https://github.com/Azure/azure-event-hubs-spark/blob/7ceae44f3bfe61575d24c94fe0749a70eeccbc11/core/src/main/scala/org/apache/spark/eventhubs/client/CachedEventHubsReceiver.scala#L137-L138

This checklist is used to make sure that common guidelines for a pull request are followed.

  • I have read the contribution guidelines.
  • Title of the pull request is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR.
  • The pull request does not introduce breaking changes (unless a major version change occurs in the assembly and module).
  • If applicable, the public code is properly documented.
  • Pull request includes test coverage for the included changes.
  • The code builds without any errors.

@Fokko Fokko force-pushed the Fokko:fd-add-comparable branch 2 times, most recently from b8109fc to fe8c518 Nov 9, 2018

@Fokko

This comment has been minimized.

Copy link
Contributor

Fokko commented Dec 13, 2018

PTAL @sjkwak

@Fokko Fokko force-pushed the Fokko:fd-add-comparable branch from fe8c518 to d948a4a Dec 20, 2018

@Fokko

This comment has been minimized.

Copy link
Contributor

Fokko commented Dec 20, 2018

Thanks @sjkwak I've reworked the PR

@sjkwak

sjkwak approved these changes Dec 20, 2018

@sjkwak sjkwak merged commit 9d04a98 into Azure:dev Dec 21, 2018

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
license/cla All CLA requirements met.
Details

sjkwak added a commit that referenced this pull request Jan 4, 2019

Release client 2.0.0 and EPH 2.2.0 (#416)
* Update Apache Proton-J dependency (0.29.0 --> 0.31.0) (#407)

* PartitionReceiver - add a method that provides an EventPosition which corresponds to an EventData returned last by the receiver (#408)

* Support IsPartitionEmpty property for PartitionRuntimeInformation (#399)

* Move setPrefetchCount API to the ReceiverOptions class from the PartitionReceiver and update the settings of Default & Max Prefetch count (#410)

This pull request includes two major changes related to Prefetch API.

1) Move setPrefetchCount API to the ReceiverOptions class so that prefetch value specified by a user can be used instead of using default value when communicating to the service during link open and initializing a receiver. This change also addresses the receiver stuck issue caused by setPrefetchAPI in a race condition.

2) Change the default value and set the upper bound of the prefetch count. Note that prefetch count should be greater than or equal to maxEventCount which can be set when either a) calling receive() API or b) implementing the getMaxEventCount API of the SessionReceiverHandler interface.

* Fixes several issues in the reactor related components (#411)

This pull request contains the following changes.

1) Finish pending tasks when recreating the reactor and make sure pending calls scheduled on the old reactor get complete.
2) Fix the session open timeout issue which can result in NPE in proton-J engine.
3) Make session open timeout configurable and use the value of OperationTimeout.
4) Update the message of exceptions and include an entity name in the exception message.
5) API change - use ScheduledExecutorService.
6) Improve tracing.

* Implement comparable on EventData (#395)

* Update receive/send link creation logic and improve tracing (#414)

* Prep for releasing client 2.0.0 and EPH 2.2.0 (#415)

@Fokko Fokko deleted the Fokko:fd-add-comparable branch Jan 11, 2019

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