liferay-dummy-factory
CLAUDE.md49 starsChanged 38 days agoMITView on GitHub
A Liferay DXP Control Panel app that generates dummy data (users, sites, pages, web content, documents, taxonomy, message boards, …) through per-entity forms and multi-step JSON workflows. One OSGi bundle (MVCPortlet + JAX-RS workflow API + React UI) in a Liferay Workspace, tested with JUnit, Vitest, and Spock + Playwright against a real DXP container. The exact DXP version is in gradle.properties. Code, tests and docs changed together; the relevant unit suites pass; node scripts/check-docs.mjs passes; integration specs at least…
In this repository3 other files it gives its agents.
- contract-reviewSkill
- liferay-debugSkill
- parallel-orchestrationSkill
The file
Files
liferay-dummy-factory
A Liferay DXP Control Panel app that generates dummy data (users, sites, pages, web content, documents, taxonomy, message boards, …) through per-entity forms and multi-step JSON workflows. One OSGi bundle (MVCPortlet + JAX-RS workflow API + React UI) in a Liferay Workspace, tested with JUnit, Vitest, and Spock + Playwright against a real DXP container. The exact DXP version is in gradle.properties.
Map
| Path | What |
modules/liferay-dummy-factory/src/main/java/…/tools/ | portlet/actions (resource commands) → service (Creators) ; workflow/ (engine, adapters, JAX-RS) |
modules/liferay-dummy-factory/src/main/resources/META-INF/resources/ | view.jsp, React/TypeScript in js/ |
modules/liferay-dummy-factory/src/test/java/, …/test/ | JUnit, Vitest |
integration-test/ | Spock + Playwright specs, workflow sample fixtures |
configs/common/ | portal and OSGi config baked into the test image |
docs/ | documentation — start at docs/README.md |
Commands
./gradlew :modules:liferay-dummy-factory:jar # build the bundle (includes the esbuild frontend build)
./gradlew :modules:liferay-dummy-factory:test # Java unit tests + JaCoCo
(cd modules/liferay-dummy-factory && yarn test) # Vitest
./gradlew :integration-test:compileTestGroovy # compile specs without Docker
./gradlew :integration-test:integrationTest [--tests "<FQCN>"] # full E2E; needs Docker + LIFERAY_DXP_LICENSE_FILE
./gradlew startDockerContainer | stopDockerContainer | removeDockerContainer
node scripts/check-docs.mjs # docs consistency (CI-enforced)Contracts that fail silently when broken
- Input boundary — reject user input, sanitize generated data, never mix. →
docs/architecture/backend.md#input-boundary-policy - Batch contract — Creators return
BatchResult<T>→{success, count, requested, skipped, items, error?},success := count == requested,erroriff failure; per-entityBatchTransaction.run,throws Throwable. →docs/architecture/backend.md#batch-response-contract - Two entry points, one behaviour — resource command and workflow adapter call the same Creator and expose identical item fields; new
/ldf/*commands are registered inview.jsp. →docs/reference/workflow-api.md - DXP 2026 platform —
jakarta.portlet4.0 (JSP taglib URI stayshttp://xmlns.jcp.org/portlet_3_0), nojavax.servletimport,release.dxp.apiwithout a version. →docs/reference/liferay-dxp-api.md - Tests verify through JSONWS; Playwright only for DOM concerns, never selecting by visible text, always asserting the success class. →
.claude/rules/tests.md data-testids are generated, never invented. →docs/reference/test-ids.md- One fact, one file; no versions in prose; Yarn only. →
.claude/rules/documentation.md,docs/reference/dependencies.md
How guidance is organized
.claude/rules/*.mdare path-scoped and load automatically when you touch matching files:backend-java,frontend,tests,build-and-ci,documentation..claude/skills/hold task procedures:liferay-debug(any failure),contract-review(reviews),parallel-orchestration(only on explicit request).- Explanations and facts live in
docs/(guides / reference / architecture / adr). Look there before re-deriving anything; record new findings there, once. .claude/plan/is git-ignored scratch space.
Done means
Code, tests and docs changed together; the relevant unit suites pass; node scripts/check-docs.mjs passes; integration specs at least compile (compileTestGroovy). If you could not run the integration suite (it needs Docker and a DXP license), say so explicitly.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

