You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@activemq.apache.org by "jbertram (via GitHub)" <gi...@apache.org> on 2023/04/28 18:10:55 UTC

[GitHub] [activemq-artemis] jbertram opened a new pull request, #4460: ARTEMIS-4265 make more web console tabs conditional on permission

jbertram opened a new pull request, #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460

   Many of the tabs on the web console show up even though the user doesn't have permission to execute the command corresponding to the tab. For example the "Connections" tab shows up even though the user can't execute the `listConnections` management operation.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] brusdev commented on pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "brusdev (via GitHub)" <gi...@apache.org>.
brusdev commented on PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460#issuecomment-1532057589

   The change LGTM, are you planning to add any console smoke test, i.e. [QueuesTest](https://github.com/apache/activemq-artemis/blob/main/tests/smoke-tests/src/test/java/org/apache/activemq/artemis/tests/smoke/console/QueuesTest.java)?
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] brusdev commented on a diff in pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "brusdev (via GitHub)" <gi...@apache.org>.
brusdev commented on code in PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460#discussion_r1185840593


##########
tests/smoke-tests/src/test/java/org/apache/activemq/artemis/tests/smoke/console/QueuesTest.java:
##########
@@ -60,6 +62,89 @@ public void testDefaultQueues() throws Exception {
       assertEquals(0, queuesPage.getMessagesCount("ExpiryQueue"));
    }
 
+   @Test
+   public void testConnectionsTab() {

Review Comment:
   Nice tests but they don't seem related to queues, could you move them to a new test class, i.e. `TabsTest` or any other names?



##########
tests/smoke-tests/src/test/java/org/apache/activemq/artemis/tests/smoke/console/QueuesTest.java:
##########
@@ -60,6 +62,89 @@ public void testDefaultQueues() throws Exception {
       assertEquals(0, queuesPage.getMessagesCount("ExpiryQueue"));
    }
 
+   @Test
+   public void testConnectionsTab() {

Review Comment:
   Nice tests but they don't seem related to queues, could you move them to a new test class, i.e. `TabsTest` or any other names?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] jbertram commented on a diff in pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "jbertram (via GitHub)" <gi...@apache.org>.
jbertram commented on code in PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460#discussion_r1186377047


##########
tests/smoke-tests/src/test/java/org/apache/activemq/artemis/tests/smoke/console/QueuesTest.java:
##########
@@ -60,6 +62,89 @@ public void testDefaultQueues() throws Exception {
       assertEquals(0, queuesPage.getMessagesCount("ExpiryQueue"));
    }
 
+   @Test
+   public void testConnectionsTab() {

Review Comment:
   Done.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] brusdev merged pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "brusdev (via GitHub)" <gi...@apache.org>.
brusdev merged PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] jbertram commented on pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "jbertram (via GitHub)" <gi...@apache.org>.
jbertram commented on PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460#issuecomment-1535589912

   @brusdev, thanks for the tip! Tests added.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] jbertram commented on pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "jbertram (via GitHub)" <gi...@apache.org>.
jbertram commented on PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460#issuecomment-1533509949

   @brusdev, I wasn't aware of that class. Based on your comment I took a look, but I don't see how to customize the following files used by the broker:
    - `management.xml`
    - `artemis.profile`
    - `artemis-users.properties`
    - `artemis-roles.properties`
   
   I need to set up a handful of different users in unique roles with access to the console. Is this possible?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [activemq-artemis] brusdev commented on pull request #4460: ARTEMIS-4265 make more web console tabs conditional on permission

Posted by "brusdev (via GitHub)" <gi...@apache.org>.
brusdev commented on PR #4460:
URL: https://github.com/apache/activemq-artemis/pull/4460#issuecomment-1534190838

   @jbertram you could create the `console` folder with those files in the [servers](https://github.com/apache/activemq-artemis/tree/main/tests/smoke-tests/src/main/resources/servers) folder and add the `configuration` element to the `create-create-console` execution, i.e.
   https://github.com/apache/activemq-artemis/blob/main/tests/smoke-tests/pom.xml#L258
   ```
    <execution>
       <phase>test-compile</phase>
       <id>create-create-console</id>
       <goals>
          <goal>create</goal>
       </goals>
       <configuration>
          <configuration>${basedir}/target/classes/servers/console</configuration>
          ...
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org