Skip to content

Commit

Permalink
Revert "adds prometheus endpoint with pre aggregation metrics"
Browse files Browse the repository at this point in the history
This reverts commit e487758.
  • Loading branch information
igorcalabria authored and cfms3 committed Mar 5, 2024
1 parent 5be690c commit e82135f
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 137 deletions.
1 change: 0 additions & 1 deletion packages/cubejs-server-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
"moment": "^2.29.1",
"node-fetch": "^2.6.0",
"p-limit": "^3.1.0",
"prom-client": "^14.2.0",
"promise-timeout": "^1.3.0",
"ramda": "^0.27.0",
"semver": "^6.3.0",
Expand Down
100 changes: 0 additions & 100 deletions packages/cubejs-server-core/src/core/metrics.ts

This file was deleted.

17 changes: 0 additions & 17 deletions packages/cubejs-server-core/src/core/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ import type {
DriverConfig,
} from './types';
import { ContextToOrchestratorIdFn, ContextAcceptanceResult, ContextAcceptanceResultHttp, ContextAcceptanceResultWs, ContextAcceptor } from './types';
import { Metrics } from './metrics';

const { version } = require('../../../package.json');

Expand Down Expand Up @@ -410,22 +409,6 @@ export class CubejsServerCore {
const apiGateway = this.apiGateway();
apiGateway.initApp(app);

const metricsContext = {securityContext: undefined, authInfo: undefined, requestId: "metrics"}

const metrics = new Metrics({
scheduledRefreshTimeZones: this.options.scheduledRefreshTimeZones ?? [],
compilerApi: this.getCompilerApi.bind(this),
orchestratorApi: this.getOrchestratorApi.bind(this),
refreshScheduler: this.getRefreshScheduler(),
metricsContext: metricsContext,
logger: this.logger
})

app.get('/metrics', (async (req, res) => {
const allMetrics = await metrics.getMetrics()
res.status(200).send(allMetrics)
}));

if (this.options.devServer) {
this.devServer.initDevEnv(app, this.options);
} else {
Expand Down
19 changes: 0 additions & 19 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12249,11 +12249,6 @@ bindings@^1.5.0:
dependencies:
file-uri-to-path "1.0.0"

[email protected]:
version "1.0.2"
resolved "https://registry.yarnpkg.com/bintrees/-/bintrees-1.0.2.tgz#49f896d6e858a4a499df85c38fb399b9aff840f8"
integrity sha512-VOMgTMwjAaUG580SXn3LacVgjurrbMme7ZZNYGSSV7mmtY6QQRh0Eg3pwIcntQ77DErK1L0NxkbetjcoXzVwKw==

bl@^1.0.0:
version "1.2.3"
resolved "https://registry.yarnpkg.com/bl/-/bl-1.2.3.tgz#1e8dd80142eac80d7158c9dccc047fb620e035e7"
Expand Down Expand Up @@ -24861,13 +24856,6 @@ progress@^2.0.0, progress@^2.0.1:
resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8"
integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==

prom-client@^14.2.0:
version "14.2.0"
resolved "https://registry.yarnpkg.com/prom-client/-/prom-client-14.2.0.tgz#ca94504e64156f6506574c25fb1c34df7812cf11"
integrity sha512-sF308EhTenb/pDRPakm+WgiN+VdM/T1RaHj1x+MvAuT8UiQP8JmOEbxVqtkbfR4LrvOg5n7ic01kRBDGXjYikA==
dependencies:
tdigest "^0.1.1"

promise-inflight@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/promise-inflight/-/promise-inflight-1.0.1.tgz#98472870bf228132fcbdd868129bad12c3c029e3"
Expand Down Expand Up @@ -28344,13 +28332,6 @@ tarn@^1.1.5:
resolved "https://registry.yarnpkg.com/tarn/-/tarn-1.1.5.tgz#7be88622e951738b9fa3fb77477309242cdddc2d"
integrity sha512-PMtJ3HCLAZeedWjJPgGnCvcphbCOMbtZpjKgLq3qM5Qq9aQud+XHrL0WlrlgnTyS8U+jrjGbEXprFcQrxPy52g==

tdigest@^0.1.1:
version "0.1.2"
resolved "https://registry.yarnpkg.com/tdigest/-/tdigest-0.1.2.tgz#96c64bac4ff10746b910b0e23b515794e12faced"
integrity sha512-+G0LLgjjo9BZX2MfdvPfH+MKLCrxlXSYec5DaPYP1fe6Iyhf0/fSmJ0bFiZ1F8BT6cGXl2LpltQptzjXKWEkKA==
dependencies:
bintrees "1.0.2"

tedious@^6.7.1:
version "6.7.1"
resolved "https://registry.yarnpkg.com/tedious/-/tedious-6.7.1.tgz#e581be8634a5268b37dffe8930ba2d781edd8a3d"
Expand Down

0 comments on commit e82135f

Please sign in to comment.