Skip to content

Native async callbacks #143

Closed
Closed
@vaind

Description

@vaind

To implement any kind of async callbacks from C to Dart, we have to jump through some hoops, see the following issues:

In short, native callbacks must be executed on the "right" dart isolate, during its event loop.
This issue currently affects observers (#142) and is a prerequisite for SyncClient listeners (#140).

From my understanding, getting this to work is quite a bit involved because we would need to create some custom C code that would call directly into dart APIs to inject the callback into the event loop (forgive if this is inaccurate, still learning about the workaround). AFAICT this would require that we either ship a different version of the objectbox-c or we create an additional one we ship alongside the standard one used by all other languages...

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions