← スキル一覧に戻る

adding-persistent-event
by terraware
Server side of the Terraware web application
⭐ 11🍴 1📅 2026年1月23日
SKILL.md
name: adding-persistent-event description: Adds a new type of event that gets persisted to the event log. Use this when adding new kinds of write operations to the system or when adding new events to existing code.
Adding Persistent Event
Instructions
Copy this checklist and check off items as you complete them. Note that some items are conditional:
Task Progress:
- [ ] Create a new sealed interface if needed.
- [ ] Create the event class.
- [ ] Create typealias(es) for the event class.
- [ ] Create a new subject payload class if needed.
- [ ] Make sure the subject is handled in EventLogPayloadTransformer.
- [ ] Add custom FieldsUpdatedAction logic to EventLogPayloadTransformer if needed.
- [ ] Add a database migration to backfill events for existing entities if needed.
- [ ] Add code to publish the new event.
- [ ] Add test(s) for any new logic in EventLogPayloadTransformer.
- [ ] Add test(s) or modify existing tests to verify code that publishes the new event.
- [ ] Generate translations of localized strings with `yarn translate`.
- [ ] Format code with `./gradlew spotlessApply`.
- [ ] Run the full test suite with `./gradlew test`.
Reference
See EVENTS.md for detailed documentation including best practices.
Additional guidelines
When implementing FieldsUpdatedPersistentEvent.listUpdatedFields, prefer expression syntax over block syntax for the method body, and omit the return type. For example,
override fun listUpdatedFields() =
listOfNotNull(createUpdatedField("example", changedFrom.example, changedTo.example))
スコア
総合スコア
60/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
✓LICENSE
ライセンスが設定されている
+10
○説明文
100文字以上の説明がある
0/10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です