From 9b1fc49798631f01b3ac5c23ff8412abedd588bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jegors=20=C4=8Cemisovs?= Date: Sun, 17 Mar 2024 11:18:44 +0200 Subject: [PATCH] Update endpoint id from 'count' to 'counter' The 'count' endpoint id was updated to 'counter' across the application. This change has been applied across all instances in the HTTP calls and in the TranslationCountEndpoint class. The pom.xml file also got updated by increasing the groovy version and removing the jmeter-maven-plugin configuration. --- bruno/actuator/Reset Translation Counter.bru | 2 +- bruno/actuator/Show Translation Counter.bru | 2 +- .../Check Translation Counter.bru | 2 +- .../Reset Translation Counter.bru | 2 +- .../translation-counter/Second Check.bru | 2 +- .../Set Translation Counter.bru | 2 +- .../Validate Translation Counter.bru | 2 +- .../Zero Translation Counter.bru | 2 +- http-client/poc/increase-counter.http | 2 +- http-client/scenario/translation-counter.http | 2 +- .../actuator/reset-translation-counter.http | 2 +- .../actuator/show-translation-counter.http | 2 +- http-yac/poc/increase-counter.http | 2 +- http-yac/scenario/translation-counter.http | 2 +- hurl/translation-counter.hurl | 12 +++---- pom.xml | 34 +------------------ .../actuator/TranslationCountEndpoint.java | 2 +- 17 files changed, 22 insertions(+), 54 deletions(-) diff --git a/bruno/actuator/Reset Translation Counter.bru b/bruno/actuator/Reset Translation Counter.bru index 023c598..48b9818 100644 --- a/bruno/actuator/Reset Translation Counter.bru +++ b/bruno/actuator/Reset Translation Counter.bru @@ -5,7 +5,7 @@ meta { } delete { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/bruno/actuator/Show Translation Counter.bru b/bruno/actuator/Show Translation Counter.bru index d55b182..d4770e0 100644 --- a/bruno/actuator/Show Translation Counter.bru +++ b/bruno/actuator/Show Translation Counter.bru @@ -5,7 +5,7 @@ meta { } get { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/bruno/scenario/translation-counter/Check Translation Counter.bru b/bruno/scenario/translation-counter/Check Translation Counter.bru index c376b2d..a1e0c61 100644 --- a/bruno/scenario/translation-counter/Check Translation Counter.bru +++ b/bruno/scenario/translation-counter/Check Translation Counter.bru @@ -5,7 +5,7 @@ meta { } get { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/bruno/scenario/translation-counter/Reset Translation Counter.bru b/bruno/scenario/translation-counter/Reset Translation Counter.bru index f5ea942..0c4db55 100644 --- a/bruno/scenario/translation-counter/Reset Translation Counter.bru +++ b/bruno/scenario/translation-counter/Reset Translation Counter.bru @@ -5,7 +5,7 @@ meta { } delete { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/bruno/scenario/translation-counter/Second Check.bru b/bruno/scenario/translation-counter/Second Check.bru index edd0872..6030091 100644 --- a/bruno/scenario/translation-counter/Second Check.bru +++ b/bruno/scenario/translation-counter/Second Check.bru @@ -5,7 +5,7 @@ meta { } get { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/bruno/scenario/translation-counter/Set Translation Counter.bru b/bruno/scenario/translation-counter/Set Translation Counter.bru index 496a5cf..0cef2f0 100644 --- a/bruno/scenario/translation-counter/Set Translation Counter.bru +++ b/bruno/scenario/translation-counter/Set Translation Counter.bru @@ -5,7 +5,7 @@ meta { } post { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: json auth: none } diff --git a/bruno/scenario/translation-counter/Validate Translation Counter.bru b/bruno/scenario/translation-counter/Validate Translation Counter.bru index 4259921..fa1138c 100644 --- a/bruno/scenario/translation-counter/Validate Translation Counter.bru +++ b/bruno/scenario/translation-counter/Validate Translation Counter.bru @@ -5,7 +5,7 @@ meta { } get { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/bruno/scenario/translation-counter/Zero Translation Counter.bru b/bruno/scenario/translation-counter/Zero Translation Counter.bru index 433b253..b256dee 100644 --- a/bruno/scenario/translation-counter/Zero Translation Counter.bru +++ b/bruno/scenario/translation-counter/Zero Translation Counter.bru @@ -5,7 +5,7 @@ meta { } get { - url: {{host}}/actuator/count + url: {{host}}/actuator/counter body: none auth: none } diff --git a/http-client/poc/increase-counter.http b/http-client/poc/increase-counter.http index e4a9bbb..7f1ada9 100644 --- a/http-client/poc/increase-counter.http +++ b/http-client/poc/increase-counter.http @@ -1,4 +1,4 @@ -@sut = actuator/count +@sut = actuator/counter ### Read Translation Counter GET {{host}}/{{sut}} diff --git a/http-client/scenario/translation-counter.http b/http-client/scenario/translation-counter.http index 9dd3358..67dcb22 100644 --- a/http-client/scenario/translation-counter.http +++ b/http-client/scenario/translation-counter.http @@ -1,4 +1,4 @@ -@sut = actuator/count +@sut = actuator/counter ### Reset Translation Counter DELETE {{host}}/{{sut}} diff --git a/http-yac/actuator/reset-translation-counter.http b/http-yac/actuator/reset-translation-counter.http index 576507d..3c3f78e 100644 --- a/http-yac/actuator/reset-translation-counter.http +++ b/http-yac/actuator/reset-translation-counter.http @@ -1,3 +1,3 @@ -DELETE {{host}}/actuator/translation-count +DELETE {{host}}/actuator/counter ?? status == 204 diff --git a/http-yac/actuator/show-translation-counter.http b/http-yac/actuator/show-translation-counter.http index 91e2912..89d6e65 100644 --- a/http-yac/actuator/show-translation-counter.http +++ b/http-yac/actuator/show-translation-counter.http @@ -1,4 +1,4 @@ -{{host}}/actuator/translation-count +{{host}}/actuator/counter ?? status == 200 ?? body count isNumber diff --git a/http-yac/poc/increase-counter.http b/http-yac/poc/increase-counter.http index d679e88..de32e2b 100644 --- a/http-yac/poc/increase-counter.http +++ b/http-yac/poc/increase-counter.http @@ -1,4 +1,4 @@ -@sut = actuator/translation-count +@sut = actuator/counter ### Read Translation Counter # @name translationCounter diff --git a/http-yac/scenario/translation-counter.http b/http-yac/scenario/translation-counter.http index a7633a6..84791c8 100644 --- a/http-yac/scenario/translation-counter.http +++ b/http-yac/scenario/translation-counter.http @@ -1,4 +1,4 @@ -@sut = actuator/count +@sut = actuator/counter ### Reset Translation Counter DELETE {{host}}/{{sut}} diff --git a/hurl/translation-counter.hurl b/hurl/translation-counter.hurl index 0495523..e4f05d6 100644 --- a/hurl/translation-counter.hurl +++ b/hurl/translation-counter.hurl @@ -1,9 +1,9 @@ # Reset Translation Counter -DELETE {{host}}/actuator/count +DELETE {{host}}/actuator/counter HTTP 204 # Zero Translation Counter -GET {{host}}/actuator/count +GET {{host}}/actuator/counter HTTP 200 [Asserts] header "Content-Type" contains "json" @@ -23,7 +23,7 @@ Content-Type: application/json jsonpath "$.sentence" == "ellohay, orldway!" # Check Translation Counter -GET {{host}}/actuator/count +GET {{host}}/actuator/counter HTTP 200 [Asserts] jsonpath "$.count" == 1 @@ -42,13 +42,13 @@ Content-Type: application/json jsonpath "$.sentence" == "ethay ickquay ownbray oxfay umpsjay overay ethay azylay ogday." # Second Counter Check -GET {{host}}/actuator/count +GET {{host}}/actuator/counter HTTP 200 [Asserts] jsonpath "$.count" == 2 # Set Translation Counter -POST {{host}}/actuator/count +POST {{host}}/actuator/counter Content-Type: application/json {"count": 9} @@ -58,7 +58,7 @@ HTTP 200 jsonpath "$.count" == 9 # Check Changed Counter -GET {{host}}/actuator/count +GET {{host}}/actuator/counter HTTP 200 [Asserts] jsonpath "$.count" == 9 diff --git a/pom.xml b/pom.xml index eb1b76b..7209b61 100644 --- a/pom.xml +++ b/pom.xml @@ -89,7 +89,7 @@ 17 - 4.0.18 + 4.0.20 2.2.20 5.10.3 @@ -537,38 +537,6 @@ maven-failsafe-plugin - - - com.lazerycode.jmeter - jmeter-maven-plugin - - - - configuration - - configure - - - - - jmeter-tests - - jmeter - - - - - jmeter-check-results - - results - - - - - true - 5.6.3 - - diff --git a/src/main/java/lv/id/jc/piglatin/actuator/TranslationCountEndpoint.java b/src/main/java/lv/id/jc/piglatin/actuator/TranslationCountEndpoint.java index d5bc7b4..0aaad8c 100644 --- a/src/main/java/lv/id/jc/piglatin/actuator/TranslationCountEndpoint.java +++ b/src/main/java/lv/id/jc/piglatin/actuator/TranslationCountEndpoint.java @@ -15,7 +15,7 @@ * It provides methods for reading, setting, and resetting the translation count. */ @Component -@Endpoint(id = "count") +@Endpoint(id = "counter") public class TranslationCountEndpoint { private final AtomicInteger counterService;