FCM quick start app update to use new FCM v1 registration api(s) by eldhosembabu · Pull Request #2810 · firebase/quickstart-android · GitHub
Skip to content

FCM quick start app update to use new FCM v1 registration api(s)#2810

Open
eldhosembabu wants to merge 2 commits into
masterfrom
emb/fcm-qs-update
Open

FCM quick start app update to use new FCM v1 registration api(s)#2810
eldhosembabu wants to merge 2 commits into
masterfrom
emb/fcm-qs-update

Conversation

@eldhosembabu

Copy link
Copy Markdown
Contributor

FCM quick start app update to use new FCM v1 registration api(s)

@wiz-9635d3485b

wiz-9635d3485b Bot commented Jun 18, 2026

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the FCM quickstart sample to use the new FCM Registration API (using Installation ID) instead of the deprecated registration token, upgrading the Firebase BoM and replacing getToken and onNewToken with register, onRegistered, and onUnregistered in both Java and Kotlin implementations. The review feedback highlights critical issues: calling Toast.makeText directly inside the background-threaded onRegistered callback will cause a crash and must be posted to the main thread. Additionally, several mismatched documentation tags (such as duplicate onRegistered tags and outdated log_reg_token end tags) need correction, and the button text in the layout should be updated to reflect the new registration functionality.

Comment thread messaging/app/src/main/res/layout/activity_main.xml
@eldhosembabu eldhosembabu requested a review from Doris-Ge June 18, 2026 19:31

@Doris-Ge Doris-Ge left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thanks!

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Enable FCM New FCM Registration using Installation id

nit: should this be a variable name with '_' delimiter such as fcm_installation_id_enabled?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants