Skip to content

Conversation

@itssimon
Copy link
Member

@itssimon itssimon commented Jan 29, 2026

Summary by CodeRabbit

Release Notes

Removed Features

  • Request tracing and distributed span collection have been removed from the request logging system.

Configuration Changes

  • The tracing-enabled configuration option in request logging settings has been removed. Please remove this setting from your configuration files if present to ensure compatibility.

✏️ Tip: You can customize this high-level summary in your review settings.

@itssimon itssimon self-assigned this Jan 29, 2026
@coderabbitai
Copy link

coderabbitai bot commented Jan 29, 2026

Walkthrough

This pull request removes OpenTelemetry tracing support from the codebase. Changes include deletion of SpanCollector and ApitallySpanCollector classes, removal of tracing configuration options, elimination of spans and traceId from logging request objects, updates to request logging APIs, and corresponding test adjustments.

Changes

Cohort / File(s) Summary
Configuration & Build
README.md, pom.xml, src/test/resources/application.yml
Removed tracing-enabled configuration option and OpenTelemetry SDK dependency (io.opentelemetry:opentelemetry-sdk v1.58.0).
Tracing Implementation
src/main/java/io/apitally/common/SpanCollector.java, src/main/java/io/apitally/spring/ApitallySpanCollector.java
Deleted entire SpanCollector and ApitallySpanCollector classes (257 total lines), eliminating span collection, serialization, and tracer initialization logic.
Request Logging & Configuration
src/main/java/io/apitally/common/RequestLoggingConfig.java, src/main/java/io/apitally/common/RequestLogger.java, src/main/java/io/apitally/common/dto/RequestLogItem.java
Removed tracingEnabled field/accessors from RequestLoggingConfig; removed spans and traceId from RequestLogItem fields and constructor; updated RequestLogger to accept only request, response, exception, and logs (eliminated spans and traceId parameters).
Client Integration
src/main/java/io/apitally/common/ApitallyClient.java, src/main/java/io/apitally/spring/ApitallyAutoConfiguration.java, src/main/java/io/apitally/spring/ApitallyFilter.java
Removed spanCollector field from ApitallyClient; removed delegate wiring in ApitallyAutoConfiguration; simplified ApitallyFilter to remove span creation, finalization, and shouldCaptureSpans flag.
Tests
src/test/java/io/apitally/common/.../ApitallyClientTest.java, src/test/java/io/apitally/common/.../RequestLoggerTest.java, src/test/java/io/apitally/common/.../SpanCollectorTest.java, src/test/java/io/apitally/spring/.../ApitallyFilterTest.java, src/test/java/io/apitally/spring/app/TestController.java
Deleted SpanCollectorTest.java (164 lines); updated remaining tests to remove tracing setup, assertions on spans/trace_id, and OpenTelemetry instrumentation; adjusted logRequest call signatures to four parameters.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Remove tracing' directly and accurately summarizes the primary change across all modified files, which comprehensively removes tracing functionality from the codebase.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch remove-span-collector

Tip

🧪 Unit Test Generation v2 is now available!

We have significantly improved our unit test generation capabilities.

To enable: Add this to your .coderabbit.yaml configuration:

reviews:
  finishing_touches:
    unit_tests:
      enabled: true

Try it out by using the @coderabbitai generate unit tests command on your code files or under ✨ Finishing Touches on the walkthrough!

Have feedback? Share your thoughts on our Discord thread!


Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (3)
src/main/java/io/apitally/common/RequestLogger.java (1)

12-12: Remove unused import.

The SpanData import is no longer used after removing tracing functionality. This is likely causing the Spotless formatting check failure.

🧹 Proposed fix
-import io.apitally.common.dto.SpanData;
src/main/java/io/apitally/spring/ApitallyFilter.java (1)

13-13: Remove unused import.

The SpanData import is no longer used after removing span tracing functionality from the filter.

🧹 Proposed fix
-import io.apitally.common.dto.SpanData;
src/test/java/io/apitally/common/RequestLoggerTest.java (1)

14-14: Remove unused import.

The SpanData import is no longer used after removing tracing-related test code. This is likely contributing to the Spotless formatting check failure.

🧹 Proposed fix
-import io.apitally.common.dto.SpanData;

@codecov
Copy link

codecov bot commented Jan 29, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.47%. Comparing base (334e922) to head (f360021).

Additional details and impacted files
@@             Coverage Diff              @@
##               main      #60      +/-   ##
============================================
- Coverage     79.01%   77.47%   -1.54%     
+ Complexity      408      363      -45     
============================================
  Files            39       37       -2     
  Lines          1396     1252     -144     
  Branches        172      153      -19     
============================================
- Hits           1103      970     -133     
- Misses          190      197       +7     
+ Partials        103       85      -18     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants