RedHatInsights / insights-core

Insights Core is a data collection and processing framework used by Red Hat Insights
https://cloud.redhat.com/insights
Apache License 2.0
153 stars 183 forks source link

feat: drop URLCache and associated code #4173

Closed ptoscano closed 4 months ago

ptoscano commented 4 months ago

All Pull Requests:

Check all that apply:

Complete Description of Additions/Changes:

URLCache was used to cache the results of HTTP calls with a certain ETag, using the cached ETag to let the server know about not returning data if nothing changed. That's the theory, which seems good at first.

In practice, there are a number of factors:

Because of the reasons above, URLCache has a very little value, if not even creating potential issues. Hence, drop it completely, and do GET calls directly, just like done everywhere else in the client.

From an implementation POV:

Jira ID: CCT-617 Jira ID: RHINENG-11707

[1] https://docs.python.org/3/library/pickle.html#pickle.Unpickler [2] https://issues.redhat.com/browse/RHEL-49738

m-horky commented 4 months ago

Hi @xiangce this PR is can be merged.