Á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
5a96dbb59c
Run eslint --fix
2019-12-23 18:19:08 +01:00
Daniel García Aubert
e96ea32ea4
Rely on defaults (server-options) for routes configuration
2019-10-07 14:38:21 +02:00
Daniel García Aubert
06a47a8afc
Changed folder structure to reflect application functionallity. Renamed files using hyphens instead of underscore to have a more consistent naming across the whole project
2019-10-03 18:24:39 +02:00
Daniel García Aubert
54cf5a072f
Improve naming
2019-10-01 18:22:13 +02:00
Daniel García Aubert
3dee09a5c5
Draft: be able to inject custom middlewares
2019-10-01 17:27:46 +02:00
Daniel García Aubert
07cf020923
Style
2019-10-01 16:17:21 +02:00
Daniel García Aubert
7620383f87
Remove outdated comment
2019-10-01 16:13:19 +02:00
Daniel García Aubert
b2f51a4d2d
Use 'const' instead of 'var'
2019-10-01 16:11:08 +02:00
Daniel García Aubert
5c95ee0daa
Rename public factory function
2019-10-01 15:50:05 +02:00
Daniel García Aubert
8f331becf4
Be more consistent while defining arguments
2019-04-05 11:55:58 +02:00
Daniel García Aubert
df548b301c
Typo
2019-04-04 19:42:28 +02:00
Daniel García Aubert
7dad3eb454
Add schedule force exit to SIGINT, SIGTERM, and unhandledRejection events
2019-04-04 19:21:09 +02:00
Daniel García Aubert
29e5b1ff97
Use 'once'
2019-04-04 18:31:07 +02:00
Daniel García Aubert
ce04cbcb45
Use callback properly
2019-04-04 18:21:49 +02:00
Daniel García Aubert
f2b5921ade
Flush batch logger to not lose info
2019-04-04 18:15:21 +02:00
Daniel García Aubert
12e35b02e8
Log more info
2019-04-04 17:26:58 +02:00
Daniel García Aubert
b01ac63ed7
Do not pass callback to method close
2019-04-04 17:13:04 +02:00
Daniel García Aubert
3ed4b142c0
Improve shutdown
2019-04-04 16:44:54 +02:00
Daniel García Aubert
3c73e2f0b4
Revert "Temporal debugging flag"
...
This reverts commit b3306ae258
.
2019-04-04 11:51:43 +02:00
Daniel García Aubert
b3306ae258
Temporal debugging flag
2019-04-03 19:01:36 +02:00
Daniel García Aubert
71bc3da115
Bad variable name
2019-01-03 19:26:44 +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
fdaae20af7
Use let instead of var
2018-11-15 14:34:36 +01:00
Daniel García Aubert
267baf621e
Send userm system, time and percent CPU metrics
2018-11-15 13:49:57 +01:00
Daniel García Aubert
e28349ff29
Send metrics about memory and CPU usage
2018-11-15 11:03:51 +01:00
Daniel García Aubert
a616982ec3
Use strict mode
2018-10-24 15:42:33 +02:00
Simon Martín
b4724d7408
data ingestion logger reopenFileStreams
2018-06-18 18:48:38 +02:00
Daniel García Aubert
d7e24f7745
Use external module to get full qualified domain name properly
2018-06-08 13:30:54 +02:00
Raul Ochoa
28af78ba99
Avoid global stats client
2017-03-30 17:32:22 +02:00
Raul Ochoa
57d7ec3048
Make active GC cycles for Node.js >=v6
2017-03-30 16:27:34 +02:00
Raul Ochoa
db9bfacf07
Extract stats client creation
2017-03-30 16:13:17 +02:00
Raul Ochoa
742d7255a1
Log Node.js version on startup
2017-02-10 10:03:36 +01:00
Raul Ochoa
bf1a67780d
Merge branch 'master' into express-4.x
2016-09-30 17:37:30 +02:00
Raul Ochoa
b0dfe1d509
Only reload log files if logger exists
2016-09-30 17:10:52 +02:00
Daniel García Aubert
aa0ce62a85
Implement batch logger to log query times when queries are defined with id
2016-09-29 15:09:36 +02:00
Raul Ochoa
abc2f130c9
Migrate to express 4.x series
...
- Remove express logger
- Error handler responds with application/[json|javascript]
- Fix all tests relying on res.headers
- assert.response based on request module
2016-09-26 18:09:27 +02:00
Raul Ochoa
4dfdb2eaea
Fix example
2016-09-15 00:40:25 +02:00
Raul Ochoa
27b73cb163
Allow to use --config /path/to/config.js
to specify configuration file
2016-09-15 00:36:24 +02:00
Raul Ochoa
510f1cd7d7
Rename var
2016-09-14 23:10:14 +02:00
Raul Ochoa
84b80547c2
Remove settings' app_root
2016-09-14 21:02:56 +02:00
Raul Ochoa
f92d50cccf
Rename from app to server
...
Removes app_root dependency in requires
2016-09-14 20:54:53 +02:00
Raul Ochoa
e315e77525
Allow to use absolute paths for log files
...
Fixes #355
2016-09-14 20:03:16 +02:00
Raul Ochoa
0626d80e24
Removes support for optional rollbar logging
2016-09-14 19:22:31 +02:00
Daniel García Aubert
e9bd93cf3f
Now batch service is linked to express app in order to make it accesible from main app module to expose drain mechanism
2016-01-25 16:28:19 +01:00
Daniel García Aubert
c6bae6d951
app module moved to right place
2015-12-03 18:33:17 +01:00
Daniel García Aubert
a697fe6faa
Making test pass
2015-12-03 18:19:39 +01:00
Daniel García Aubert
e5dedb6315
Split query controller and separated from app
2015-12-03 17:28:18 +01:00
Raul Ochoa
cac2fff5ed
jshint: fix application entrypoint
2015-05-12 17:33:41 +02:00