This is an automated email from the ASF dual-hosted git repository.

jbertram pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git


The following commit(s) were added to refs/heads/main by this push:
     new ea06621  ARTEMIS-3510 enhance detailed view of property 
JMS_AMQP_ORIGINAL_ENCODING
     new e879ac1  This closes #3781
ea06621 is described below

commit ea06621f3f96630951a9f32cd6c943fc476ce369
Author: Erwin Dondorp <[email protected]>
AuthorDate: Fri Oct 1 09:56:54 2021 +0200

    ARTEMIS-3510 enhance detailed view of property JMS_AMQP_ORIGINAL_ENCODING
---
 .../src/main/webapp/plugin/js/components/browse.js          | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git 
a/artemis-hawtio/artemis-plugin/src/main/webapp/plugin/js/components/browse.js 
b/artemis-hawtio/artemis-plugin/src/main/webapp/plugin/js/components/browse.js
index 4874e8c..404659c 100644
--- 
a/artemis-hawtio/artemis-plugin/src/main/webapp/plugin/js/components/browse.js
+++ 
b/artemis-hawtio/artemis-plugin/src/main/webapp/plugin/js/components/browse.js
@@ -804,6 +804,16 @@ var Artemis;
         }
 
 
+        var amqpEncodingLabels = [
+                       "amqp-unknown", "amqp-null", "amqp-data", 
"amqp-sequence", "amqp-value-null",
+                       "amqp-value-string", "amqp-value-binary", 
"amqp-value-map", "amqp-value-list"];
+        function formatAmqpEncoding(enc) {
+            if (isNaN(enc)) {
+                return enc;
+            }
+            return enc > -1 && enc < 9 ? amqpEncodingLabels[enc] : enc;
+        }
+
         function createProperties(message) {
             var properties = [];
             angular.forEach(message, function (value, key) {
@@ -811,6 +821,9 @@ var Artemis;
                     Artemis.log.debug("key=" + key + " value=" + value);
                     angular.forEach(value, function (v2, k2) {
                     Artemis.log.debug("key=" + k2 + " value=" + v2);
+                                               if(k2 === 
"JMS_AMQP_ORIGINAL_ENCODING") {
+                                                       v2 += " (" + 
formatAmqpEncoding(v2) + ")";
+                                               }
                         properties.push({key: k2, value: v2});
                     });
                 }

Reply via email to