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

Breaking change in 4.12.0 due to RestSharp update to 109+ #515

Open
shuebner opened this issue May 4, 2023 · 2 comments
Open

Breaking change in 4.12.0 due to RestSharp update to 109+ #515

shuebner opened this issue May 4, 2023 · 2 comments
Labels
question Further information is requested

Comments

@shuebner
Copy link

shuebner commented May 4, 2023

Steps to reproduce:

Use version 4.11.0 and set a BaseUrl:

ApiClient.RestClient.BaseUrl = new Uri("http://some.url")

Upgrade to 4.12.0.

The code no longer builds even though the version upgrade was minor.

Expected behavior:

Either hide your third-party implementation details behind an interface.
Or be aware of breaking changes in your own API via third-party library changes and increase your major version accordingly.

Actual behavior:

RestSharp made a breaking change to RestClient in SHA1:507ed8 and increased heir major version to 109 accordingly.
RestSharp as part of the influx client API was updated from 108.0.1 to 110.1.0 (i. e. >=109) between influx client 4.11.0 and 4.12.0.
Even though this is a breaking API change for influx client as well, there was no major version increase.

Specifications:

  • Client Version: 4.12.0
  • InfluxDB Version: irrelevant
  • Platform: irrelevant
@bednar
Copy link
Contributor

bednar commented May 4, 2023

Hi @shuebner,

thanks for using our client,

How do you access to the ApiClient? The ApiClient is internal property of the InfluxDBClient:

private readonly ApiClient _apiClient;
.

You should set url via constructor:

const string url = "http://localhost:8086";
const string token = "my-token";

using var client = new InfluxDBClient(url, token)

Regards

@bednar bednar added the question Further information is requested label May 4, 2023
@shuebner
Copy link
Author

shuebner commented May 4, 2023

This has nothing to do with either InfluxDBClient or the URL, but only ApiClient. The class ApiClient is public as is the RestClient property. This makes it part of the public API of the influx client library.
Influx published a breaking change in its API under a minor version increment.
That is unexpected and -- when following semver rules -- wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants