3 Replies Latest reply on Jun 2, 2015 9:15 AM by travellerx

    Java property files

    emmanuel.lebeaupin

      Hi,

       

      I am a newbie about JBPM. So, sorry if my question is too obvious.

      I use kjar to deploy jbpm processes (with JBOSS EAP 6.3). I would like to use java external property files to store project configurations (for example, webservices hostname,...).

       

      Is it possible? Is JBPM included this functionnality? Should I modify jboss server classpath to include a new external folder and create a work item handler to handle it?

       

      Regards,

       

      Emmanuel

        • 1. Re: Java property files
          travellerx

          Which project configuration you want to save ?

           

           

          If you have workitemhandler, you can add the properties file in the same project classpath.

          You can use the server's classpath as well but would be helpful if you can explain bit more.

          • 2. Re: Java property files
            emmanuel.lebeaupin

            For example, I have created a workitemhandler to push messages via WebSocket.

            I would like configure socket server url into an external property file :

            server.socket.url =ws://localhost:1337

             

            I don't want add properties in the project because properties aren't the same according to the environment (development, production,...).

            • 3. Re: Java property files
              travellerx

              I haven't tried this before, but in your workitemhandler you can read System Properties which will point to the properties file & you can read it from there, that can be the solution, though might not be best.