How to use CoreStore with Google Promises Framework #200

Closed
opened 2025-12-29 15:26:32 +01:00 by adam · 1 comment
Owner

Originally created by @krema on GitHub (Feb 26, 2018).

Hi,
I have noticed that my fetches are not present when fullfilling the promise.

After some testing and reading from issue https://github.com/JohnEstropia/CoreStore/issues/180 I noticed that the use of promises leads to a switch from the main-thread to the main-thread serial queue. That may be one reason why I can't access the fetched properties.

Is there any way to make it work somehow?
Appreciate any idea.

Originally created by @krema on GitHub (Feb 26, 2018). Hi, I have noticed that my fetches are not present when fullfilling the promise. After some testing and reading from issue https://github.com/JohnEstropia/CoreStore/issues/180 I noticed that the use of promises leads to a switch from the main-thread to the main-thread serial queue. That may be one reason why I can't access the fetched properties. Is there any way to make it work somehow? Appreciate any idea.
adam closed this issue 2025-12-29 15:26:32 +01:00
Author
Owner

@krema commented on GitHub (Feb 27, 2018):

Instead of fiddling around with GCD I made it work with an additional layer (business). I use the repository pattern that acts as a facade for CoreStore / CoreData and map the Core Data entities to a business model before returning them from the data access layer to the business layer. So simply!

I am closing this ticket for now.

@krema commented on GitHub (Feb 27, 2018): Instead of fiddling around with GCD I made it work with an additional layer (business). I use the repository pattern that acts as a facade for CoreStore / CoreData and map the Core Data entities to a business model before returning them from the data access layer to the business layer. So simply! I am closing this ticket for now.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/CoreStore#200