Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

appcd-config-service

Package Overview
Dependencies
Maintainers
3
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

appcd-config-service - npm Package Compare versions

Comparing version 3.0.0 to 3.1.0

6

CHANGELOG.md

@@ -0,1 +1,7 @@

# v3.1.0 (Dec 1, 2020)
* feat: Added config file live reloading.
* fix: Unload the config layer if the watched config file is deleted.
* chore: Updated dependencies.
# v3.0.0 (Jun 12, 2020)

@@ -2,0 +8,0 @@

78

dist/config-service.js

@@ -10,2 +10,4 @@ "use strict";

var _appcdFswatcher = _interopRequireDefault(require("appcd-fswatcher"));
var _appcdResponse = _interopRequireWildcard(require("appcd-response"));

@@ -110,2 +112,14 @@

} = data;
const unload = id => {
log(`Unloading config: ${highlight(id)}`);
this.config.unload(id);
if (this.watchers[id]) {
log(`Closing ${highlight(id)} fs watcher`);
this.watchers[id].close();
delete this.watchers[id];
}
};
log(`Handling ${highlight(action)} request`);

@@ -115,10 +129,34 @@

} else if (action === 'load') {
this.config.load(data.file, {
id: data.id || data.namespace,
namespace: data.namespace || data.id,
readonly: data.readonly,
schema: data.schema
const id = data.id || data.namespace;
if (!id || typeof id !== 'string') {
throw new _appcdDispatcher.DispatcherError(_appcdResponse.codes.BAD_REQUEST, 'Missing id or namespace');
}
const load = isReload => {
log(`${isReload ? 'Reloading' : 'Loading'} ${id} config: ${highlight(data.file)}`);
this.config.load(data.file, {
id,
namespace: data.namespace || data.id,
readonly: data.readonly,
schema: data.schema
});
};
load();
this.watchers[id] = new _appcdFswatcher.default(data.file).on('change', ({
action
}) => {
if (action === 'delete') {
unload(id);
} else {
load(true);
}
});
ctx.response = new _appcdResponse.default(_appcdResponse.codes.OK);
return;
} else if (action === 'unload') {
this.config.unload(data.id || data.namespace);
unload(data.id || data.namespace);
ctx.response = new _appcdResponse.default(_appcdResponse.codes.OK);
return;
} else if (writeRegExp.test(action)) {

@@ -176,3 +214,3 @@ // performing a modifying action

if (filter) {
log('Filtering config:', filter);
log(`Filtering config: ${highlight(filter)}`);
} // log(this.config.toString());

@@ -246,6 +284,30 @@

}
/**
* Closes all open filesystem watchers.
*
* @returns {Promise}
* @access public
*/
async shutdown() {
// stop all filesystem watchers
const ids = Object.keys(this.watchers);
if (ids.length) {
log(`Closing ${ids.length} fs watcher${ids.length !== 1 ? 's' : ''}:`);
for (const id of ids) {
log(` ${highlight(id)}`);
this.watchers[id].close();
delete this.watchers[id];
}
} else {
log('No open fs watchers');
}
}
}
exports.default = ConfigService;
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImNvbmZpZy1zZXJ2aWNlLmpzIl0sIm5hbWVzIjpbIkVycm9yIiwicHJlcGFyZVN0YWNrVHJhY2UiLCJyZXF1aXJlIiwiZXJyb3IiLCJsb2ciLCJoaWdobGlnaHQiLCJhcHBjZExvZ2dlciIsInN0eWxlcyIsIndyaXRlUmVnRXhwIiwiQ29uZmlnU2VydmljZSIsIlNlcnZpY2VEaXNwYXRjaGVyIiwiY29uc3RydWN0b3IiLCJjZmciLCJUeXBlRXJyb3IiLCJjb25maWciLCJ3YXRjaGVycyIsImdldFRvcGljIiwiY3R4IiwiZGF0YSIsInBhcmFtcyIsInRvcGljIiwicmVxdWVzdCIsIlN0cmluZyIsImZpbHRlciIsImtleSIsInJlcGxhY2UiLCJzcGxpdCIsImpvaW4iLCJvbkNhbGwiLCJ0cmltIiwiYWN0aW9uIiwiRGlzcGF0Y2hlckVycm9yIiwiY29kZXMiLCJCQURfUkVRVUVTVCIsImxvYWQiLCJmaWxlIiwiaWQiLCJuYW1lc3BhY2UiLCJyZWFkb25seSIsInNjaGVtYSIsInVubG9hZCIsInRlc3QiLCJGT1JCSURERU4iLCJyZXNwb25zZSIsIlJlc3BvbnNlIiwiT0siLCJKU09OIiwic3RyaW5naWZ5IiwidmFsdWUiLCJzZXQiL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Y2hlciR7aWRzLmxlbmd0aCAhPT0gMSA/ICdzJyA6ICcnfTpgKTtcblx0XHRcdGZvciAoY29uc3QgaWQgb2YgaWRzKSB7XG5cdFx0XHRcdGxvZyhgICAke2hpZ2hsaWdodChpZCl9YCk7XG5cdFx0XHRcdHRoaXMud2F0Y2hlcnNbaWRdLmNsb3NlKCk7XG5cdFx0XHRcdGRlbGV0ZSB0aGlzLndhdGNoZXJzW2lkXTtcblx0XHRcdH1cblx0XHR9IGVsc2Uge1xuXHRcdFx0bG9nKCdObyBvcGVuIGZzIHdhdGNoZXJzJyk7XG5cdFx0fVxuXHR9XG59XG4iXSwiZmlsZSI6ImNvbmZpZy1zZXJ2aWNlLmpzIn0=

13

package.json
{
"name": "appcd-config-service",
"version": "3.0.0",
"version": "3.1.0",
"description": "Appc Daemon service for managing the appcd configuration.",

@@ -19,10 +19,11 @@ "main": "./dist/config-service",

"dependencies": {
"appcd-dispatcher": "^3.0.0",
"appcd-logger": "^3.0.0",
"appcd-path": "^2.0.1",
"appcd-response": "^3.0.0",
"appcd-dispatcher": "^3.1.0",
"appcd-fswatcher": "^2.0.1",
"appcd-logger": "^3.0.1",
"appcd-path": "^2.0.2",
"appcd-response": "^3.0.1",
"source-map-support": "^0.5.19"
},
"devDependencies": {
"appcd-gulp": "^3.0.1",
"appcd-gulp": "^3.1.0",
"tmp": "^0.2.1"

@@ -29,0 +30,0 @@ },

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc