Skip to content

java.lang.NoClassDefFoundError: com/amazonaws/auth/AWSCredentials with localstack module and AWS SDK2 #4279

@joshiste

Description

@joshiste

When using the AWS SDK v2 the com.amazonaws.auth.AWSCredentials class is not present and a java.lang.NoClassDefFoundError is thrown.

Imho either the local stack module should declare a dependency on the AWS SDK v1 or not use the classes at all. (I'd prefer the latter).

my current workaround, is to add the classes just for tests:

        <dependency>
            <groupId>com.amazonaws</groupId>
            <artifactId>aws-java-sdk-core</artifactId>
            <version>1.11.959</version>
            <scope>test</scope>
            <exclusions>
                <exclusion>
                    <groupId>*</groupId>
                    <artifactId>*</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions