Improve single schema cache (#7214)
* Initial Commit * fix flaky test * temporary set ci timeout * turn off ci check * fix postgres tests * fix tests * node flaky test * remove improvements * Update SchemaPerformance.spec.js * fix tests * revert ci * Create Singleton Object * properly clear cache testing * Cleanup * remove fit * try PushController.spec * try push test rewrite * try push enqueue time * Increase test timeout * remove pg server creation test * xit push tests * more xit * remove skipped tests * Fix conflicts * reduce ci timeout * fix push tests * Revert "fix push tests" This reverts commit 05aba62f1cbbca7d5d3e80b9444529f59407cb56. * improve initialization * fix flaky tests * xit flaky test * Update CHANGELOG.md * enable debug logs * Update LogsRouter.spec.js * create initial indexes in series * lint * horizontal scaling documentation * Update Changelog * change horizontalScaling db option * Add enableSchemaHooks option * move enableSchemaHooks to databaseOptions
This commit is contained in:
@@ -100,7 +100,7 @@ module.exports.ParseServerOptions = {
|
||||
},
|
||||
databaseOptions: {
|
||||
env: 'PARSE_SERVER_DATABASE_OPTIONS',
|
||||
help: 'Options to pass to the mongodb client',
|
||||
help: 'Options to pass to the database client',
|
||||
action: parsers.objectParser,
|
||||
},
|
||||
databaseURI: {
|
||||
@@ -149,13 +149,6 @@ module.exports.ParseServerOptions = {
|
||||
action: parsers.booleanParser,
|
||||
default: false,
|
||||
},
|
||||
enableSingleSchemaCache: {
|
||||
env: 'PARSE_SERVER_ENABLE_SINGLE_SCHEMA_CACHE',
|
||||
help:
|
||||
'Use a single schema cache shared across requests. Reduces number of queries made to _SCHEMA, defaults to false, i.e. unique schema cache per request.',
|
||||
action: parsers.booleanParser,
|
||||
default: false,
|
||||
},
|
||||
encryptionKey: {
|
||||
env: 'PARSE_SERVER_ENCRYPTION_KEY',
|
||||
help: 'Key for encrypting your files',
|
||||
@@ -366,13 +359,6 @@ module.exports.ParseServerOptions = {
|
||||
action: parsers.booleanParser,
|
||||
default: false,
|
||||
},
|
||||
schemaCacheTTL: {
|
||||
env: 'PARSE_SERVER_SCHEMA_CACHE_TTL',
|
||||
help:
|
||||
'The TTL for caching the schema for optimizing read/write operations. You should put a long TTL when your DB is in production. default to 5000; set 0 to disable.',
|
||||
action: parsers.numberParser('schemaCacheTTL'),
|
||||
default: 5000,
|
||||
},
|
||||
security: {
|
||||
env: 'PARSE_SERVER_SECURITY',
|
||||
help: 'The security options to identify and report weak security settings.',
|
||||
@@ -788,3 +774,12 @@ module.exports.FileUploadOptions = {
|
||||
default: false,
|
||||
},
|
||||
};
|
||||
module.exports.DatabaseOptions = {
|
||||
enableSchemaHooks: {
|
||||
env: 'PARSE_SERVER_DATABASE_ENABLE_SCHEMA_HOOKS',
|
||||
help:
|
||||
'Enables database hooks to update single schema cache. Set to true if using multiple Parse Servers instances connected to the same database.',
|
||||
action: parsers.booleanParser,
|
||||
default: false,
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user