Ignore:
Timestamp:
Jan 12, 2011, 9:45:08 PM (9 years ago)
Author:
robert@…
Message:

Externalized configuration; improved assay view (detail views of runs and samples); implemented uploading and parsing of FASTA and QUAL files

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

    • Property svn:ignore
      •  

        old new  
        44.classpath
        55.project
         6fileuploads
  • trunk/grails-app/conf/Config.groovy

    r2 r3  
     1// ##################################################################################
     2// DO NOT Change these settings!!!
     3// You can overwrite them by adding your own configuration file in ~/.grails/[environment]-[appName].properties
     4
    15// locations to search for config files that get merged into the main config
    26// config files can either be Java properties files or ConfigSlurper scripts
     7grails.config.locations = [
     8        // the default per-environment configuration
     9        // (e.g. grails-app/conf/config-development.properties)
     10        "classpath:config-${grails.util.GrailsUtil.environment}.properties",
     11        "file:${ basedir }/grails-app/conf/config-${grails.util.GrailsUtil.environment}.properties",
     12        "classpath:config-${grails.util.GrailsUtil.environment}.groovy",
     13       
     14        // the external configuration to override the default
     15        // configuration (e.g. ~/.grails-config/ci-gscf.properties)
     16        "file:${userHome}/.grails-config/${grails.util.GrailsUtil.environment}-${appName}.properties",
     17        "file:${userHome}/.grails-config/${grails.util.GrailsUtil.environment}-${appName}.groovy",
     18        "file:${userHome}/.grails/${grails.util.GrailsUtil.environment}-${appName}.properties",
     19        "file:${userHome}/.grails/${grails.util.GrailsUtil.environment}-${appName}.groovy"
     20]
    321
    4 // grails.config.locations = [ "classpath:${appName}-config.properties",
    5 //                             "classpath:${appName}-config.groovy",
    6 //                             "file:${userHome}/.grails/${appName}-config.properties",
    7 //                             "file:${userHome}/.grails/${appName}-config.groovy"]
     22// Add extra location if desired
     23if(System.properties["${appName}.config.location"]) {
     24        grails.config.locations << "file:" + System.properties["${appName}.config.location"]
     25}
    826
    9 // if(System.properties["${appName}.config.location"]) {
    10 //    grails.config.locations << "file:" + System.properties["${appName}.config.location"]
    11 // }
     27// Whether to synchronize with gscf or not. By default, synchronization is turned on
     28metagenomics.synchronization = true
     29
     30// By default, Metagenomics only fetches studies that have been changed by GSCF. GSCF sends
     31// notifications to the module, when something changes. However, it is possible that these messages
     32// can't be delivered or some other error happens. In that case, the data in the module is out of sync.
     33// To prevent that, every now and then a complete synchronization is performed. The frequency of this
     34// operation can be set by the following parameter. The parameter determines the number of seconds
     35// between two consecutive full synchronizations. Setting it to zero disables full synchronization, but
     36// is strongly discouraged.
     37metagenomics.fullSynchronization = 24 * 3600 // 1 day
     38
     39// Temporary directory to upload files to.
     40// If the directory is given relative (e.g. 'fileuploads/temp'), it is taken relative to the web-app directory
     41// Otherwise, it should be given as an absolute path (e.g. '/home/user/sequences')
     42// The directory should be writable by the webserver user
     43metagenomics.fileUploadDir = "filuploads/temp"
     44
     45// Maximum age that uploaded files should be kept on the server before deleting them. When a user uploads a file,
     46// but doesn't process the file (e.g. because he leaves the page beforehand or his computer crashes), the files
     47// remain in the upload directory. This mechanism ensures that the upload directory is cleaned after some time.
     48// The time is given in seconds.
     49metagenomics.fileUploadMaxAge = 2 * 24 * 3600 // 2 days
     50
     51// Directory to save the uploaded files permanently
     52// If the directory is given relative (e.g. 'fileuploads/temp'), it is taken relative to the web-app directory
     53// Otherwise, it should be given as an absolute path (e.g. '/home/user/sequences')
     54// The directory should be writable by the webserver user
     55metagenomics.fileDir = "fileuploads/permanent"
     56
     57// Path in GSCF that is used after baseURL for adding a new study
     58gscf.addStudyPath = "/studyWizard/index?jump=create"
    1259
    1360grails.project.groupId = appName // change this to alter the default package name and Maven publishing destination
     
    3582grails.views.gsp.encoding = "UTF-8"
    3683grails.converters.encoding = "UTF-8"
     84
    3785// enable Sitemesh preprocessing of GSP pages
    3886grails.views.gsp.sitemesh.preprocess = true
    39 // scaffolding templates configuration
    40 grails.scaffolding.templates.domainSuffix = 'Instance'
    4187
    4288// Set to false to use the new Grails 1.2 JSONBuilder in the render method
    4389grails.json.legacy.builder = false
     90
    4491// enabled native2ascii conversion of i18n properties files
    4592grails.enable.native2ascii = true
     93
    4694// whether to install the java.util.logging bridge for sl4j. Disable for AppEngine!
    4795grails.logging.jul.usebridge = true
     96
    4897// packages to include in Spring bean scanning
    4998grails.spring.bean.packages = []
    50 
    51 // ##################################################################################
    52 // DO NOT Change these settings!!!
    53 // You can overwrite them by adding a /grails-app/conf/LocalConfig.groovy.
    54 // Use /grails-app/conf/_LocalConfig.groovy as an example!
    55 // Make sure to set SVN to ignore this file!
    56 
    57 // Whether to synchronize with gscf or not. By default, synchronization is turned on
    58 metagenomics.synchronization = true
    59 
    60 // Temporary directory to upload files to.
    61 // If the directory is given relative (e.g. 'fileuploads/temp'), it is taken relative to the web-app directory
    62 // Otherwise, it should be given as an absolute path (e.g. '/home/user/sequences')
    63 // The directory should be writable by the webserver user
    64 metagenomics.fileUploadDir = "fileuploads"
    65 
    66 // Maximum age that uploaded files should be kept on the server before deleting them. When a user uploads a file,
    67 // but doesn't process the file (e.g. because he leaves the page beforehand or his computer crashes), the files
    68 // remain in the upload directory. This mechanism ensures that the upload directory is cleaned after some time.
    69 // The time is given in seconds.
    70 metagenomics.fileUploadMaxAge = 2 * 24 * 3600
    71 
    72 // Directory to save the uploaded files permanently
    73 // If the directory is given relative (e.g. 'fileuploads/temp'), it is taken relative to the web-app directory
    74 // Otherwise, it should be given as an absolute path (e.g. '/home/user/sequences')
    75 // The directory should be writable by the webserver user
    76 metagenomics.fileDir = "/home/robert/projects/grails/metagenomics/sequences"
    77 
    78 // Path in GSCF that is used after baseURL for adding a new study
    79 gscf.addStudyPath = "/studyWizard/index?jump=create"
    80 
    81 environments { // set per-environment serverURL stem for creating absolute links
    82         development {
    83                 //development Environment (German Server)
    84                 grails.serverURL = "http://localhost:8184"
    85 
    86                 gscf.baseURL = "http://localhost:8080/gscf"
    87                 //gscf.baseURL = "http://ci.gscf.nmcdsp.org"
    88                 metagenomics.baseURL = "http://localhost:8184/metagenomics"
    89                 metagenomics.consumerID = metagenomics.baseURL
    90 
    91                 // Turn off synchronization in development mode
    92                 metagenomics.synchronization = true
    93         }
    94         ci {
    95                 //CI Environment (German Server)
    96                 grails.serverURL = "http://ci.metagenomics.nmcdsp.org"
    97                 gscf.baseURL = "http://ci.gscf.nmcdsp.org"
    98                 metagenomics.baseURL = "http://ci.metagenomics.nmcdsp.org"
    99                 metagenomics.consumerID = metagenomics.baseURL
    100         }
    101         test {
    102                 //Test Environment (German Server)
    103                 grails.serverURL = "http://test.gscf.nmcdsp.org"
    104                 gscf.baseURL = "http://test.gscf.nmcdsp.org"
    105                 metagenomics.baseURL = "http://test.metagenomics.nmcdsp.org"
    106                 metagenomics.consumerID = metagenomics.baseURL
    107         }
    108         nbx14 {
    109                 // nbx14 instance
    110                 grails.serverURL = "http://nbx14.osx.eu"
    111                 gscf.baseURL = "http://nbx14.osx.eu"
    112                 metagenomics.baseURL = "http://metagenomics.nbx14.osx.eu"
    113                 metagenomics.consumerID = metagenomics.baseURL
    114         }
    115         demo {
    116                 // demo instance
    117                 grails.serverURL = "http://demo.nbx14.osx.eu"
    118                 gscf.baseURL = "http://demo.nbx14.osx.eu"
    119                 metagenomics.baseURL = "http://demo.metagenomics.nbx14.osx.eu"
    120                 metagenomics.consumerID = metagenomics.baseURL
    121         }
    122         production {
    123                 //Production Environment (German Server)
    124                 grails.serverURL = "http://www.nmcdsp.org"
    125                 gscf.baseURL = "http://www.nmcdsp.org"
    126                 metagenomics.baseURL = "http://metagenomics.nmcdsp.org"
    127                 metagenomics.consumerID = metagenomics.baseURL
    128         }
    129         www {
    130                 //Production Environment used in deploy scripts (German Server)
    131                 grails.serverURL = "http://metagenomics.nmcdsp.org"
    132                 gscf.baseURL = "http://www.nmcdsp.org"
    133                 metagenomics.baseURL = "http://metagenomics.nmcdsp.org"
    134                 metagenomics.consumerID = metagenomics.baseURL
    135         }
    136 }
    137 // ##################################################################################
    138 
    13999
    140100// log4j configuration
     
    167127grails.views.javascript.library = "jquery"
    168128jquery.version = '1.4.4'
    169 
    170 // Include local config to overwrite defaults
    171 def localConfigFile = "${System.properties['base.dir']}/grails-app/conf/LocalConfig.groovy"
    172 
    173 if (new File(localConfigFile)?.canRead()) {
    174         grails.config.locations << "file:${localConfigFile}"
    175 }
Note: See TracChangeset for help on using the changeset viewer.