Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update readme, link to prometheus-akka-http #2

Merged
merged 4 commits into from
Jan 25, 2024
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
17 changes: 6 additions & 11 deletions .github/workflows/scala.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,13 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Scala
uses: olafurpg/setup-scala@v11
uses: actions/checkout@v4
- name: Set up Java
uses: actions/setup-java@v4
with:
java-version: [email protected]
- name: Cache sbt
uses: actions/cache@v2
with:
path: |
~/.ivy2/cache
~/.sbt
key: ${{ runner.os }}-sbt-${{ hashFiles('**/build.sbt') }}
distribution: temurin
java-version: 17.0.8
cache: sbt
- name: Check format
run: sbt scalafmtCheckAll
- name: Run tests
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@

Collection of utilities to allow exposing prometheus metrics from pekko-http endpoint using the prometheus java client

"com.varwise" %% "prometheus-pekko-http" % "0.6.0"
"com.varwise" %% "prometheus-pekko-http" % "1.0.0"

### Related projects

[prometheus-akka-http](https://github.com/varwise/prometheus-akka-http) - same thing but for akka-http

### Publishing

Expand Down
10 changes: 5 additions & 5 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@ libraryDependencies ++= {
("org.apache.pekko" %% "pekko-stream" % pekkoVersion % Provided).cross(CrossVersion.for3Use2_13),
("org.apache.pekko" %% "pekko-http" % pekkoHttpVersion % Provided).cross(CrossVersion.for3Use2_13),
("org.apache.pekko" %% "pekko-http-spray-json" % pekkoHttpVersion % Provided).cross(CrossVersion.for3Use2_13),
"io.prometheus" % "simpleclient" % simpleclientVersion,
"io.prometheus" % "simpleclient_common" % simpleclientVersion,
("org.apache.pekko" %% "pekko-testkit" % pekkoVersion % Test).cross(CrossVersion.for3Use2_13),
("org.apache.pekko" %% "pekko-http-testkit" % pekkoHttpVersion % Test).cross(CrossVersion.for3Use2_13),
"org.scalatest" %% "scalatest" % scalaTestVersion % Test
"io.prometheus" % "simpleclient" % simpleclientVersion,
"io.prometheus" % "simpleclient_common" % simpleclientVersion,
("org.apache.pekko" %% "pekko-testkit" % pekkoVersion % Test).cross(CrossVersion.for3Use2_13),
("org.apache.pekko" %% "pekko-http-testkit" % pekkoHttpVersion % Test).cross(CrossVersion.for3Use2_13),
"org.scalatest" %% "scalatest" % scalaTestVersion % Test
)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class PrometheusResponseTimeRecorderSpec extends AnyFlatSpec with Matchers {
labelNames: List[String],
labelValues: List[String],
bucket: Double
): Int = {
): Int = {
val name = metricName + "_bucket"

// 'le' should be the first label in the list
Expand Down