[jboss-jira] [JBoss JIRA] (WFLY-10884) Quickstart jaxrs-jwt should use the "jboss.server.config.dir" system property for the file path to jwt.keystore

Masafumi Miura (JIRA) issues at jboss.org
Fri Aug 17 17:09:00 EDT 2018


Masafumi Miura created WFLY-10884:
-------------------------------------

             Summary: Quickstart jaxrs-jwt should use the "jboss.server.config.dir" system property for the file path to jwt.keystore
                 Key: WFLY-10884
                 URL: https://issues.jboss.org/browse/WFLY-10884
             Project: WildFly
          Issue Type: Bug
          Components: Quickstarts
    Affects Versions: 13.0.0.Final
            Reporter: Masafumi Miura
            Assignee: Eduardo Martins


Quickstart jaxrs-jwt should use the "jboss.server.config.dir" system property for the file path to jwt.keystore.

We can not expect ../standalone/configuration/jwt.keystore is always a valid path for jwt.keystore because the process current directory can be changed to any other location than $JBOSS_HOME/bin when standalone.sh is invoked from other location. 

For example, when you start WildFly by executing ./bin/standalone.sh under $JBOSS_HOME directory, the request fails with the following FileNotFoundException:

{code}
19:15:57,579 ERROR [stderr] (default task-1) java.io.FileNotFoundException: ../standalone/configuration/jwt.keystore (No such file or directory)
19:15:57,581 ERROR [stderr] (default task-1) 	at java.io.FileInputStream.open0(Native Method)
19:15:57,581 ERROR [stderr] (default task-1) 	at java.io.FileInputStream.open(FileInputStream.java:195)
19:15:57,581 ERROR [stderr] (default task-1) 	at java.io.FileInputStream.<init>(FileInputStream.java:138)
19:15:57,582 ERROR [stderr] (default task-1) 	at java.io.FileInputStream.<init>(FileInputStream.java:93)
19:15:57,582 ERROR [stderr] (default task-1) 	at org.jboss.quickstarts.jaxrsjwt.auth.JwtManager.<clinit>(JwtManager.java:46)
19:15:57,583 ERROR [stderr] (default task-1) 	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
19:15:57,583 ERROR [stderr] (default task-1) 	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
19:15:57,583 ERROR [stderr] (default task-1) 	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
19:15:57,584 ERROR [stderr] (default task-1) 	at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
19:15:57,584 ERROR [stderr] (default task-1) 	at java.lang.Class.newInstance(Class.java:442)
19:15:57,585 ERROR [stderr] (default task-1) 	at org.jboss.weld.bean.proxy.DefaultProxyInstantiator.newInstance(DefaultProxyInstantiator.java:43)
19:15:57,586 ERROR [stderr] (default task-1) 	at org.jboss.weld.bean.proxy.ProxyFactory.run(ProxyFactory.java:359)
19:15:57,586 ERROR [stderr] (default task-1) 	at org.jboss.weld.bean.proxy.ProxyFactory.create(ProxyFactory.java:343)
19:15:57,586 ERROR [stderr] (default task-1) 	at org.jboss.weld.bean.proxy.ClientProxyFactory.create(ClientProxyFactory.java:81)
19:15:57,587 ERROR [stderr] (default task-1) 	at org.jboss.weld.bean.proxy.ClientProxyProvider.createClientProxy(ClientProxyProvider.java:206)
....
{code}



--
This message was sent by Atlassian JIRA
(v7.5.0#75005)


More information about the jboss-jira mailing list