[ 
https://issues.apache.org/jira/browse/ARTEMIS-5266?focusedWorklogId=954464&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-954464
 ]

ASF GitHub Bot logged work on ARTEMIS-5266:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 29/Jan/25 15:51
            Start Date: 29/Jan/25 15:51
    Worklog Time Spent: 10m 
      Work Description: gemmellr commented on code in PR #5477:
URL: https://github.com/apache/activemq-artemis/pull/5477#discussion_r1934142984


##########
artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/Message.java:
##########
@@ -507,8 +507,8 @@ default byte[] getDuplicateIDBytes() {
       if (duplicateID == null) {
          return null;
       } else {
-         if (duplicateID instanceof SimpleString) {
-            return ((SimpleString) duplicateID).getData();
+         if (duplicateID instanceof SimpleString string) {
+            return string.getData();

Review Comment:
   ```suggestion
            if (duplicateID instanceof SimpleString simpleString) {
               return simpleString.getData();
   ```





Issue Time Tracking
-------------------

    Worklog Id:     (was: 954464)
    Time Spent: 1.5h  (was: 1h 20m)

> Code gardening after move to Java 17
> ------------------------------------
>
>                 Key: ARTEMIS-5266
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-5266
>             Project: ActiveMQ Artemis
>          Issue Type: Task
>            Reporter: Justin Bertram
>            Assignee: Justin Bertram
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> With the recent move to Java 17 now is a good time to do some code gardening 
> to leverage new language features (e.g. text blocks) and deal with old issue 
> (e.g. unused variables, etc.).



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@activemq.apache.org
For additional commands, e-mail: issues-h...@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact


Reply via email to