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

Wrong class in CDI Extensions Check #228

Closed
stefanorg opened this issue Jan 21, 2019 · 2 comments
Closed

Wrong class in CDI Extensions Check #228

stefanorg opened this issue Jan 21, 2019 · 2 comments
Milestone

Comments

@stefanorg
Copy link

stefanorg commented Jan 21, 2019

Hi i think that this:

if (type instanceof Class<?> && AmazonDynamoDBClient.class.isAssignableFrom((Class<?>) type)) {

should be

... && AmazonDynamoDB.class ...

This way in a CDI context i can have a Producer of AmazonDynamoDB:

@Bean @Produces
    public AmazonDynamoDB amazonDynamoDB() {
//        return AmazonDynamoDBClientBuilder
//          .standard()
//          .withCredentials(amazonAWSCredentialsProvider())
//          .withRegion(Regions.EU_WEST_1).build();

        return AmazonDaxClientBuilder
          .standard()
          .withCredentials(amazonAWSCredentialsProvider())
          .withRegion(Regions.EU_WEST_1)
          .withEndpointConfiguration("**********************************")
          .build();


    }

Thanks

@derjust derjust added this to the 5.1.0 milestone Jan 23, 2019
derjust added a commit that referenced this issue Jan 23, 2019
Resort to interface to be more flexible
@derjust
Copy link
Owner

derjust commented Jan 23, 2019

Yes, resorting to the interface is all we need - no need to be that 'specific'

Will be part of 5.1.0 (Available as part of 5.1.0-SNAPSHOT as of now)

@derjust derjust closed this as completed Jan 23, 2019
@stefanorg
Copy link
Author

Hi i'm not able to see this fix in 5.1.0 branch.

https://github.com/derjust/spring-data-dynamodb/blob/v5.1.0/src/main/java/org/socialsignin/spring/data/dynamodb/repository/cdi/DynamoDBRepositoryExtension.java

Do you need a pull request for this?
When do you think this can be fixed?

Thank for your work 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants