Project

General

Profile

« Previous | Next » 

Revision 6ebe6843

Added by Andreas Kohlbecker over 8 years ago

datasources.xml file is now configurable, the eclipse launcher expects now ~/.cdmLibrary/datasources-cdm-server.xml

View differences:

ide/eclipse/cdm-server - start.launch
13 13
<listEntry value="org.eclipse.debug.ui.launchGroup.run"/>
14 14
</listAttribute>
15 15
<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="eu.etaxonomy.cdm.server.Bootloader"/>
16
<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-webapp=${workspace_loc:cdmlib-remote-webapp/src/main/webapp/}&#10;-webappClasspath=${project_classpath:cdmlib-remote-webapp}&#13;&#10;-jmx"/>
16
<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-webapp=${workspace_loc:cdmlib-remote-webapp/src/main/webapp/}&#10;-webappClasspath=${project_classpath:cdmlib-remote-webapp}&#10;-datasources=${system_property:user.home}/.cdmLibrary/datasources-cdm-server.xml&#13;&#10;-jmx"/>
17 17
<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="cdm-server"/>
18 18
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Xmx1200M&#13;&#10;&#13;&#10;-XX:PermSize=128m &#13;&#10;-XX:MaxPermSize=390m&#13;&#10;&#13;&#10;-XX:+UseConcMarkSweepGC &#13;&#10;-XX:+CMSClassUnloadingEnabled &#13;&#10;-XX:+CMSPermGenSweepingEnabled&#13;&#10;&#13;&#10;-Dorg.eclipse.jetty.util.log.DEBUG=false&#13;&#10;&#13;&#10;-Dcom.sun.management.jmxremote.ssl=false&#13;&#10;-Dcom.sun.management.jmxremote.authenticate=false&#13;&#10;-Dcom.sun.management.jmxremote.port=9999"/>
19 19
</launchConfiguration>
src/main/java/eu/etaxonomy/cdm/server/Bootloader.java
319 319
        }
320 320

  
321 321
         if(cmdLine.hasOption(DATASOURCES_FILE.getOpt())){
322
             logger.error(DATASOURCES_FILE.getOpt() + " NOT JET IMPLEMENTED!!!");
322
             File datasourcesFile = new File(cmdLine.getOptionValue(DATASOURCES_FILE.getOpt()));
323
             if(datasourcesFile.canRead()) {
324
                instanceManager.setDatasourcesFile(datasourcesFile);
325
            } else {
326
                logger.error("File set as " + DATASOURCES_FILE.getOpt()
327
                        + " (" + cmdLine.getOptionValue(DATASOURCES_FILE.getOpt())
328
                        + ") is not readable.");
329
            }
323 330
         }
324 331

  
325 332
        verifySystemResources();
src/main/java/eu/etaxonomy/cdm/server/instance/InstanceManager.java
42 42

  
43 43
    boolean serverIsRunning = false;
44 44

  
45
    private final File datasourcesFile;
45
    private File datasourcesFile;
46

  
47
    /**
48
     * @return the datasourcesFile
49
     */
50
    public File getDatasourcesFile() {
51
        return datasourcesFile;
52
    }
53

  
54
    /**
55
     * @param datasourcesFile the datasourcesFile to set
56
     */
57
    public void setDatasourcesFile(File datasourcesFile) {
58
        this.datasourcesFile = datasourcesFile;
59
    }
60

  
46 61
    private ListOrderedMap instances = new ListOrderedMap();
47 62

  
48 63
    private final boolean austostart = true;

Also available in: Unified diff