Skip to content

Commit

Permalink
bump WKC (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
hugoArregui authored Mar 15, 2024
1 parent e8d1b4d commit c78eef9
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 20 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,10 @@
"@dcl/schemas": "^10.3.0",
"@well-known-components/env-config-provider": "^1.1.1",
"@well-known-components/fetch-component": "^2.0.0",
"@well-known-components/http-server": "^2.0.0",
"@well-known-components/interfaces": "^1.4.1",
"@well-known-components/http-server": "^2.0.1-20240313124908.commit-80c33da",
"@well-known-components/interfaces": "^1.4.3",
"@well-known-components/logger": "^3.1.2",
"@well-known-components/metrics": "^2.0.1-20220909150423.commit-8f7e5bc",
"@well-known-components/metrics": "^2.0.2-20240314122215.commit-df469cb",
"dcl-catalyst-client": "^21.5.5",
"eth-connect": "^6.2.4",
"lru-cache": "^10.0.1"
Expand Down
10 changes: 7 additions & 3 deletions src/components.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
import { createDotEnvConfigComponent } from '@well-known-components/env-config-provider'
import { createServerComponent, createStatusCheckComponent } from '@well-known-components/http-server'
import {
createServerComponent,
createStatusCheckComponent,
instrumentHttpServerWithPromClientRegistry
} from '@well-known-components/http-server'
import { createLogComponent } from '@well-known-components/logger'
import { createMetricsComponent, instrumentHttpServerWithMetrics } from '@well-known-components/metrics'
import { createMetricsComponent } from '@well-known-components/metrics'
import { AppComponents, GlobalContext } from './types'
import { metricDeclarations } from './metrics'
import { createCatalystsProvider } from './adapters/realm-provider'
Expand All @@ -28,7 +32,7 @@ export async function initComponents(): Promise<AppComponents> {
const mainRealmProvider = await createMainRealmProviderComponent({ logs, fetch, config })
const content = await createContentComponent({ fetch, config })

await instrumentHttpServerWithMetrics({ metrics, server, config })
await instrumentHttpServerWithPromClientRegistry({ metrics, server, config, registry: metrics.registry! })

return {
config,
Expand Down
3 changes: 2 additions & 1 deletion src/metrics.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { getDefaultHttpMetrics, validateMetricsDeclaration } from '@well-known-components/metrics'
import { validateMetricsDeclaration } from '@well-known-components/metrics'
import { getDefaultHttpMetrics } from '@well-known-components/http-server'
import { metricDeclarations as logsMetricsDeclarations } from '@well-known-components/logger'

export const metricDeclarations = {
Expand Down
42 changes: 29 additions & 13 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -690,6 +690,11 @@
"@nodelib/fs.scandir" "2.1.5"
fastq "^1.6.0"

"@opentelemetry/api@^1.4.0":
version "1.8.0"
resolved "https://registry.yarnpkg.com/@opentelemetry/api/-/api-1.8.0.tgz#5aa7abb48f23f693068ed2999ae627d2f7d902ec"
integrity sha512-I/s6F7yKUDdtMsoBWXJe8Qz40Tui5vsuKCWJEWVL+5q9sSWRzzx6v2KeNsOBEwd94j0eWkpWCH4yB6rZg9Mf0w==

"@pkgr/core@^0.1.0":
version "0.1.1"
resolved "https://registry.yarnpkg.com/@pkgr/core/-/core-0.1.1.tgz#1ec17e2edbec25c8306d424ecfbf13c7de1aaa31"
Expand Down Expand Up @@ -999,10 +1004,10 @@
"@well-known-components/interfaces" "^1.4.1"
cross-fetch "^3.1.5"

"@well-known-components/http-server@^2.0.0":
version "2.0.0"
resolved "https://registry.yarnpkg.com/@well-known-components/http-server/-/http-server-2.0.0.tgz#85ec93080ae64f962782699db3eeecd597f59405"
integrity sha512-baDP0+MpgqTnKLFFXS41WBbg9QIGCXTEA7BHf6JqW1evrTW10MKEx+rgEvQQlhCA5oXxUdKOD+xNnR3GqzGw9w==
"@well-known-components/http-server@^2.0.1-20240313124908.commit-80c33da":
version "2.0.1-20240313124908.commit-80c33da"
resolved "https://registry.yarnpkg.com/@well-known-components/http-server/-/http-server-2.0.1-20240313124908.commit-80c33da.tgz#8d5cdca3b39784b9fd4eb0702224b9a268444832"
integrity sha512-Po6/QodzvbzJYJydBg+8Ga3+JagGyfOm7o9Iweosr/SdfbdPY8+BmvfN3bLaNh0tOkT3UA6uvhqAD4ADCSKoaQ==
dependencies:
"@types/http-errors" "^2.0.1"
destroy "^1.2.0"
Expand All @@ -1022,17 +1027,27 @@
"@types/node-fetch" "^2.5.12"
typed-url-params "^1.0.1"

"@well-known-components/interfaces@^1.4.3":
version "1.4.3"
resolved "https://registry.yarnpkg.com/@well-known-components/interfaces/-/interfaces-1.4.3.tgz#026047966db480bd561a315fdc8116b88bf8d27a"
integrity sha512-roVtoOHG6uaH+nL4C0ISnAwkkopc2FLsS7fqX+roI22EdX9PAknPoImhPU8/3u6jgRAVpglX5Zj4nWZkSaXPkQ==
dependencies:
"@types/node" "^20.3.1"
"@types/node-fetch" "^2.5.12"
typed-url-params "^1.0.1"

"@well-known-components/logger@^3.1.2":
version "3.1.3"
resolved "https://registry.yarnpkg.com/@well-known-components/logger/-/logger-3.1.3.tgz#b1f4a76ac5e0d89c276cf339fe44a61f46023d2f"
integrity sha512-tTjD27CdfU4SVe+kPfjRbPSqdrw0Crg+M31RNejinCuMEBtEGbhYLtB1M4gn+PSTy2Oi3cI3iOdeQ1xVhMSerQ==

"@well-known-components/metrics@^2.0.1-20220909150423.commit-8f7e5bc":
version "2.0.1"
resolved "https://registry.yarnpkg.com/@well-known-components/metrics/-/metrics-2.0.1.tgz#b5f5410c3ba6e5658ef80926a1f7bd81d7aa1f56"
integrity sha512-jgT9TuxVS9GzVMMYWXNJRM2qXvexuf4xfrFNBYa3w+gqEWCK4Id5R4zBee/bm6/F5yIPauAWxbOS6KNNDBIrGw==
"@well-known-components/metrics@^2.0.2-20240314122215.commit-df469cb":
version "2.0.2-20240314122215.commit-df469cb"
resolved "https://registry.yarnpkg.com/@well-known-components/metrics/-/metrics-2.0.2-20240314122215.commit-df469cb.tgz#98546b0c57660a2df70f4e13bc7a8a870d56e70d"
integrity sha512-O7IGqEasy2ykv2YXaIHKRtCp9Tn12RbcqesV0lpjD0KW3Uj814Vi5OJWTlvsH1azSNvmvdVWoHN0pShDocwUrw==
dependencies:
prom-client "^14.1.0"
"@well-known-components/http-server" "^2.0.1-20240313124908.commit-80c33da"
prom-client "^15.1.0"

"@well-known-components/test-helpers@^1.5.6":
version "1.5.6"
Expand Down Expand Up @@ -3025,11 +3040,12 @@ pretty-format@^29.0.0, pretty-format@^29.7.0:
ansi-styles "^5.0.0"
react-is "^18.0.0"

prom-client@^14.1.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==
prom-client@^15.1.0:
version "15.1.0"
resolved "https://registry.yarnpkg.com/prom-client/-/prom-client-15.1.0.tgz#816a4a2128da169d0471093baeccc6d2f17a4613"
integrity sha512-cCD7jLTqyPdjEPBo/Xk4Iu8jxjuZgZJ3e/oET3L+ZwOuap/7Cw3dH/TJSsZKs1TQLZ2IHpIlRAKw82ef06kmMw==
dependencies:
"@opentelemetry/api" "^1.4.0"
tdigest "^0.1.1"

prompts@^2.0.1:
Expand Down

0 comments on commit c78eef9

Please sign in to comment.