title: Embedded Glassfish and `imqcmd`
body: <p>We are using an embedded Glassfish Server in our testing environment. We use the <code>org.glassfish.embeddable.CommandRunner</code> interface to execute administrative tasks (i.e., what we do with <code>asadmin</code> with a standard standalone Glassfish server)</p>
  
  <p>Example:</p>
  
  <pre><code>GlassFish glassfish = GlassFishRuntime.bootstrap( bp ).newGlassFish( gfp );
  CommandRunner commandRunner = glassfish.getService( CommandRunner.class );
  commandRunner.run(
    "create-jms-resource",
    "--restype",
    "javax.jms.Queue",
    "SOME_QUEUE_NAME"
  );
  </code></pre>
  
  <p>Now on the command line I am able to set queue options with <code>imqcmd</code>. For example</p>
  
  <pre><code>imqcmd -u admin -passfile ../password.txt update dst -n SOME_QUEUE_NAME -t q -o maxBytesPerMsg=-1 -f
  </code></pre>
  
  <p>Is there a way to achieve the same with an embedded Glassfish server?</p>