Add sample-java-entity-decorators project#1
Merged
iliyan-velichkov merged 2 commits intoMay 19, 2026
Conversation
Adds a Dirigible project under sample-java-entity-decorators/ demonstrating the engine-java + data-store-java annotation surface: - demo/Country.java — @entity persisted via the shared SessionFactory - demo/CountryRepository.java — @repository extending JavaRepository<Country> - demo/CountryController.java — @controller exposing CRUD over @Get/@Post/@delete - demo/CountrySeeder.java — @controller that seeds three rows on POST CountryController and CountrySeeder receive the repository via @Inject, which is the recommended client-code pattern (controllers never touch BeanProvider or JavaEntityStore directly). Also adds a Java-oriented .gitignore and fleshes out the README with the project layout, URL map and a usage note. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Per integration-test review feedback, the seeder is folded into the test itself (the test POSTs each country to CountryController) and the list endpoint moves to the controller's bare base URL. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
9 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
sample-java-entity-decorators/demonstrating theengine-java+data-store-javaannotation surface (@Entity,@Repository,@Controller,@Inject,@Get/@Post/@Delete,@PathParam,@Body,@Roles)..gitignoreand a README with the project layout and URL map.Project layout
sample-java-entity-decorators/demo/Country.java—@Entitysample-java-entity-decorators/demo/CountryRepository.java—@RepositoryextendingJavaRepository<Country>sample-java-entity-decorators/demo/CountryController.java—@Controllerwith CRUD routessample-java-entity-decorators/demo/CountrySeeder.java—@Controllerthat seeds three rows on POSTsample-java-entity-decorators/project.jsonControllers receive the repository via
@Inject, which is the recommended client-code pattern (controllers never touchBeanProviderorJavaEntityStoredirectly).Test plan
POST /services/java/sample-java-entity-decorators/demo/CountrySeeder→seeded.GET /services/java/sample-java-entity-decorators/demo/CountryController/list→ JSON list with Afghanistan/Albania/Algeria.GET /services/java/sample-java-entity-decorators/demo/CountryController/1→ Afghanistan.POST /services/java/sample-java-entity-decorators/demo/CountryControllerwith JSON body → returns the inserted row.DELETE /services/java/sample-java-entity-decorators/demo/CountryController/1→ 200, row gone from/list.GET /services/openapiincludes the controller paths.🤖 Generated with Claude Code