Extend EventData with AmqpAnnotatedMessage#22314
Extend EventData with AmqpAnnotatedMessage#22314conniey merged 39 commits intoAzure:mainfrom v-hongli1:issue#21717
Conversation
|
Thank you for your contribution hongli750210! We will review the pull request and get back to you soon. |
YijunXieMS
left a comment
There was a problem hiding this comment.
- EH EventData and SB Message have similar stuffs but also many different properties. We need to remove what is not need for EventData.
- The changes on the systemProperties looks pretty risky. Is it possible to keep existing stuffs and only expose new APIs?
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
This should be the message id. We're not exposing user id as a top-level property.
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...ssaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventHubMessageSerializer.java
Outdated
Show resolved
Hide resolved
…AnnotatedMessage by lihong 202106161337
…AmqpAnnotatedMessage by lihong 202106161625
…r issue#21717 Extend EventData with AmqpAnnotatedMessage by lihong 202106161656
…r issue#21717 Extend EventData with AmqpAnnotatedMessage by lihong 202106161801
…r issue#21717 Extend EventData with AmqpAnnotatedMessage by lihong 202106161820
…c) for issue#21717 Extend EventData with AmqpAnnotatedMessage by lihong 202106301016
…c) for issue#21717 Extend EventData with AmqpAnnotatedMessage by lihong 202106301030
|
This pull request is protected by Check Enforcer. What is Check Enforcer?Check Enforcer helps ensure all pull requests are covered by at least one check-run (typically an Azure Pipeline). When all check-runs associated with this pull request pass then Check Enforcer itself will pass. Why am I getting this message?You are getting this message because Check Enforcer did not detect any check-runs being associated with this pull request within five minutes. This may indicate that your pull request is not covered by any pipelines and so Check Enforcer is correctly blocking the pull request being merged. What should I do now?If the check-enforcer check-run is not passing and all other check-runs associated with this PR are passing (excluding license-cla) then you could try telling Check Enforcer to evaluate your pull request again. You can do this by adding a comment to this pull request as follows: What if I am onboarding a new service?Often, new services do not have validation pipelines associated with them, in order to bootstrap pipelines for a new service, you can issue the following command as a pull request comment: |
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...bs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventDataBatch.java
Outdated
Show resolved
Hide resolved
...ssaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventHubMessageSerializer.java
Outdated
Show resolved
Hide resolved
...ssaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventHubMessageSerializer.java
Outdated
Show resolved
Hide resolved
| */ | ||
| public EventData(byte[] body) { | ||
| this(BinaryData.fromBytes(Objects.requireNonNull(body, "'body' cannot be null."))); | ||
| this.systemProperties = new SystemProperties(); |
There was a problem hiding this comment.
Since AmqpAnnotatedMessage exposes byte[] as the body, I felt like it was best to store it as such rather than BinaryData that we were using before to stop a lot of the conversions to and from BinaryData.
There was a problem hiding this comment.
@conniey, @yijun: This looks like SystemProperties is a copy of data that also appears on the AmqpAnnotatedMessage instance. Since the AmqpAnnotatedMessage instance is fully mutable, if callers change the data there, then the EventData projection is no longer accurate and you've got drift....
Am I overlooking something?
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Outdated
Show resolved
Hide resolved
...enthubs/azure-messaging-eventhubs/src/main/java/com/azure/messaging/eventhubs/EventData.java
Show resolved
Hide resolved
|
/azp run java - eventhubs - tests |
|
Azure Pipelines successfully started running 1 pipeline(s). |
EventDatawithAmqpAnnotatedMessage#21717@jongio, @conniey for notification