[
https://issues.apache.org/jira/browse/QPID-8706?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18021181#comment-18021181
]
Robert Godfrey commented on QPID-8706:
--------------------------------------
Firstly - apologies I didn't get notified to your response to my comment.
Personally I prefer organising the constants in a way that reflects the
organisation of the AMQP specification itself or (where Qpid specific) a
separate QpidSpecificAMQPSymbols file ... if we want code clarity then we can
then define everything in interfaces and have a AMQPSymbolDefinitions that
extends all the other interface files. Something like
{code:java}
private static final Symbol NOT_VALID_BEFORE =
Symbol.valueOf("x-qpid-not-valid-before");
{code}
doesn't feel like it should live in the same file as
{code:java}
Symbol ANONYMOUS_RELAY = Symbol.valueOf("ANONYMOUS-RELAY");
{code}
... as an aside
{code:java}
public static final String ANNOTATION_KEY = "x-opt-jms-msg-type";
{code}
just seems wrong.
Again, I don't massively object, but it just seems a change which doesn't
reflect how AMQP works, and makes a single file which will need to be changed
based on updates to any level of the spec, or various Qpid specific
functionality
> [Broker-J] Move AMQP-1.0 symbols declarations to a utility class
> ----------------------------------------------------------------
>
> Key: QPID-8706
> URL: https://issues.apache.org/jira/browse/QPID-8706
> Project: Qpid
> Issue Type: Improvement
> Components: Broker-J
> Affects Versions: qpid-java-broker-9.2.1
> Reporter: Daniil Kirilyuk
> Priority: Minor
> Fix For: qpid-java-broker-10.0.0
>
>
> Currently in qpid-broker-plugins-amqp-1-0-protocol all Symbol instance are
> created via Symbol.valueOf(). Although they are cached internally, to improve
> the code readability it would be beneficial to move all constant Symbols to
> the utility class as public static final constants.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]