Skip to content

Commit c640e2e

Browse files
monicatangfacebook-github-bot
authored andcommitted
Add log events
Reviewed By: captbaritone Differential Revision: D70283658 fbshipit-source-id: 43b1a814bd20832703716d7de72b59b62e2bb66e
1 parent ab3b117 commit c640e2e

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

packages/relay-runtime/store/RelayStoreTypes.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -786,12 +786,31 @@ export type UseFragmentSubscriptionMissedUpdates = {
786786
+hasDataChanges: boolean,
787787
};
788788

789+
/**
790+
* This event is logged when two strong objects share the same id,
791+
* but have different types, resulting in an collision in the store.
792+
*/
793+
export type IdCollisionTypenameLogEvent = {
794+
+name: 'idCollision.typename',
795+
};
796+
797+
/**
798+
* This event is logged when a response contains fields with different
799+
* values but which have the same corresponding id, resulting in a
800+
* collision in the store.
801+
*/
802+
export type IdCollisionFieldLogEvent = {
803+
+name: 'idCollision.field',
804+
};
805+
789806
export type LogEvent =
790807
| SuspenseFragmentLogEvent
791808
| SuspenseQueryLogEvent
792809
| QueryResourceFetchLogEvent
793810
| QueryResourceRetainLogEvent
794811
| FragmentResourceMissingDataLogEvent
812+
| IdCollisionTypenameLogEvent
813+
| IdCollisionFieldLogEvent
795814
| PendingOperationFoundLogEvent
796815
| NetworkInfoLogEvent
797816
| NetworkStartLogEvent

0 commit comments

Comments
 (0)