Skip to content

Commit

Permalink
Upgrade to Jackson 2.18
Browse files Browse the repository at this point in the history
* Fix `ObservationTests` for the latest changes with default tags.
Related to: #2814
  • Loading branch information
artembilan committed Oct 1, 2024
1 parent a597c15 commit cbc2eb3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ ext {
commonsPoolVersion = '2.12.0'
hamcrestVersion = '2.2'
hibernateValidationVersion = '8.0.1.Final'
jacksonBomVersion = '2.17.2'
jacksonBomVersion = '2.18.0'
jaywayJsonPathVersion = '2.9.0'
junit4Version = '4.13.2'
junitJupiterVersion = '5.11.1'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@
/**
* @author Gary Russell
* @author Ngoc Nhan
* @author Artem Bilan
*
* @since 3.0
*
*/
Expand All @@ -91,17 +93,17 @@ void endToEnd(@Autowired Listener listener, @Autowired RabbitTemplate template,
SimpleSpan span = spans.poll();
assertThat(span.getTags()).containsEntry("spring.rabbit.template.name", "template");
assertThat(span.getName()).isEqualTo("/observation.testQ1 send");
await().until(() -> spans.peekFirst().getTags().size() == 3);
await().until(() -> spans.peekFirst().getTags().size() == 5);
span = spans.poll();
assertThat(span.getTags())
.containsAllEntriesOf(
Map.of("spring.rabbit.listener.id", "obs1", "foo", "some foo value", "bar", "some bar value"));
assertThat(span.getName()).isEqualTo("observation.testQ1 receive");
await().until(() -> spans.peekFirst().getTags().size() == 1);
await().until(() -> spans.peekFirst().getTags().size() == 3);
span = spans.poll();
assertThat(span.getTags()).containsEntry("spring.rabbit.template.name", "template");
assertThat(span.getName()).isEqualTo("/observation.testQ2 send");
await().until(() -> spans.peekFirst().getTags().size() == 3);
await().until(() -> spans.peekFirst().getTags().size() == 5);
span = spans.poll();
assertThat(span.getTags())
.containsAllEntriesOf(
Expand Down Expand Up @@ -141,7 +143,7 @@ public KeyValues getLowCardinalityKeyValues(RabbitMessageReceiverContext context
assertThat(span.getTags()).containsEntry("messaging.destination.name", "");
assertThat(span.getTags()).containsEntry("messaging.rabbitmq.destination.routing_key", "observation.testQ1");
assertThat(span.getName()).isEqualTo("/observation.testQ1 send");
await().until(() -> spans.peekFirst().getTags().size() == 4);
await().until(() -> spans.peekFirst().getTags().size() == 6);
span = spans.poll();
assertThat(span.getTags())
.containsAllEntriesOf(Map.of("spring.rabbit.listener.id", "obs1", "foo", "some foo value", "bar",
Expand All @@ -154,7 +156,7 @@ public KeyValues getLowCardinalityKeyValues(RabbitMessageReceiverContext context
assertThat(span.getTags()).containsEntry("messaging.destination.name", "");
assertThat(span.getTags()).containsEntry("messaging.rabbitmq.destination.routing_key", "observation.testQ2");
assertThat(span.getName()).isEqualTo("/observation.testQ2 send");
await().until(() -> spans.peekFirst().getTags().size() == 3);
await().until(() -> spans.peekFirst().getTags().size() == 5);
span = spans.poll();
assertThat(span.getTags())
.containsAllEntriesOf(
Expand Down

0 comments on commit cbc2eb3

Please sign in to comment.