Uploaded image for project: 'XWork'
  1. XWork
  2. XW-949

dynamic setting of xwork home directory (path to xwork.xml)

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • Configuration
    • None

    Description

      Hello,
      I'm using xwork for a swing application. I would like to put my xwork configuration files out of the classpath.
      Currently I've done the following 'dirty hack':
      1. added system property to vm start parameters: -Dxwork.home=conf/system/
      2. modified XmlConfigurationProvider in com.opensymphony.xwork.config.providers

      try {
      String xworkHome = System.getProperty("xwork.home");
      System.out.println(xworkHome);
      if (xworkHome!=null)

      { //is = getInputStream(xworkHome+fileName); is = new FileInputStream(xworkHome+fileName); }

      else

      { is = getInputStream(fileName); }

      ...

      Or am I missing something and this feature is already present?
      I read in the Manning's book that classpath is the only place you can put it.

      Attachments

        Activity

          People

            Unassigned Unassigned
            vitaly Vitaly Gordon
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: