Files
react-native/ReactCommon
Valentin SherginandFacebook Github Bot f2bb793699 Fabric: Re-registration a ComponentDescriptorProvider is now no-op and an assert in DEBUG mode
Summary:
We suspect that the re-registration of `ComponentDescriptorProvider`s during Bridge reloading might cause crashes in Fabric core. That happens because the re-registration process replaces already existing and being used ComponentDescriptors in the managed registries with the exact same new ones, which forces old ones to be deallocated and all pointers to them invalid. (On of the fundamental Fabric design decision is that `ShadowNode`s don't own/retain ComponentDescriptors.)
It seems was already indirectly addressed in application code on iOS but still fixing that in the core is valuable.
Android implementation does not use reactive component registration, so it was already fine.

As the follow-up diff, we plan to remove "removing" capabilities from ComponentDescriptorRegistry and ComponentDescriptorProviderRegistry to make it even more future-proof.

Changelog: [Internal] Fabric-specific internal change.

Reviewed By: sammy-SC

Differential Revision: D18273683

fbshipit-source-id: 7615627842855f078a3fdf3049f5511f59700972
2019-11-01 11:38:59 -07:00
..
2019-10-16 10:06:34 -07:00
2019-10-16 10:06:34 -07:00
2019-10-16 10:06:34 -07:00
2019-10-16 10:06:34 -07:00
2019-10-16 10:06:34 -07:00
2019-10-16 10:06:34 -07:00