XPC between an app and a service residing in another app's bundle

409 Views Asked by At

I have two unique sandboxed Cocoa applications. I wish for one of these to be able to provide some data on-demand to the first application, but without first requiring the launch the second application. For this, I'm thinking of creating an XPC service in the second application and then using it from the first.

Is this possible? I have the privilege of enabling "App Groups" if that would enable this functionality, as all the examples and code I've seen so far require the service to be bundled inside of the calling application or require the second application to be running. I don't want the launch the second application as the data can simply be obtained by querying the database and does not require interrupting the user's workflow.

Is this possible to do?

Would it be better to instead create a background Login item in the second application and use the Groups Container to communicate using files? That's highly inefficient and I'd personally prefer to be able to communicate between the two apps.

0

There are 0 best solutions below