QPID-8368: [Broker-J] Restore graylog profile to address the review comments
diff --git a/apache-qpid-broker-j/src/main/assembly/dependency-verification/DEPENDENCIES_REFERENCE b/apache-qpid-broker-j/src/main/assembly/dependency-verification/DEPENDENCIES_REFERENCE
index 7ba93c0..e5cd01f 100644
--- a/apache-qpid-broker-j/src/main/assembly/dependency-verification/DEPENDENCIES_REFERENCE
+++ b/apache-qpid-broker-j/src/main/assembly/dependency-verification/DEPENDENCIES_REFERENCE
@@ -99,8 +99,6 @@
     License: Apache License, Version 2.0  (https://www.apache.org/licenses/LICENSE-2.0.txt)
   - Apache Qpid Broker-J Derby Message Store Plug-in (http://qpid.apache.org/components/broker-plugins/qpid-broker-plugins-derby-store) org.apache.qpid:qpid-broker-plugins-derby-store:jar
     License: Apache License, Version 2.0  (https://www.apache.org/licenses/LICENSE-2.0.txt)
-  - Apache Qpid Broker-J LogBack GrayLog Logging Plug-in (http://qpid.apache.org/components/broker-plugins/qpid-broker-plugins-graylog-logging-logback) org.apache.qpid:qpid-broker-plugins-graylog-logging-logback:jar
-    License: Apache License, Version 2.0  (https://www.apache.org/licenses/LICENSE-2.0.txt)
   - Apache Qpid Broker-J LogBack JDBC Logging Plug-in (http://qpid.apache.org/components/broker-plugins/qpid-broker-plugins-jdbc-logging-logback) org.apache.qpid:qpid-broker-plugins-jdbc-logging-logback:jar
     License: Apache License, Version 2.0  (https://www.apache.org/licenses/LICENSE-2.0.txt)
   - Apache Qpid Broker-J JDBC Message Store Connection Pooling Plug-in (http://qpid.apache.org/components/broker-plugins/qpid-broker-plugins-jdbc-provider-bone) org.apache.qpid:qpid-broker-plugins-jdbc-provider-bone:jar
diff --git a/broker/pom.xml b/broker/pom.xml
index 0d06449..3ec8a4e 100644
--- a/broker/pom.xml
+++ b/broker/pom.xml
@@ -157,12 +157,6 @@
       <scope>runtime</scope>
     </dependency>
 
-    <dependency>
-      <groupId>org.apache.qpid</groupId>
-      <artifactId>qpid-broker-plugins-graylog-logging-logback</artifactId>
-      <scope>runtime</scope>
-    </dependency>
-
     <!-- test dependencies -->
     <dependency>
       <groupId>org.apache.qpid</groupId>
@@ -171,4 +165,23 @@
     </dependency>
   </dependencies>
 
+  <profiles>
+    <profile>
+      <id>graylog</id>
+      <activation>
+        <property>
+          <name>graylog</name>
+        </property>
+      </activation>
+
+      <dependencies>
+        <dependency>
+          <groupId>org.apache.qpid</groupId>
+          <artifactId>qpid-broker-plugins-graylog-logging-logback</artifactId>
+          <scope>runtime</scope>
+        </dependency>
+      </dependencies>
+    </profile>
+  </profiles>
+
 </project>
diff --git a/pom.xml b/pom.xml
index 522a7a2..785a444 100644
--- a/pom.xml
+++ b/pom.xml
@@ -97,6 +97,7 @@
     <profile.broker.clean.between.tests>true</profile.broker.clean.between.tests>
     <profile.test_receive_timeout>1000</profile.test_receive_timeout>
     <profile.qpid.tests.mms.messagestore.persistence>true</profile.qpid.tests.mms.messagestore.persistence>
+    <profile.virtualhostnode.context.blueprint>{"type":"ProvidedStore","globalAddressDomains":"${dollar.sign}{qpid.globalAddressDomains}"}</profile.virtualhostnode.context.blueprint>
 
     <dollar.sign>$</dollar.sign>
     <at.sign>@</at.sign>
@@ -175,7 +176,6 @@
     <module>broker-plugins/jdbc-provider-bone</module>
     <module>broker-plugins/jdbc-store</module>
     <module>broker-plugins/jdbc-logging-logback</module>
-    <module>broker-plugins/graylog-logging-logback</module>
     <module>broker-plugins/logging-logback</module>
     <module>broker-plugins/management-amqp</module>
     <module>broker-plugins/management-http</module>
@@ -361,12 +361,6 @@
 
       <dependency>
         <groupId>org.apache.qpid</groupId>
-        <artifactId>qpid-broker-plugins-graylog-logging-logback</artifactId>
-        <version>${project.version}</version>
-      </dependency>
-
-      <dependency>
-        <groupId>org.apache.qpid</groupId>
         <artifactId>qpid-broker-plugins-memory-store</artifactId>
         <version>${project.version}</version>
       </dependency>
@@ -828,12 +822,6 @@
         <version>${bcpkix-version}</version>
       </dependency>
 
-      <dependency>
-        <groupId>de.siegmar</groupId>
-        <artifactId>logback-gelf</artifactId>
-        <version>${logback-gelf-version}</version>
-      </dependency>
-
     </dependencies>
   </dependencyManagement>
 
@@ -1640,6 +1628,35 @@
       </build>
     </profile>
 
+    <profile>
+      <id>graylog</id>
+      <activation>
+        <property>
+          <name>graylog</name>
+        </property>
+      </activation>
+
+      <modules>
+        <module>broker-plugins/graylog-logging-logback</module>
+      </modules>
+
+      <dependencyManagement>
+        <dependencies>
+          <dependency>
+            <groupId>de.siegmar</groupId>
+            <artifactId>logback-gelf</artifactId>
+            <version>${logback-gelf-version}</version>
+          </dependency>
+          <dependency>
+            <groupId>org.apache.qpid</groupId>
+            <artifactId>qpid-broker-plugins-graylog-logging-logback</artifactId>
+            <version>${project.version}</version>
+          </dependency>
+        </dependencies>
+      </dependencyManagement>
+
+    </profile>
+
   </profiles>
 </project>