-
Notifications
You must be signed in to change notification settings - Fork 4
Refactor sample server StatementEntity to use Lombok and revert dd04a64 #462
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
Refactor sample server StatementEntity to use Lombok and revert dd04a64 #462
Conversation
Co-authored-by: thomasturrell <1552612+thomasturrell@users.noreply.github.com>
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.
Pull request overview
This PR modernizes the xapi-server sample by refactoring StatementEntity to use Lombok annotations and reverts an incorrect addition of Lombok configuration to the xapi-model-spring-boot-starter core module.
- Reduces
StatementEntityboilerplate from 79 to 34 lines using@Data,@NoArgsConstructor, and@AllArgsConstructor - Removes incorrectly added Lombok configuration from xapi-model-spring-boot-starter (commit dd04a64)
- Adds Lombok usage documentation to the xapi-server README with IDE setup guidance
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
xapi-model-spring-boot-starter/src/test/java/dev/learning/xapi/autoconfigure/model/LombokProcessingTests.java |
Removed test file that was incorrectly added to core module |
xapi-model-spring-boot-starter/pom.xml |
Removed Lombok dependency and compiler plugin configuration from core module |
xapi-model-spring-boot-starter/lombok.config |
Removed Lombok configuration file from core module |
samples/xapi-server/src/main/java/dev/learning/xapi/samples/xapiserver/StatementEntity.java |
Refactored JPA entity to use Lombok annotations instead of explicit getters/setters/constructors |
samples/xapi-server/pom.xml |
Added Lombok dependency and annotation processor configuration |
samples/xapi-server/README.md |
Added documentation section explaining Lombok usage and IDE setup requirements |
samples/xapi-server/src/main/java/dev/learning/xapi/samples/xapiserver/StatementEntity.java
Outdated
Show resolved
Hide resolved
… practices Co-authored-by: thomasturrell <1552612+thomasturrell@users.noreply.github.com>
|



Description
Modernizes the xapi-server sample by refactoring
StatementEntityto use Lombok annotations, reducing boilerplate from 79 to 36 lines. Also reverts commit dd04a64 which incorrectly added Lombok configuration to the core xapi-model-spring-boot-starter module.Changes
xapi-server sample (Lombok refactoring):
StatementEntity.java: Replaced explicit getters/setters/constructors with@Getter,@Setter,@NoArgsConstructor,@AllArgsConstructor(following JPA entity best practices by avoiding@Datawhich generates problematicequals(),hashCode(), andtoString()methods)pom.xml: Added Lombok dependency and maven-compiler-plugin annotation processor configurationlombok.config: Created with standard settings for code coverage, builder naming, and constructor properties (consistent with xapi-model)README.md: Added Lombok usage documentation with IDE setup guidancexapi-model-spring-boot-starter (reversion of dd04a64):
lombok.configLombokProcessingTests.javaBefore:
After:
Checklist:
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.