WIP feat(fcm): Add support for AndroidConfigV2#1227
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces Android v2 configuration support for Firebase Cloud Messaging by deprecating the legacy AndroidConfig and AndroidNotification classes and introducing their v2 counterparts: AndroidConfigV2, AndroidNotificationV2, AndroidBackgroundSyncMessage, and AndroidRemoteNotification. The Message class has been updated to support these new configurations as mutually exclusive options with the legacy v1 fields, and comprehensive unit tests have been added. The review feedback focuses on improving AndroidNotificationV2 by statically importing checkNotNull, defining static final constants for regular expressions and date formatting to improve performance, specifying Locale.ENGLISH for locale-safe string conversions, and adding robust null checks for builder arguments.
This change implements support for the Android v2 API and it deprecates v1 AndroidConfig structures and replaces them with the new AndroidConfigV2 structures.
Adds AndroidConfigV2, AndroidNotificationV2, AndroidRemoteNotification, and AndroidBackgroundSyncMessage types.
Deprecates AndroidConfig and AndroidNotification.