Daniel García Aubert
107a97aa9e
Honor @oleurud's comment
2020-06-03 15:11:08 +02:00
Daniel García Aubert
219d2c9044
Shortcuts for serializers
2020-06-03 15:10:31 +02:00
Daniel García Aubert
1e89821d97
Use standard serializers for error, request, and response
2020-06-03 14:28:35 +02:00
Daniel García Aubert
29c6505252
Do not set header 'x-tiler-profiler' and log it instead
2020-06-02 17:09:06 +02:00
Daniel García Aubert
7d8d05b865
Log errors and do not send 'X-Tiler-Errors' header
2020-06-02 16:15:01 +02:00
Daniel García Aubert
afeb91dc86
Bring back logger for windshaft
2020-06-02 13:20:57 +02:00
Daniel García Aubert
b7b3392bdd
Be able to set log level from env variable LOG_LEVEL
2020-06-02 13:16:26 +02:00
Daniel García Aubert
b60116410a
Use req/res logger instead of the one bound to global object
2020-06-02 12:31:18 +02:00
Daniel García Aubert
48c28aea0b
Do not bind logger to global object, now it's a part of serverOptions
2020-06-02 11:49:54 +02:00
Daniel García Aubert
62d66f2dbc
Do not use global logger in middlewares, use the one initialized in res.locals instead
2020-06-02 09:00:45 +02:00
Daniel García Aubert
163c546236
Replace log4js by pino as logger:
...
- Logs to stdout, disabled while testing
- Change log calls signature when needed
- Use development version of camshaft
- Removes unused log cofiguration
- Bind request id to log req/res
- Log req at the begining of the cycle and res at the end
2020-06-01 19:18:15 +02:00
Daniel García Aubert
6bcf477532
Avoid custom headers to be undefined
2020-05-29 16:06:16 +02:00
Daniel García Aubert
f82232194c
Under if
2020-05-26 16:31:53 +02:00
Daniel García Aubert
aff5c9a614
Add test to check the headers exist while instantiating a map
2020-05-26 16:28:44 +02:00
Daniel García Aubert
ddefb1a6ca
Add 'Carto-Stat-Tag', 'Carto-User-Id', and 'Carto-Client' headers
2020-05-26 13:15:35 +02:00
Daniel García Aubert
8cc24bc665
- Drop support for Node.js < 12
...
- Support Node.js 12
- Upgrade `windshaft` to version `7.0.0`
- Upgrade `camshaft` to version `0.65.3`
- Upgrade `cartodb-redis` to version `3.0.0`
2020-05-14 13:00:23 +02:00
Daniel García Aubert
4dfc898587
Don't log when metrics where sent successfully
2020-05-01 13:25:03 +02:00
Daniel García Aubert
3cf17c8bab
typo
2020-05-01 10:40:56 +02:00
Daniel García Aubert
8c38ecf808
Missing substring
2020-04-30 13:24:41 +02:00
Daniel García Aubert
a196a26ab4
Get templateHash for static tile request and errored named map instantiations
2020-04-30 13:09:12 +02:00
Daniel García Aubert
d5348dd9d4
Rename fields from headers of metrics
2020-04-29 18:48:10 +02:00
Daniel García Aubert
7e31b956bf
Send stat_tag metric when available
2020-04-29 18:25:01 +02:00
Daniel García Aubert
dbc5d65d90
Send template_hash as part of the metrics event
2020-04-29 17:26:33 +02:00
Daniel García Aubert
c91d78fe51
Also export template hash
2020-04-29 16:44:14 +02:00
Daniel García Aubert
798d010776
Ensure "map_id" and "cache_buster" as part of the event
2020-04-29 14:32:08 +02:00
Daniel García Aubert
70f0b6ea50
Avoid to use "pubsub" for the name of modules, middlewares, variables, etc..
2020-04-29 10:40:45 +02:00
Daniel García Aubert
4e3ef96374
Add test to chek we still send events when errored map static tile
2020-04-29 10:28:10 +02:00
Daniel García Aubert
c88a14bf43
Send metrics for map instantiations (named, anonymous and static) with the new format.
2020-04-28 19:17:00 +02:00
Daniel García Aubert
c5cb2ea4cb
Add FIXME comment
2020-04-27 13:35:19 +02:00
Daniel García Aubert
fe9610abe9
Missing logger argument
2020-04-27 13:35:07 +02:00
Daniel García Aubert
1bbde4f5e3
Let to the caller to choose how to handle the call to a method
2020-04-27 13:27:05 +02:00
Daniel García Aubert
e90c196598
Simplified metrics middleware and backend
2020-04-27 12:46:27 +02:00
Daniel García Aubert
6a2333be64
Topic name's lifetime is longer than pubsub backend, we can keep it as property.
2020-04-27 12:13:54 +02:00
Daniel García Aubert
7d6a64d383
Do not expose functions just to be able to mock them while testing
2020-04-27 11:59:36 +02:00
Daniel García Aubert
42dc2915ea
Send pubsub metrics once the response has finished
2020-04-27 11:41:37 +02:00
Daniel García Aubert
3cec6b5a90
Missing callback
2020-04-27 11:06:09 +02:00
Daniel García Aubert
c31e3d6e3f
Consistent interface when returning no event for eventa data in metrics
2020-04-27 10:58:37 +02:00
Daniel García Aubert
6e4c8a6639
Follow Node.js callback pattern
2020-04-27 10:23:11 +02:00
manmorjim
d1696425fd
Prevent using cast column from alias __ctx_query
...
Fixes #1160 by keep the original name of the column and using it if the
column type is date.
2020-04-10 14:14:24 +02:00
Daniel García Aubert
8bb4fbec12
Get the rendererCache's config right and avoid to set the NamedMapCacheReporter's interval to 'undefined'
2020-04-04 18:51:22 +02:00
Daniel García Aubert
a8fb51ba25
- Rename NamedMapProviderReporter by NamedMapProviderCacheReporter
...
- Extract getOnTileErrorStrategy to a module
- Stop using MapStore from windshaft while testing and create a custom one instead
2020-04-04 17:46:08 +02:00
Daniel García Aubert
c25678cc28
Remove /version
endpoint and bootstrapFonts at process startup (now done in windshaft)
2020-04-04 17:42:26 +02:00
Daniel García Aubert
f583a4240a
Remove jshint comments
2020-04-04 17:29:33 +02:00
Daniel García Aubert
4054c6923f
Use new signature for onTileErrorStrategy
2020-03-27 19:38:28 +01:00
Daniel García Aubert
58ed7c0093
Lint
2020-03-23 10:07:24 +01:00
Daniel García Aubert
78f47e5873
Update windshaft and send more metrics
2020-03-21 18:30:38 +01:00
Daniel García Aubert
21d1a56953
Update windshaft and use the new method that reports stats about cached renderers
2020-03-21 14:13:53 +01:00
Daniel García Aubert
69a02bcee0
Fix stat named map providers cache count
2020-03-20 18:50:22 +01:00
Esther Lozano
7b8cc0a8b8
Add response time to pubsub events ( #1155 )
2020-03-10 11:40:01 +01:00
Esther Lozano
779a8a8927
Fix linter
2020-02-26 17:44:53 +01:00