-
-
Notifications
You must be signed in to change notification settings - Fork 301
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
Fixes #768 #897
base: main
Are you sure you want to change the base?
Fixes #768 #897
Conversation
Reopening from #772 that for some reason was closed. Code review requested changes were applied |
Tnx on PR. Will try to look at it during the weekend. |
Any updates? |
Any updates here? We would appreciate this to facilitate upgrade to Spring Boot 3 |
Hey @driverpt , sorry for late response. I am finally done with all the things that I had waiting personally I will be having more time for open source. Expect review soon! |
static class DynamoDbTemplateConfiguration { | ||
@ConditionalOnMissingBean(DynamoDbOperations.class) | ||
@Bean | ||
public DynamoDbTemplate dynamoDBTemplate(DynamoDbProperties properties, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should think about creating DynamoDbAsyncTemplate
This is just a note, not required for this PR.
@maciejwalkowiak I think we can merge this one and release it in 3.0.3 |
@@ -101,31 +131,61 @@ static class StandardDynamoDbClient { | |||
|
|||
@ConditionalOnMissingBean | |||
@Bean | |||
public DynamoDbClient dynamoDbClient(AwsClientBuilderConfigurer awsClientBuilderConfigurer, | |||
public DynamoDbClient standardDynamoDbClient(AwsClientBuilderConfigurer awsClientBuilderConfigurer, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changing bean names makes it a breaking change, in such case it would have to be included in 3.1.0. Perhaps we can leave bean names as they were?
|
||
configuration.region(AwsClientBuilderConfigurer.resolveRegion(properties, regionProvider)) | ||
.credentialsProvider(credentialsProvider).url(properties.getDax().getUrl()); | ||
return ClusterDaxClient.builder().overrideConfiguration(configuration.build()).build(); | ||
} | ||
|
||
@ConditionalOnMissingBean | ||
@Bean | ||
public DynamoDbAsyncClient daxDynamoDbAsyncClient(DynamoDbProperties properties, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for PR @driverpt!
You sneaked in async client ;-) Is there a particular reason for that?
As much as we do want to autoconfigure async clients we need to think how to do it consistently in every module so that we don't create beans that consume resources without users knowing about it or needing it.
One of the principles of 3.0 was to not create more than needed in contract to 2.x, so we need to be careful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because in the project we just upgraded to Spring Boot 3, we use WebFlux + Async Clients :)
I think it's harmless because it has @ConditionalOnBean
+1 on this issue. I'm looking for the async version for a webflux project as well. |
Is this going to be merged anytime soon? |
📢 Type of change
📜 Description
Issue: #768 #769
DynamoDb Clients are now initialized Standalone
💡 Motivation and Context
We do not use Spring Data and just wanted simple DynamoDb Initialization
💚 How did you test it?
Integration Tests
📝 Checklist
🔮 Next steps