Skip to content

fix: partial write support and default write endpoint#388

Open
alespour wants to merge 9 commits into
mainfrom
fix/partial-writes
Open

fix: partial write support and default write endpoint#388
alespour wants to merge 9 commits into
mainfrom
fix/partial-writes

Conversation

@alespour
Copy link
Copy Markdown
Contributor

@alespour alespour commented May 19, 2026

Proposed Changes

This PR finalizes partial-write support and fixes regression issue with the default API endpoint behavior introduced in PR #365.

  • The client defaults to the V2 API endpoint for writes for broad product compatibility. Since the Java client has not been released yet with the PR feat: support partial writes #365 behavior, this change is not breaking.
  • V3 API-only options:
    • noSync
    • acceptPartial

Checklist

  • CHANGELOG.md updated
  • Rebased/mergeable
  • A test has been added if appropriate
  • Tests pass
  • Commit messages are conventional

@codecov
Copy link
Copy Markdown

codecov Bot commented May 19, 2026

Codecov Report

❌ Patch coverage is 91.66667% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 88.29%. Comparing base (e634c9c) to head (1bf2242).

Files with missing lines Patch % Lines
...nfluxdb/v3/client/internal/InfluxDBClientImpl.java 77.77% 0 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #388      +/-   ##
==========================================
+ Coverage   88.25%   88.29%   +0.04%     
==========================================
  Files          21       21              
  Lines        1532     1546      +14     
  Branches      277      279       +2     
==========================================
+ Hits         1352     1365      +13     
- Misses         82       83       +1     
  Partials       98       98              

☔ 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.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR restores V2 write endpoint defaults while preserving V3-only partial-write and noSync support behind useV2Api=false.

Changes:

  • Defaults write routing to the V2 API endpoint and updates related tests/expectations.
  • Refines V2/V3 method-not-allowed error messages and partial-write error formatting.
  • Updates README and changelog language around partial writes and endpoint compatibility.

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/main/java/com/influxdb/v3/client/write/WriteOptions.java Changes default write endpoint selection to V2 and updates validation/docs.
src/main/java/com/influxdb/v3/client/internal/InfluxDBClientImpl.java Adds endpoint-specific 405 guidance for V2 and V3 writes.
src/main/java/com/influxdb/v3/client/internal/RestClient.java Adjusts partial-write detail rendering and fallback JSON token formatting.
src/main/java/com/influxdb/v3/client/InfluxDBClient.java Updates public configuration documentation.
src/main/java/com/influxdb/v3/client/config/ClientConfig.java Updates write endpoint configuration documentation.
src/test/java/... Updates and expands tests for defaults, routing, validation, and error formatting.
README.md Documents default V2 writes and V3-only write options.
CHANGELOG.md Records partial-write support and V2 default behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread README.md Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@alespour alespour marked this pull request as ready for review May 19, 2026 19:17
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