Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Duplicate
-
4.0.1
-
None
-
None
Description
To work around a DynamoDB SDK bug that just turned one, I created an attribute converter that ignores MetaClass and an AnnotationCollector that applies it to record classes with some other usual POJO bits.
The annotation collector is in the same package as the converter-prvider Java class. Running the stub generator produces this output (line breaks added):
@groovy.transform.AnnotationCollector() @software.amazon.awssdk.enhanced.dynamodb.mapper.annotations.DynamoDbBean(converterProviders={IgnoreMetaClassAttributeConverterProvider,software.amazon.awssdk.enhanced.dynamodb.DefaultAttributeConverterProvider.class}) @groovy.transform.stc.POJO() @java.lang.annotation.Retention(value=java.lang.annotation.RetentionPolicy.SOURCE) @java.lang.annotation.Target(value=java.lang.annotation.ElementType.TYPE) public @interface DynamoDbRecord2{;}
Note the missing .class on the first class argument (which is not imported and is present in the same package, but is a Java file).
Attachments
Issue Links
- duplicates
-
GROOVY-8184 Class constant withouts .class in annotation value resolves as VariableExpression
- Closed
- relates to
-
GROOVY-10996 Compilation issue in Groovy 4
- Closed