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

Redis Cache: improve the API consistency #43468

Merged
merged 1 commit into from
Sep 24, 2024

Conversation

Ladicek
Copy link
Contributor

@Ladicek Ladicek commented Sep 24, 2024

All the get* methods in the RedisCache API now have 3 variants:

  • not accepting value type, using the configured default
  • accepting value type as a Class
  • accepting value type as a TypeLiteral

Internally, all these methods delegate to an implementation that takes a Type.

The error message about the default value type was also consolidated into a single place, the enforceDefaultType() method.

Follows up on #43320

Copy link
Member

@cescoffier cescoffier left a comment

Choose a reason for hiding this comment

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

That's nice!

This comment has been minimized.

All the `get*` methods in the `RedisCache` API now have 3 variants:

- not accepting value type, using the configured default
- accepting value type as a `Class`
- accepting value type as a `TypeLiteral`

Internally, all these methods delegate to an implementation
that takes a `Type`.

The error message about the default value type was also consolidated
into a single place, the `enforceDefaultType()` method.
@Ladicek Ladicek force-pushed the redis-cache-improve-api branch from 640f169 to 8501412 Compare September 24, 2024 14:38
Copy link

quarkus-bot bot commented Sep 24, 2024

Status for workflow Quarkus CI

This is the status report for running Quarkus CI on commit 8501412.

✅ The latest workflow run for the pull request has completed successfully.

It should be safe to merge provided you have a look at the other checks in the summary.

You can consult the Develocity build scans.

@cescoffier cescoffier merged commit 685cdea into quarkusio:main Sep 24, 2024
20 checks passed
@quarkus-bot quarkus-bot bot added this to the 3.16 - main milestone Sep 24, 2024
@Ladicek Ladicek deleted the redis-cache-improve-api branch September 24, 2024 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants