Uploaded image for project: 'ActiveMQ Artemis'
  1. ActiveMQ Artemis
  2. ARTEMIS-3485

Custom web context path doesn't work

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 2.19.0
    • None
    • None

    Description

      I am trying to expose the web console at https://companyhostname/artemis. Basically i want the context of the web console to start with /artemis. I changed my bootstrap.xml as follow:
      <broker xmlns="http://activemq.org/schema">
      <jaas-security domain="activemq"/>
      <server configuration="file:/C:/Users/nle/ActiveMQ/mybroker2/etc//broker.xml"/>

      <web bind="http://0.0.0.0:8161" path="web">
      <app url="artemis/activemq-branding" war="activemq-branding.war"/>
      <app url="artemis/artemis-plugin" war="artemis-plugin.war"/>
      <app url="artemis/console" war="console.war"/>
      </web>
      </broker>

      Running this on localhost for testing, when I hit
      http://localhost:8161/artemis/console/
      I got redirected to the login screen which means the context of the console app has been prefixed with /artemis correctly.
      However, i see that all the css from artemis-branding and js from artemis-plugin are missing and the request for artemisPlugin.js does not start with /artemis as i set in my bootstrap.xml. I believe the cause of this is from the return of the http://localhost:8161/artemis/console/plugin (io.hawt.web.plugin.PluginServlet):

      {
         "artemis-plugin":{
            "Context":"\/artemis-plugin",
            "Scripts":[
               "plugin\/js\/artemisHelpers.js",
               "plugin\/js\/artemisPlugin.js",
               "plugin\/js\/components\/addressSendMessage.js",
               "plugin\/js\/components\/addresses.js",
               "plugin\/js\/components\/browse.js",
               "plugin\/js\/components\/connections.js",
               "plugin\/js\/components\/consumers.js",
               "plugin\/js\/components\/createAddress.js",
               "plugin\/js\/components\/createQueue.js",
               "plugin\/js\/components\/deleteAddress.js",
               "plugin\/js\/components\/deleteQueue.js",
               "plugin\/js\/components\/diagram.js",
               "plugin\/js\/components\/help.js",
               "plugin\/js\/components\/navigation.js",
               "plugin\/js\/components\/preferences.js",
               "plugin\/js\/components\/producers.js",
               "plugin\/js\/components\/queues.js",
               "plugin\/js\/components\/sendMessage.js",
               "plugin\/js\/components\/sessions.js",
               "plugin\/js\/components\/status.js",
               "plugin\/js\/components\/tree.js",
               "plugin\/js\/services\/pagination.js",
               "plugin\/js\/services\/resource.js",
               "plugin\/js\/services\/sendMessageService.js",
               "plugin\/js\/services\/toolbar.js"
            ],
            "Domain":null,
            "Name":"artemis-plugin"
         },
         "activemq-branding":{
            "Context":"\/activemq-branding",
            "Scripts":[
               "plugin\/js\/brandingPlugin.js"
            ],
            "Domain":null,
            "Name":"activemq-branding"
         }
      }
      

      I think there is some script that reads this json and issues the resource requests but it does not seem to take into account the context i put in the bootstrap.xml.

      Attachments

        Activity

          People

            brusdev Domenico Francesco Bruscino
            brusdev Domenico Francesco Bruscino
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 40m
                40m