-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Cannot used Lombok @Builder with @Introspected in 4.7.1 #11432
Comments
It's very likely related to #11347 @graemerocher |
does |
yes, this one works
|
so previously it was using the constructor of the type to instantiate it I guess now it goes through the builder. Seems weird to combine 2 different ways to construct the object (builder and no args constructor) but maybe that is just me. |
We often combine these as each of the approaches has different use cases:
|
There is also a similar issue when using record entities with automatic timestamps:
The introspection writer marks the |
I am afraid that my issue is not related to Lombok or introspected, but I have entities with Jakarta persistence API annotations combined with some @transient annotation from micronaut which I did to solve the entity binding issue. It is working on version 4.6.2. Now seems like updating to 4.7.2 does not support this. Any idea what changed! |
I am looking into it. Thanks. |
@aoyanb probably the same issue |
@aoyanb I recommend you create an example that reproduces the issue in an issue report. Thanks. |
Expected Behavior
Given the simple POJO class using Lombok
@Builder
annotation with@NoArgsConstructor
and@Introspected
annotation then the introspection is generated and the class can be instantiated using theBeanIntrospector
API.This was working without issues in
4.7.0
and before.Actual Behaviour
When trying to instantiate the class using
BeanIntrospection
API then I got following errorSteps To Reproduce
Run
IntrospectionTest
in the example applicationor
4.7.1
Micronaut application with Lombok supportmn create-app --build=gradle_kotlin --jdk=21 --lang=java --test=junit --features=lombok com.example.demo
POJO
class from the Expected Behaviour descriptionInstrospectionTest
with the test method from the Expected Behavior descriptionEnvironment Information
Operating system macOS 15.0.1 (aarch64)
Java runtime Azul Zulu OpenJDK Runtime Environment 21.0.5+11-LTS
Java VM Azul Zulu OpenJDK 64-Bit Server VM 21.0.5+11-LTS (mixed mode, sharing)
see https://scans.gradle.com/s/6avzotdmjfhg4#infrastructure
Example Application
https://github.com/musketyr/micronaut-4.7.1-introspection-issue
Version
4.7.1
The text was updated successfully, but these errors were encountered: