{"_id":"563735d24dbdd919001b26bd","project":"56000f0d8c0c9d0d00dcad21","githubsync":"","category":{"_id":"562d68d5d38b650d0044472a","project":"56000f0d8c0c9d0d00dcad21","__v":5,"version":"56000f0e8c0c9d0d00dcad24","pages":["562d904026a0a10d00ad6c30","56398e44a19edf0d009721a7","5639e5bad25e8919005f3e6a","563a30e3a19edf0d009722e6","563bf349d8f2d20d00448b39"],"sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-10-25T23:42:13.718Z","from_sync":false,"order":1,"slug":"getting-started","title":"Getting Started"},"user":"5600910981a9670d006d144f","__v":26,"version":{"_id":"56000f0e8c0c9d0d00dcad24","project":"56000f0d8c0c9d0d00dcad21","__v":13,"createdAt":"2015-09-21T14:07:10.176Z","releaseDate":"2015-09-21T14:07:10.176Z","categories":["56000f0e8c0c9d0d00dcad25","56008f2497f69f1700f21a36","560091601503430d007cc936","560e0d8054af2b0d005bbe92","560e3ce7ad6b200d00ff471c","560e3cf2c4e4ae0d00b42ed1","561c81d0e822e12b00e1fe00","561c81e9e822e12b00e1fe01","561c823d20b4a92b007d5147","56257f8951bf1c0d001f660a","562d5f165bd25e0d0054dbd4","562d68d5d38b650d0044472a","56421aebb0dc090d00f88438"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1.0"},"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-11-02T10:07:14.055Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":1,"body":"[block:callout]\n{\n  \"type\": \"warning\",\n  \"title\": \"Draft Documentation\"\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Space.configuration\"\n}\n[/block]\nAllows centralised global configuration the Space environment\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n // testMode: ['SPACE_TESTMODE', false, 'bool']\\n  sysLog : {\\n    enabled: ['SPACE_SYSLOG_ENABLED', false, 'bool']\\n  },\\n  appLog : {\\n    enabled: ['SPACE_APPLOG_ENABLED', false, 'bool']\\n  }\\n}\",\n      \"language\": \"javascript\"\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Module.configuration (Application)\"\n}\n[/block]\nSome Runtime Configuration can be set using Environment Variables, which are specified below as an array value. Options yet to be implemented have been commented out.\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"Configuration: {\\n  jobQueue: {\\n    mongoUrl: ['SPACE_JQ_MONGO_URL', '', 'string'],\\n    mongoOplogUrl: ['SPACE_JQ_MONGO_OPLOG_URL', '', 'string']\\n    collectionName: ['SPACE_JQ_COLLECTION_NAME', 'space_jobQueue', 'string']\\n  }\\n  eventSourcing: {\\n    log: {\\n      enabled: ['SPACE_ES_LOG_ENABLED', false, 'bool']\\n    }\\n    commits: {\\n      processingTimeout: ['SPACE_ES_COMMITS_PROCESSING_TIMEOUT', 1000, 'int']\\n    }\\n    snapshotting: {\\n      enabled: ['SPACE_ES_SNAPSHOTTING_ENABLED', true, 'bool']\\n      frequency: ['SPACE_ES_SNAPSHOTTING_FREQUENCY', 10, 'int']\\n    }\\n  }\\n}\",\n      \"language\": \"javascript\"\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"process.ENV API\"\n}\n[/block]\n\n[block:parameters]\n{\n  \"data\": {\n    \"0-0\": \"SPACE_TESTMODE\",\n    \"8-0\": \"SPACE_ES_MONGO_URL\",\n    \"9-0\": \"SPACE_ES_MONGO_OPLOG_URL\",\n    \"10-0\": \"SPACE_ES_COMMITS_COLLECTION_NAME\",\n    \"11-0\": \"SPACE_ES_SNAPSHOTTING_COLLECTION_NAME\",\n    \"0-1\": \"true,false\",\n    \"8-1\": \"\\\"mongodb://localhost:27017/dbName\\\"\",\n    \"9-1\": \"\\\"mongodb://localhost:27017/local?authSource=dbName?replicaSet=set-xx\\\"\",\n    \"h-1\": \"Example values\",\n    \"h-0\": \"Variable\",\n    \"10-1\": \"my_custom_collection_name\",\n    \"11-1\": \"my_custom_collection_name\",\n    \"h-2\": \"Status\",\n    \"0-2\": \"Proposed\",\n    \"8-2\": \"Pre-production\",\n    \"9-2\": \"Pre-production\",\n    \"10-2\": \"Pre-production\",\n    \"11-2\": \"Pre-production\",\n    \"3-0\": \"SPACE_JQ_LOG_ENABLED\",\n    \"5-0\": \"SPACE_JQ_MONGO_OPLOG_URL\",\n    \"3-1\": \"0,1,true,false\",\n    \"5-1\": \"\\\"mongodb://localhost:27017/local?authSource=dbName?replicaSet=set-xx\\\"\",\n    \"3-2\": \"Pre-Production\",\n    \"5-2\": \"Pre-Production\",\n    \"6-0\": \"SPACE_JQ_COLLECTION_NAME\",\n    \"6-1\": \"my_custom_collection_name\",\n    \"6-2\": \"Pre-Production\",\n    \"1-0\": \"SPACE_SYSLOG_ENABLED\",\n    \"1-1\": \"true,false\",\n    \"1-2\": \"Pre-Production\",\n    \"2-0\": \"SPACE_APPLOG_ENABLED\",\n    \"2-1\": \"true,false\",\n    \"2-2\": \"Pre-Production\",\n    \"4-0\": \"SPACE_JQ_MONGO_URL\",\n    \"4-1\": \"\\\"mongodb://localhost:27017/dbName\\\"\",\n    \"4-2\": \"Pre-Production\",\n    \"7-0\": \"SPACE_ES_LOG_ENABLED\",\n    \"7-1\": \"true,false\",\n    \"7-2\": \"Pre-Production\"\n  },\n  \"cols\": 3,\n  \"rows\": 12\n}\n[/block]","excerpt":"","slug":"configuration","type":"basic","title":"Configuration"}
[block:callout] { "type": "warning", "title": "Draft Documentation" } [/block] [block:api-header] { "type": "basic", "title": "Space.configuration" } [/block] Allows centralised global configuration the Space environment [block:code] { "codes": [ { "code": "{\n // testMode: ['SPACE_TESTMODE', false, 'bool']\n sysLog : {\n enabled: ['SPACE_SYSLOG_ENABLED', false, 'bool']\n },\n appLog : {\n enabled: ['SPACE_APPLOG_ENABLED', false, 'bool']\n }\n}", "language": "javascript" } ] } [/block] [block:api-header] { "type": "basic", "title": "Module.configuration (Application)" } [/block] Some Runtime Configuration can be set using Environment Variables, which are specified below as an array value. Options yet to be implemented have been commented out. [block:code] { "codes": [ { "code": "Configuration: {\n jobQueue: {\n mongoUrl: ['SPACE_JQ_MONGO_URL', '', 'string'],\n mongoOplogUrl: ['SPACE_JQ_MONGO_OPLOG_URL', '', 'string']\n collectionName: ['SPACE_JQ_COLLECTION_NAME', 'space_jobQueue', 'string']\n }\n eventSourcing: {\n log: {\n enabled: ['SPACE_ES_LOG_ENABLED', false, 'bool']\n }\n commits: {\n processingTimeout: ['SPACE_ES_COMMITS_PROCESSING_TIMEOUT', 1000, 'int']\n }\n snapshotting: {\n enabled: ['SPACE_ES_SNAPSHOTTING_ENABLED', true, 'bool']\n frequency: ['SPACE_ES_SNAPSHOTTING_FREQUENCY', 10, 'int']\n }\n }\n}", "language": "javascript" } ] } [/block] [block:api-header] { "type": "basic", "title": "process.ENV API" } [/block] [block:parameters] { "data": { "0-0": "SPACE_TESTMODE", "8-0": "SPACE_ES_MONGO_URL", "9-0": "SPACE_ES_MONGO_OPLOG_URL", "10-0": "SPACE_ES_COMMITS_COLLECTION_NAME", "11-0": "SPACE_ES_SNAPSHOTTING_COLLECTION_NAME", "0-1": "true,false", "8-1": "\"mongodb://localhost:27017/dbName\"", "9-1": "\"mongodb://localhost:27017/local?authSource=dbName?replicaSet=set-xx\"", "h-1": "Example values", "h-0": "Variable", "10-1": "my_custom_collection_name", "11-1": "my_custom_collection_name", "h-2": "Status", "0-2": "Proposed", "8-2": "Pre-production", "9-2": "Pre-production", "10-2": "Pre-production", "11-2": "Pre-production", "3-0": "SPACE_JQ_LOG_ENABLED", "5-0": "SPACE_JQ_MONGO_OPLOG_URL", "3-1": "0,1,true,false", "5-1": "\"mongodb://localhost:27017/local?authSource=dbName?replicaSet=set-xx\"", "3-2": "Pre-Production", "5-2": "Pre-Production", "6-0": "SPACE_JQ_COLLECTION_NAME", "6-1": "my_custom_collection_name", "6-2": "Pre-Production", "1-0": "SPACE_SYSLOG_ENABLED", "1-1": "true,false", "1-2": "Pre-Production", "2-0": "SPACE_APPLOG_ENABLED", "2-1": "true,false", "2-2": "Pre-Production", "4-0": "SPACE_JQ_MONGO_URL", "4-1": "\"mongodb://localhost:27017/dbName\"", "4-2": "Pre-Production", "7-0": "SPACE_ES_LOG_ENABLED", "7-1": "true,false", "7-2": "Pre-Production" }, "cols": 3, "rows": 12 } [/block]