Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
Configuration is handled by [Spring Boot](https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html),
which supports properties files, YAML files, environment variables and command-line arguments for setting config values.

As a general rule, Prebid Cache will immediately fails on startup if any of required properties is missing or invalid.
Both `_` and `-` can be used as a delimiters. As an example, both `api.cache_path` and `api.cache-path` refer to the same parameter.

As a general rule, Prebid Cache will immediately fail on startup if any of required properties is missing or invalid.

The next sections describes how to set up project configuration.

Expand All @@ -14,6 +16,8 @@ The next sections describes how to set up project configuration.
- `api.cache_path` - set path for cache endpoint.
- `api.module_storage_path` - set path for storage endpoint.
- `api.api_key` - set API key.
- `api.cache_write_secured` - if `true`, POST requests to `/cache` will require a valid API key.
- `api.external_UUID_secured` - if `true`, providing external UUID will additionally require a valid API key.

#### Cors
- `cors.enabled` - toggle for cors.
Expand Down
21 changes: 21 additions & 0 deletions docs/metrics.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Metrics

`{prefix}` can be `read` or `write` but doesn't automatically mean that metric will appear in both.

- `pbc.{prefix}.request.duration` - the time it took to store or retrieve creative in ns.
- `pbc.{prefix}.request` - the count of incoming requests.
- `pbc.{prefix}.trustedRequest` - the count of incoming requests carrying a matching API key.
- `pbc.request.invalid` - the count of incoming requests using invalid endpoint or method.
- `pbc.{prefix}.err.timedOut` - the count of timed out requests. Usually indicates an issue with the storage backend.
- `pbc.{prefix}.err.missingId` - the count of requests that carried a UUID that was not present in storage backend.
- `pbc.{prefix}.err.badRequest` - the count of malformed or otherwise invalid requests.
- `pbc.{prefix}.err.unauthorized` - the count of unauthorized requests.
- `pbc.{prefix}.err.unknown` - the count of unknown (not falling into the defined categories) errors.
- `pbc.{prefix}.err.db` - the count of storage backend errors.
- `pbc.{prefix}.json` - the count of JSON (banner) creatives.
- `pbc.{prefix}.xml` - the count of XML (video) creatives.
- `pbc.err.secondaryWrite` - the count of secondary write errors.
- `pbc.err.existingId` - the count of errors due to existing UUID key in the storage backend.
- `pbc.err.rejectedExternalId` - the count of rejected writes due to specifying external UUID not being allowed.
- `pbc.proxy.success` - the count of successful proxying requests.
- `pbc.proxy.failure` - the count of failed proxying requests.
Loading