Commit Graph

394 Commits

Author SHA1 Message Date
Alberto Hernández
0e21b16004
force-build-master (#704) 2022-09-12 11:42:07 +02:00
Daniel García Aubert
d3d0baaac1 fix: be able to run test in development env w/o requiring a different dokerfile image 2021-04-07 19:03:09 +02:00
Álvaro
07119ce90a
Remove hardcoded values in tests 2020-12-17 11:11:49 +01:00
Daniel García Aubert
762a240890 Breaking changes:
- 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
2020-06-30 17:42:59 +02:00
Daniel García Aubert
d2b8e629bf Release 6.0.0 2020-06-05 14:02:34 +02:00
Daniel García Aubert
d45506554b Update yargs to version 15.3.1 2020-06-01 11:19:15 +02:00
Daniel García Aubert
e1f8e7fef1 Update mocha@7.2.0 2020-06-01 11:13:56 +02:00
Daniel García Aubert
882ac9c2bc Remove mkdirp as dep 2020-06-01 10:55:18 +02:00
Daniel García Aubert
0c92fcaf96 Node.js 12 support:
- Update `gc-stats` to version 1.4.0
- Replace `zipfile` -> `adm-zip`
- Update `libxmljs` to version 0.19.7
- Update `sqlite` to version 4.2.0
- Adapted pool acquires to the new version of `cartodb-redis`
- Adapted test to use `adm-zip`
2020-05-18 11:32:41 +02:00
Daniel García Aubert
7f1de39797 Upgrade redis-mpool to version 0.8.0 and cartodb-redis to version 3.0.0 2020-05-14 18:59:01 +02:00
Esther Lozano
419adea234
Add pubsub metrics (#642)
* Create middleware and service for pubsub metrics

* Use pubsub middleware for all request

* Replace isEnabled with isDisabled to avoid negation

* Use new headers names

* Add acceptance and unit tests

* Remove commented log calls

* Remove only filters in tests

Remove typo

* Refactor service to ease integration test

* Fix interaction with query controller

* Use middleware at api-router and test all controllers

* Rename user middleware function

* Use sinon latest version

* Create middleware and service for pubsub metrics

* Use pubsub middleware for all request

* Replace isEnabled with isDisabled to avoid negation

* Use new headers names

* Add acceptance and unit tests

* Remove commented log calls

* Remove only filters in tests

Remove typo

* Refactor service to ease integration test

* Fix interaction with query controller

* Use middleware at api-router and test all controllers

* Rename user middleware function

* Use sinon latest version

* Fix tests

* Fix typos

* Checks if pubsub config exists to enable the service

* Fix typo

* Normalize headers values for pubsub

* Trim fields when normalizing

* Trim fields when normalizing
2020-02-26 17:19:06 +01:00
Daniel García Aubert
4e9b68e578 Stubs next version 2020-01-27 12:54:50 +01:00
Daniel García Aubert
fc3a149657 Update package.json 2019-12-28 20:02:13 +01:00
Daniel García Aubert
77a12bc821 Replace the deprecated instanbul by nyc as coverage tool 2019-12-27 13:26:02 +01:00
Daniel García Aubert
24572f63a2 Stop using makefile and bash scripts to prepare redis and postgres 2019-12-27 13:09:05 +01:00
Daniel García Aubert
b11437e6cd Replace jshint by eslint as default linter tool 2019-12-23 18:18:18 +01:00
Daniel García Aubert
494f7f9bfb Stubs next version 2019-11-13 13:16:32 +01:00
Daniel García Aubert
d8494f10ff Release 5.0.0 2019-11-13 13:10:00 +01:00
Daniel García Aubert
476a220991 Update cartodb-query-tables to version 0.7.0 2019-10-21 16:20:52 +02:00
Daniel García Aubert
dc051fcc94 Update development branch 2019-10-21 13:46:40 +02:00
Daniel García Aubert
ee97a9f047 Use development branch of query-tables 2019-10-15 13:23:43 +02:00
Daniel García Aubert
ec436b9c5e Add contributor 2019-10-01 16:11:18 +02:00
Daniel García Aubert
a63c79fdd8 Release 4.0.0 2019-09-30 17:47:25 +02:00
Raúl Marín
16a8187269
Update cartodb-query-tables to 0.6.3 (#616)
* Update cartodb-query-tables to 0.6.3
2019-09-20 10:36:33 +02:00
Raul Marin
ff4721c480 Update cartodb-query-tables to 0.6.2 2019-09-18 18:19:26 +02:00
Raúl Marín
d57f00c4e5
query_tables_update: Update to 0.6.0 (#613) 2019-09-13 13:45:43 +02:00
Raúl Marín
df523960a2
Fix test timeouts (#612)
* Tests: Work with re-runs

* Test: Adapt copyfrom test
- Reduce timeout from 10 to 1 ms.
- Increase the size of the file from 6 to 2016 rows.

* Use node-cartodb-psql 0.14.0

Ref: https://github.com/CartoDB/CartoDB-SQL-API/pull/612
2019-09-13 11:28:37 +02:00
Daniel García Aubert
1055245eab Update cartodb-query-tables to version 0.5.0 2019-07-09 12:46:40 +02:00
Daniel García Aubert
7f152bc937 Update cartodb-query-tables to a development branch 2019-07-09 12:26:11 +02:00
Daniel García Aubert
3fbe18b333 Update version 2019-06-03 12:49:57 +02:00
Daniel García Aubert
e57f7b6ecf Use CARTO's fork of pg-copy-streams 2019-05-24 17:30:26 +02:00
Daniel García Aubert
679f9fa451 Use pg-copy-stream upstream 2019-05-17 18:50:41 +02:00
Daniel García Aubert
dc1c1230c4 Upgrade devel dep sqlite3 to version 4.0.6 2019-04-02 18:07:53 +02:00
Daniel García Aubert
066938cee7 Stubs next version 2019-02-22 13:07:54 +01:00
Daniel García Aubert
d04542f045 Update engines 2019-02-21 19:00:57 +01:00
Daniel García Aubert
26f8ccc3cf Drop support for Node.js 6, npm 3, Postgres 9.5, PostGIS 2.2, and Redis 3 2019-02-21 18:55:27 +01:00
Daniel García Aubert
955b72a87c Upgrade to mocha 5 to fix vulns 2019-01-16 18:13:17 +01:00
Daniel García Aubert
3e1916c003 Fix vuls in debug 2019-01-16 17:42:03 +01:00
Daniel García Aubert
020c64af26 Fix vulns in zipfile 2019-01-16 17:37:26 +01:00
Daniel García Aubert
4dec5dc992 Fixed vulns automatically with 'npm audit fix' 2019-01-16 15:32:56 +01:00
Daniel García Aubert
e36d4080d8 Stubs next version 2019-01-16 14:43:50 +01:00
Daniel García Aubert
a3a8224263 Update next release version 2019-01-16 14:40:47 +01:00
Daniel García Aubert
fc1fd66867 Get fine-grained garbage collection stats 2019-01-03 19:09:01 +01:00
Daniel García Aubert
e9e2117046 Update docs: Node.js and npm version 2019-01-02 11:16:00 +01:00
Daniel García Aubert
2404368e36 Stubs next version 2018-12-26 17:23:44 +01:00
Daniel García Aubert
880d4ce30c Stubs next version 2018-12-26 15:33:57 +01:00
Rafa de la Torre
da46f9f8e2 Fix version of cartodb-psql (remove caret ^) 2018-12-12 18:20:10 +01:00
Rafa de la Torre
2773c6d23e
Merge pull request #547 from CartoDB/mockdate
Properly mock Date.now() for tests
2018-12-11 12:46:49 +01:00
Rafa de la Torre
a7c0917019 Add mockdate to dev dependencies 2018-12-11 11:37:45 +01:00
Rafa de la Torre
b56f60ac4b Update package-lock.json 2018-12-10 18:23:58 +01:00