762a240890
- Log system revamp: - Logs to stdout, disabled while testing - Use header `X-Request-Id`, or create a new `uuid` when no present, to identyfy log entries - Be able to set log level from env variable `LOG_LEVEL`, useful while testing: `LOG_LEVEL=info npm test`; even more human-readable: `LOG_LEVEL=info npm t | ./node_modules/.bin/pino-pretty` - Be able to reduce the footprint in the final log file depending on the environment - Use one logger for every service: Queries, Batch Queries (Jobs), and Data Ingestion (CopyTo/CopyFrom) - Stop using headers such as: `X-SQL-API-Log`, `X-SQL-API-Profiler`, and `X-SQL-API-Errors` as a way to log info. - Be able to tag requests with labels as an easier way to provide business metrics - Metro: Add log-collector utility (`metro`), it will be moved to its own repository. Attaching it here fro development purposes. Try it with the following command `LOG_LEVEL=info npm t | node metro` - Metro: Creates `metrics-collector.js` a stream to update Prometheus' counters and histograms and exposes them via Express' app (`:9145/metrics`). Use the ones defined in `grok_exporter` Announcements: - Profiler is always set. No need to check its existence anymore - Unify profiler usage for every endpoint Bug fixes: - Avoid hung requests while fetching user identifier
98 lines
2.9 KiB
JSON
98 lines
2.9 KiB
JSON
{
|
|
"private": true,
|
|
"name": "cartodb-sql-api",
|
|
"version": "6.0.0",
|
|
"description": "High speed SQL API for CARTO",
|
|
"keywords": [
|
|
"carto",
|
|
"sql",
|
|
"batch",
|
|
"import",
|
|
"export",
|
|
"geospatial"
|
|
],
|
|
"url": "https://github.com/CartoDB/CartoDB-SQL-API",
|
|
"license": "BSD-3-Clause",
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git://github.com/CartoDB/CartoDB-SQL-API.git"
|
|
},
|
|
"author": "CARTO (https://carto.com)",
|
|
"contributors": [
|
|
"Simon Tokumine <simon@vizzuality.com>",
|
|
"Sandro Santilli <strk@vizzuality.com>",
|
|
"Raúl Ochoa <rochoa@carto.com>",
|
|
"Daniel García Aubert <dgaubert@carto.com>"
|
|
],
|
|
"main": "app.js",
|
|
"dependencies": {
|
|
"@carto/fqdn-sync": "0.2.2",
|
|
"@google-cloud/pubsub": "1.5.0",
|
|
"assign-deep": "^1.0.1",
|
|
"basic-auth": "^2.0.0",
|
|
"bintrees": "1.0.1",
|
|
"bunyan": "1.8.1",
|
|
"cartodb-psql": "0.14.0",
|
|
"cartodb-query-tables": "^0.7.0",
|
|
"cartodb-redis": "^3.0.0",
|
|
"debug": "^4.1.1",
|
|
"express": "^4.16.4",
|
|
"gc-stats": "^1.4.0",
|
|
"log4js": "cartodb/log4js-node#cdb",
|
|
"lru-cache": "~2.5.0",
|
|
"multer": "~1.2.0",
|
|
"node-statsd": "~0.0.7",
|
|
"node-uuid": "^1.4.7",
|
|
"oauth-client": "0.3.0",
|
|
"pg-copy-streams": "github:cartodb/node-pg-copy-streams#v2.x-carto",
|
|
"pino": "^6.3.2",
|
|
"prom-client": "^12.0.0",
|
|
"qs": "~6.2.1",
|
|
"queue-async": "~1.0.7",
|
|
"redis-mpool": "^0.8.0",
|
|
"redlock": "2.0.1",
|
|
"request": "^2.88.0",
|
|
"split2": "^3.1.1",
|
|
"step": "~0.0.5",
|
|
"step-profiler": "~0.3.0",
|
|
"topojson": "0.0.8",
|
|
"underscore": "~1.6.0",
|
|
"uuid": "^8.1.0",
|
|
"yargs": "^15.3.1"
|
|
},
|
|
"devDependencies": {
|
|
"adm-zip": "^0.4.14",
|
|
"eslint": "^6.8.0",
|
|
"eslint-config-standard": "^14.1.0",
|
|
"eslint-plugin-import": "^2.19.1",
|
|
"eslint-plugin-node": "^10.0.0",
|
|
"eslint-plugin-promise": "^4.2.1",
|
|
"eslint-plugin-standard": "^4.0.1",
|
|
"libxmljs": "^0.19.7",
|
|
"mocha": "^7.2.0",
|
|
"mockdate": "^2.0.2",
|
|
"nyc": "^15.0.0",
|
|
"pino-pretty": "^4.0.0",
|
|
"shapefile": "0.3.0",
|
|
"sinon": "^9.0.0",
|
|
"sqlite3": "^4.2.0"
|
|
},
|
|
"scripts": {
|
|
"lint:fix": "eslint --fix app.js \"lib/**/*.js\" \"test/**/*.js\"",
|
|
"lint": "eslint app.js \"lib/**/*.js\" \"test/**/*.js\"",
|
|
"pretest:setup": "npm run lint",
|
|
"test:setup": "NODE_ENV=test node test setup",
|
|
"pretest": "npm run test:setup",
|
|
"test": "NODE_ENV=test TZ='Europe/Rome' mocha -t 5000 --exit --recursive test/acceptance test/integration test/unit",
|
|
"posttest": "npm run test:teardown",
|
|
"test:teardown": "NODE_ENV=test node test teardown",
|
|
"cover": "nyc --reporter=lcov npm test",
|
|
"test:docker": "docker run -e \"NODEJS_VERSION=$NODE_VERSION\" -v `pwd`:/srv $DOCKER_IMAGE bash docker/scripts/test-setup.sh && docker ps --filter status=dead --filter status=exited -aq | xargs docker rm -v",
|
|
"docker:bash": "docker run -it -v `pwd`:/srv $DOCKER_IMAGE bash"
|
|
},
|
|
"engines": {
|
|
"node": "^10.15.1",
|
|
"npm": "^6.4.1"
|
|
}
|
|
}
|