Close Menu
  • Home
  • AI
  • Big Data
  • Cloud Computing
  • iOS Development
  • IoT
  • IT/ Cybersecurity
  • Tech
    • Nanotechnology
    • Green Technology
    • Apple
    • Software Development
    • Software Engineering

Subscribe to Updates

Get the latest technology news from Bigteetechhub about IT, Cybersecurity and Big Data.

    What's Hot

    Assessing the Feasibility and Advisability of a Civilian Cybersecurity Reserve

    March 11, 2026

    Building Greener With Steel: Why Prefab Metal Buildings Are Getting A Second Look

    March 11, 2026

    How Pokémon Go is giving delivery robots an inch-perfect view of the world

    March 11, 2026
    Facebook X (Twitter) Instagram
    Facebook X (Twitter) Instagram
    Big Tee Tech Hub
    • Home
    • AI
    • Big Data
    • Cloud Computing
    • iOS Development
    • IoT
    • IT/ Cybersecurity
    • Tech
      • Nanotechnology
      • Green Technology
      • Apple
      • Software Development
      • Software Engineering
    Big Tee Tech Hub
    Home»iOS Development»firebase cloud messaging – Kotlin Multiplatform iOS — FirebaseBridge (Objective-C) not called from iosMain (FirebasePushNotifierImpl.init not running)
    iOS Development

    firebase cloud messaging – Kotlin Multiplatform iOS — FirebaseBridge (Objective-C) not called from iosMain (FirebasePushNotifierImpl.init not running)

    big tee tech hubBy big tee tech hubJanuary 21, 2026021 Min Read
    Share Facebook Twitter Pinterest Copy Link LinkedIn Tumblr Email Telegram WhatsApp
    Follow Us
    Google News Flipboard
    firebase cloud messaging – Kotlin Multiplatform iOS — FirebaseBridge (Objective-C) not called from iosMain (FirebasePushNotifierImpl.init not running)
    Share
    Facebook Twitter LinkedIn Pinterest Email Copy Link


    I have a KMP module using a native bridge in Objective-C/Swift for FCM. Android works fine, but on iOS the FirebaseBridge methods are not called from iosMain. It seems FirebasePushNotifierImpl either doesn’t initialize properly, or FirebaseBridge.initializeFirebase() never runs.

    git:

    Relevant files:

    1) Kotlin (iosMain) — FirebasePushNotifierImpl.kt

    internal class FirebasePushNotifierImpl : PushNotifier {
    
        private val scope =
            CoroutineScope(SupervisorJob() + Dispatchers.Main.immediate)
    
        init {
            scope.launch {
                FirebaseBridge.initializeFirebase() // expected to call iOS code
            }
        }
    
        // getToken, deleteToken, subscribe, etc.
    }
    

    2) cinterop .def

    language = Objective-C
    package = firebasebridge
    headers = FirebaseBridgeObjC.h
    compilerOpts = -I${projectDir}/../../iosApp/iosApp
    

    3) Swift implementation

    @objc public class FirebaseBridge: NSObject {
    
        @objc public static func initializeFirebase() {
            DispatchQueue.main.async {
                if FirebaseApp.app() == nil {
                    FirebaseApp.configure()
                }
                UNUserNotificationCenter.current().delegate =
                    UIApplication.shared.delegate as? UNUserNotificationCenterDelegate
                UIApplication.shared.registerForRemoteNotifications()
            }
        }
        
        // getToken, deleteToken, subscribe, unsubscribe...
    }
    

    4) Objective-C header

    @interface FirebaseBridge : NSObject
    + (void)initializeFirebase;
    + (void)getToken:(FBTokenCallback)completion;
    + (void)deleteToken:(FBVoidCallback)completion;
    + (void)subscribeToTopic:(NSString*)topic;
    + (void)unsubscribeFromTopic:(NSString*)topic;
    @end
    

    Expected behavior:
    FirebasePushNotifierImpl initializes and FirebaseBridge.initializeFirebase() executes (I should see NSLog output, and FCM registers device token).

    Actual behavior:
    No logs from FirebaseBridge, device token not registered. Looks like Kotlin → Objective-C bridge is not called. Build succeeds, no compile errors.



    Source link

    called Cloud Firebase FirebaseBridge FirebasePushNotifierImpl.init iOS iosMain Kotlin Messaging Multiplatform ObjectiveC running
    Follow on Google News Follow on Flipboard
    Share. Facebook Twitter Pinterest LinkedIn Tumblr Email Copy Link
    tonirufai
    big tee tech hub
    • Website

    Related Posts

    uikit – Why the title doesn’t follow the navigation inline state in iOS 26

    March 11, 2026

    ios – OS emoji keyboard causes UI freeze in chat TextField Flutter

    March 10, 2026

    Self-managed observability: Running agentic AI inside your boundary 

    March 9, 2026
    Add A Comment
    Leave A Reply Cancel Reply

    Editors Picks

    Assessing the Feasibility and Advisability of a Civilian Cybersecurity Reserve

    March 11, 2026

    Building Greener With Steel: Why Prefab Metal Buildings Are Getting A Second Look

    March 11, 2026

    How Pokémon Go is giving delivery robots an inch-perfect view of the world

    March 11, 2026

    Why AI Data Readiness Is Becoming the Most Critical Layer in Modern Analytics

    March 11, 2026
    About Us
    About Us

    Welcome To big tee tech hub. Big tee tech hub is a Professional seo tools Platform. Here we will provide you only interesting content, which you will like very much. We’re dedicated to providing you the best of seo tools, with a focus on dependability and tools. We’re working to turn our passion for seo tools into a booming online website. We hope you enjoy our seo tools as much as we enjoy offering them to you.

    Don't Miss!

    Assessing the Feasibility and Advisability of a Civilian Cybersecurity Reserve

    March 11, 2026

    Building Greener With Steel: Why Prefab Metal Buildings Are Getting A Second Look

    March 11, 2026

    Subscribe to Updates

    Get the latest technology news from Bigteetechhub about IT, Cybersecurity and Big Data.

      • About Us
      • Contact Us
      • Disclaimer
      • Privacy Policy
      • Terms and Conditions
      © 2026 bigteetechhub.All Right Reserved

      Type above and press Enter to search. Press Esc to cancel.