Good Morning
We are seeking guidance on the supported Core Data architecture for independently sharing multiple records using NSPersistentCloudKitContainer.
Our iOS application allows users to manage a vessel and multiple cruises. Each cruise can be shared independently with different participants and permissions.
Our Core Data model includes:
CruiseEvents.vessel— optional relationship toVesselVessel.cruises— inverse relationship toCruiseEvents
New cruises are automatically associated with the owner's primary vessel. Existing local cruises may also have this relationship populated.
Our requirement is:
- Share each cruise independently using
NSPersistentCloudKitContainer.
When preparing a share, we pass the selected CruiseEvents object as the root.
However, Core Data appears to encounter conflicts when multiple independently shared cruises reference the same vessel.
We receive Core Data error 134060, including:
Object graph corruption detected … related objects assigned to multiple zones
Subsequent CloudKit mirroring operations may also report error 134406.
Our read-only diagnostic traversed the persisted Core Data relationships and identified multiple cruise roots connected through the same Vessel object.
Locally available share metadata associates those cruise roots with different CloudKit share zones.
This suggests that the shared vessel relationship may be connecting object graphs that Core Data expects to remain isolated within their respective sharing zones. We have not yet established whether this is the sole cause.
The issue also occurs on a physical device, not just Simulator. Owner and recipient testing uses separate iCloud accounts.
Is a Core Data relationship from multiple independently shared CruiseEvents objects to the same Vessel incompatible with NSPersistentCloudKitContainer sharing when those cruises belong to different share zones?
When Core Data determines the object graph for a share, does it traverse both directions of inverse relationships?
Specifically, could the following path cause additional cruises to become part of the same connected graph?
CruiseEvents.vessel → Vessel.cruises → Other CruiseEvents
Which logs, metadata, or diagnostic techniques would Apple recommend to distinguish between:
- An application-created relationship spanning independently shared graphs
- Stale or inconsistent CloudKit sharing metadata
- An
NSPersistentCloudKitContainerframework issue
One affected test environment:
- iOS: 26.2 Simulator
The issue has also been reproduced on a physical device.
We can provide the exact device and OS details, diagnostic logs, and a minimal reproduction project if needed.
Our primary question is whether independently shared Core Data objects must have completely isolated relationship graphs, and how Apple recommends modeling references to private objects that are logically shared across those graphs.
Thank you for any guidance.