3 Replies Latest reply on Mar 21, 2007 7:05 AM by dishmael

    AMF RPC Config

    dishmael Level 1
      I've got my AMF service configurations in a file called 'service-config.xml' which I load during compile time using -services "service-config.xml". Inside the file, I have one destination and three channels (one for each server the app gets deployed onto) configured.

      <service-config>
      <services>
      <service ...>
      <destination id="test">
      <channels>
      <channel ref="testChannel"/>
      </channels>
      <properties><source>*</source></properties>
      </destination>
      </service>
      </services>
      <channels>
      <channel-definition id="testChannel" .../>
      <channel-definition id="test2" .../>
      <channel-definition id="test3" .../>
      </channels>
      </services-config>

      Things work great with the first channel (test); however on the other servers (test2 and test3) I modify the service-config.xml and then I have to recompile.

      So here's my question...

      Is there a way to use the service-config.xml file so that its not part of the compilation process so that I can make changes to the config file on the fly? Maybe I'm not using it correctly or if someone knows a better way...
        • 1. Re: AMF RPC Config
          dishmael Level 1
          anyone??
          • 2. Re: AMF RPC Config
            yggdraa
            as far as i understand you cant change configs on the fly
            (at least when using Tomcat you should restart your webapp to make changes work)
            not sure if i clearly understood your question, tho
            • 3. Re: AMF RPC Config
              dishmael Level 1
              Hrm ... well, right now I have a service-config.xml file that has all the service endpoints. The application exists in a development environment and two production environments (one of which is a failover). The application uses the service-config.xml file during compilation time which means I can't change the destination on each environment. Here's what I have to do now:

              1. Modify the service-config.xml file for the primary production environment
              2 Re-compile the application
              3. Deploy the application to the primary production environment
              4. Modify the service-config.xml file for the backup production environment
              5. Re-compile the application
              6. Deploy the application to the backup production environment
              7. Modify the service-config.xml file
              8. Re-compile the applicaiton
              9. Continue working on the application in the development environment

              If I can modify the service-config.xml file without rebuilding, that would make life much easier. So my question is:

              Question: Can I use a service-config.xml file without including it in the compile time arguments? Is there a better way to define services so that I can change an endpoint without recompiling?