objectbox / objectbox/objectbox-java
Support data observers for related entities
Open
Nobody has claimed this yet.
enhancement
- Dominant language
- Java
- Stars
- 4.6k
- Forks
- 311
- PR merge metrics
- No merged PRs in 30d
Description
Note these related feature requests:
- #126
- #268
This might be a feature request.
It seems that currently it is not possible to listen for nested changes.
- ObjectBox version: 1.2.1
- Reproducibility: always
boxFor(Item::class.java).query().build().subscribe().observer { items ->
// Not called when Note.text changes.
}
Entities
@Entity
class Item {
@Id
open var id: Long = 0L
lateinit open var notes: ToMany<Note>
}
@Entity
class Note {
@Id
open var id: Long = 0L
open var text: String? = null
@Backlink
lateinit open var parentItem: ToOne<Item>
}
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the Kotlin example with Item and Note entities, focusing on the query subscription and observer behavior when Note.text changes. Determine the intended notification behavior for related entities and verify that the Item observer is notified after a nested Note update; the issue names no source files or tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- kotlin
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100