[
https://issues.apache.org/jira/browse/BEAM-4182?focusedWorklogId=96412&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-96412
]
ASF GitHub Bot logged work on BEAM-4182:
----------------------------------------
Author: ASF GitHub Bot
Created on: 28/Apr/18 11:16
Start Date: 28/Apr/18 11:16
Worklog Time Spent: 10m
Work Description: jbonofre closed pull request #5238: BEAM-4182 fix to
allow JMSMessageId to be null
URL: https://github.com/apache/beam/pull/5238
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git
a/sdks/java/io/jms/src/main/java/org/apache/beam/sdk/io/jms/JmsRecord.java
b/sdks/java/io/jms/src/main/java/org/apache/beam/sdk/io/jms/JmsRecord.java
index 1c3b3b380d9..7e59ccd1164 100644
--- a/sdks/java/io/jms/src/main/java/org/apache/beam/sdk/io/jms/JmsRecord.java
+++ b/sdks/java/io/jms/src/main/java/org/apache/beam/sdk/io/jms/JmsRecord.java
@@ -29,7 +29,7 @@
*/
public class JmsRecord implements Serializable {
- private final String jmsMessageID;
+ @Nullable private final String jmsMessageID;
private final long jmsTimestamp;
private final String jmsCorrelationID;
@Nullable private final Destination jmsReplyTo;
@@ -43,7 +43,7 @@
private final String text;
public JmsRecord(
- String jmsMessageID,
+ @Nullable String jmsMessageID,
long jmsTimestamp,
String jmsCorrelationID,
@Nullable Destination jmsReplyTo,
@@ -137,8 +137,7 @@ public int hashCode() {
public boolean equals(Object obj) {
if (obj instanceof JmsRecord) {
JmsRecord other = (JmsRecord) obj;
- return jmsMessageID.equals(other.jmsMessageID)
- && jmsDestination.equals(other.jmsDestination)
+ return jmsDestination.equals(other.jmsDestination)
&& jmsDeliveryMode == other.jmsDeliveryMode
&& jmsRedelivered == other.jmsRedelivered
&& jmsExpiration == other.jmsExpiration
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 96412)
Time Spent: 0.5h (was: 20m)
> JMSMessageID can be null
> ------------------------
>
> Key: BEAM-4182
> URL: https://issues.apache.org/jira/browse/BEAM-4182
> Project: Beam
> Issue Type: Bug
> Components: io-java-jms
> Affects Versions: 2.4.0
> Reporter: Matthias Weßendorf
> Assignee: Jean-Baptiste Onofré
> Priority: Major
> Time Spent: 0.5h
> Remaining Estimate: 0h
>
> JMSRecord asssumes the JMSMessageID to be not null, but spec says:
>
> {quote}
> Message header field references are restricted to JMSDeliveryMode,
> JMSPriority, JMSMessageID, JMSTimestamp, JMSCorrelationID, and
> JMSType. JMSMessageID, JMSCorrelationID, and JMSType values may be
> null and if so are treated as a NULL value.
> {quote}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)