console/packages/services/usage
renovate[bot] 5f75a9e3d5
chore(deps): update sentry (#6207)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-12-25 16:52:51 +02:00
..
__tests__ Make optional properties optional or nullable in usage report v2 (#6121) 2024-12-13 15:24:21 +01:00
src Improve logging around tokens and fix initial read (#6149) 2024-12-21 19:35:11 +00:00
.env.template Fix the new env vars setup (#450) 2022-10-05 11:48:05 +02:00
.gitignore Hello 2022-05-18 09:26:57 +02:00
LICENSE chore: update year in LICENSEs (#53) 2022-05-23 23:10:27 +02:00
package.json chore(deps): update sentry (#6207) 2024-12-25 16:52:51 +02:00
README.md fix: prometheus port documentation and expose (#3710) 2024-02-01 12:53:21 +00:00
tsconfig.json TS skipLibCheck everywhere, starting from root tsconfig (#588) 2022-11-03 15:00:58 +00:00
usage-report-v2.schema.json feat(apollo-router-plugin): persisted operations (app deployments) plugin with Hive, update usage to API-Version v2 (#5732) 2024-12-16 15:40:26 +02:00

@hive/usage

This service takes care of handling HTTP requests for usage reporting.

The data is written to a Kafka broker, form Kafka the data is feed into clickhouse via the usage-ingestor service.

Configuration

Name Required Description Example Value
PORT No The port this service is running on. 4001
TOKENS_ENDPOINT Yes The endpoint of the tokens service. http://127.0.0.1:6001
RATE_LIMIT_ENDPOINT No The endpoint of the rate limiting service. http://127.0.0.1:4012
KAFKA_TOPIC Yes The kafka topic. usage_reports_v2
KAFKA_CONSUMER_GROUP Yes The kafka consumer group. usage_reports_v2
KAFKA_BROKER Yes The address of the Kafka broker. 127.0.0.1:29092
KAFKA_SSL No Whether an SSL connection should be established to the kafka service. 1 (enabled) or 0 (disabled)
KAFKA_SSL_CA_PATH No Refer to TLS create secure context for more information ./path_to_ca
KAFKA_SSL_CERT_PATH No Refer to TLS create secure context for more information ./path_to_cert
KAFKA_SSL_KEY_PATH No Refer to TLS create secure context for more information ./path_to_key
KAFKA_SASL_MECHANISM No The mechanism used for doing SASL authentication plain or scram-sha-256 or scram-sha-512
KAFKA_SASL_USERNAME No The username for the SASL authentication letmein
KAFKA_SASL_PASSWORD No Whether an SSL connection should be established to the kafka service. letmein
KAFKA_BUFFER_SIZE No The buffer size ??? 12
KAFKA_BUFFER_INTERVAL No The buffer interval ??? 1
KAFKA_BUFFER_DYNAMIC No The buffer interval ??? 1
ENVIRONMENT No The environment of your Hive app. (Note: This will be used for Sentry reporting.) staging
SENTRY_DSN No The DSN for reporting errors to Sentry. https://dooobars@o557896.ingest.sentry.io/12121212
SENTRY No Whether Sentry error reporting should be enabled. 1 (enabled) or 0 (disabled)
PROMETHEUS_METRICS No Whether Prometheus metrics should be enabled 1 (enabled) or 0 (disabled)
PROMETHEUS_METRICS_LABEL_INSTANCE No The instance label added for the prometheus metrics. usage-service
PROMETHEUS_METRICS_PORT No Port on which prometheus metrics are exposed Defaults to 10254
REQUEST_LOGGING No Log http requests 1 (enabled) or 0 (disabled)
LOG_LEVEL No The verbosity of the service logs. One of trace, debug, info, warn ,error, fatal or silent info (default)