title: Set a basic Java option on Tomcat
body: <p>I need to add <code>-Dorg.apache.activemq.SERIALIZABLE_PACKAGES="*"</code> to my tomcat in my <code>catalina.bat</code> file</p>
  
  <pre><code>rem Register custom URL handlers
  rem Do this here so custom URL handles (specifically 'war:...') can be used in the security policy
  set "JAVA_OPTS=%JAVA_OPTS% -Djava.protocol.handler.pkgs=org.apache.catalina.webresources -Dorg.apache.activemq.SERIALIZABLE_PACKAGES=*"
  </code></pre>
  
  <p>But I'm still getting this error</p>
  
  <blockquote>
    <p>Caused by: java.lang.ClassNotFoundException: Forbidden class
    mypackage.Something! This class
    is not trusted to be serialized as ObjectMessage payload. Please take
    a look at <a href="http://activemq.apache.org/objectmessage.html" rel="nofollow noreferrer">http://activemq.apache.org/objectmessage.html</a> for more
    information on how to configure trusted classes.</p>
  </blockquote>
  
  <p><a href="https://i.stack.imgur.com/lqQVt.png" rel="nofollow noreferrer">If I set this property in the JVM Arguments on Eclipse Tomcat Server it works.</a></p>
  
  <p>So I'm guessing this is not setting the property.
  What's the problem?</p>
  
  <p>PS: I start tomcat with <code>catalina.bat run</code></p>