ManageIQ / manageiq-api-client

Ruby client library to the ManageIQ REST API
MIT License
11 stars 26 forks source link

upgrade faraday from 1.0 to 2.0 #122

Closed kbrock closed 7 months ago

kbrock commented 7 months ago

faraday 2.0 uses different middleware. Upgraded to use follow_redirects.

faraday 2.0 has been split up to use many http client libraries Using net-http, so this avoids requiring a dozen adapter gems


I would like to test this with tasks to ensure it all still works

Faraday 2.0 only supports ruby 3.0 and higher. had to drop testing (and supporting) ruby 2.7

kbrock commented 7 months ago

@Fryguy I'm good with this now

Fryguy commented 7 months ago

@kbrock damn - I just merged this but it does have me concerned now. I recently was using a different gem that had faraday locked to 2.x, and it caused mismatches. I checked ManageIQ core, and this will break core if we release it.

In our case, manageiq core includes manageiq-api-client [ref]. However, other gems include faraday locked to <2.0:

A number of other gems are <3.0 which are probably fine such as google-cloud-env, google-cloud-auth, and signet.

I think the best way forward is to somehow support both 1.x and 2.x in the same way that the google-cloud-env, google-cloud-auth, and signet gems some how do.

Fryguy commented 7 months ago

@kbrock fixed my concerns in https://github.com/ManageIQ/manageiq-api-client/pull/124