Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add makifbaysal/tasktrooper --skill java-persistencegit clone --depth 1 https://github.com/makifbaysal/tasktrooperWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/makifbaysal/tasktrooper/java-persistence)<a href="https://agentmods.dev/skills/makifbaysal/tasktrooper/java-persistence"><img src="https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/java-persistence/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/makifbaysal/tasktrooper/java-persistence"><img src="https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/java-persistence.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00042 | $0.01269 |
| Opus 5.5 | $0.00017 | $0.00508 |
| Sonnet 5.5 | $0.00008 | $0.00254 |
| Haiku 4.5 | $0.00004 | $0.00127 |
Grade A, and why
java-persistence scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 72 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Java Persistence (JPA / Panache / Spring Data)
Overview
Persistence is where Java services most often leak — lazy-loading exceptions, N+1 queries, entities serialized over HTTP, pagination applied in memory. Keep persistence at the repository boundary and mapped deliberately.
Core principle: Entities are a persistence detail. They never cross the HTTP boundary and they never carry business logic that belongs in the domain. Every list query is bounded AND the bound is honored by the SQL, not by Java code truncating a full result set.
Mapping surface
| Concern | Quarkus (Panache) | Spring Data |
|---|---|---|
| Entity | @Entity + PanacheEntityBase or plain @Entity |
@Entity |
| Repository | implements PanacheRepository<Task> |
extends JpaRepository<Task, UUID> |
| Query | find("status", s) / HQL |
derived methods / @Query |
| Transaction | @Transactional on the service |
@Transactional on the service |
| Pagination | .page(Page.of(n, size)) |
Pageable / Page<T> |
| Optimistic lock | @Version |
@Version |
| Schema management (non-test) | quarkus.hibernate-orm.schema-management.strategy=none (or validate; property renamed from database.generation in 3.23) |
spring.jpa.hibernate.ddl-auto=validate |
Rules
- Transaction boundary = the service method, never the repository or the resource. One use-case = one transaction.
- Never return entities from a controller/resource. Map to a DTO inside the service (or a JPA projection). Returning entities causes lazy-init serialization errors and leaks the schema.
- Fetch deliberately to avoid N+1. A loop that touches a lazy collection per row issues a query per row. Use a
JOIN FETCH/ entity graph /@BatchSizeorhibernate.default_batch_fetch_size, and verify with a query-count assertion in a test. - Never paginate a collection
JOIN FETCH. Hibernate appliesLIMIT/OFFSETin memory when the query also fetches a*-to-manycollection (warningHHH90003004) — it loads the whole table to paginate it. Sethibernate.query.fail_on_pagination_over_collection_fetch=truein the test profile so this fails loudly instead of shipping slow. Page the root entity's ids first (plain query, no fetch join), then fetch the page by id with the collection join, or rely on@BatchSize/hibernate.default_batch_fetch_sizeinstead of a fetch join at all. - Bound every list query. Page (
Page/Pageable, Panache.page(...)) — neverfindAll()/listAll()on a growing table. Default and maximum page size live with the endpoint (api-design-conventions), not just the repository call. - Migrations own the schema, not
hibernate.hbm2ddl=update/Quarkusgenerate-schema. Set validate/none in non-test envs; schema changes go through a migration (postgres-migrations), never auto-DDL in production. - Optimistic locking (
@Version) on entities with concurrent updates; mapOptimisticLockException/ObjectOptimisticLockingFailureExceptionto 409 in the central error mapper (api-design-conventions), never let it surface as 500. spring.jpa.open-in-view=false(Spring) — Open Session In View hides N+1s in the view layer and that lazy access outside a clear transaction boundary is exactly the mistake this skill exists to prevent.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 72 lines · 42 tokens per session scan A 0bf3ab9466b9
java-persistence is a skill published in the GitHub repository makifbaysal/tasktrooper (123 stars, last pushed today), licensed Apache-2.0. It adds 42 tokens to every session and 1,269 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-05.
java-persistence compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| java-persistencemakifbaysal/tasktrooper | Skill | 123 | today | Apache-2.0 | A | 42 | Claude Code, Codex |
| cudf-query-engine-builderNVIDIA/skills | Skill | 4.2k | 2d ago | Apache-2.0 | A | 99 | Claude Code, Codex |
| cuequivariance-jaxNVIDIA/skills | Skill | 4.2k | 2d ago | Apache-2.0 | A | 38 | Claude Code, Codex |
| cudnn-compile-and-serializeNVIDIA/skills | Skill | 4.2k | 2d ago | Apache-2.0 | A | 59 | Claude Code, Codex |
| cudnn-installNVIDIA/skills | Skill | 4.2k | 2d ago | Apache-2.0 | A | 49 | Claude Code, Codex |
| ccclNVIDIA/skills | Skill | 4.2k | 2d ago | Apache-2.0 | A | 206 | Claude Code, Codex |
| agentscope-javaagentscope-ai/agentscope-java | Skill | 6.5k | today | Apache-2.0 | A | 91 | Claude Code, Codex |