Reputation: 11112
I created a scheduled function with Firebase. Deployed it. I do not know where I could see the log written in my function or at least the pubsub topics. This is the output of firebase deploy
:
i deploying functions
i functions: ensuring required API cloudfunctions.googleapis.com is enabled...
i functions: ensuring required API cloudbuild.googleapis.com is enabled...
! functions: missing required API cloudbuild.googleapis.com. Enabling now...
+ functions: required API cloudfunctions.googleapis.com is enabled
+ functions: required API cloudbuild.googleapis.com is enabled
i functions: preparing functions directory for uploading...
i functions: packaged functions (49.94 KB) for uploading
i functions: ensuring required API pubsub.googleapis.com is enabled...
i functions: ensuring required API cloudscheduler.googleapis.com is enabled...
+ functions: required API cloudscheduler.googleapis.com is enabled
+ functions: required API pubsub.googleapis.com is enabled
+ functions: functions folder uploaded successfully
i functions: creating Node.js 16 function addMessage(us-central1)...
i functions: creating Node.js 16 function scheduledFunction(us-central1)...
i functions: creating Node.js 16 function every10secs(us-central1)...
+ functions[addMessage(us-central1)] Successful create operation.
Since neither the emulator emulates scheduled function nor the Firebase console displays the scheduled functions I am stuck. I assume I have to switch to the google cloud platform, but how?
Upvotes: 1
Views: 177
Reputation: 1401
It's good to know that you were able to find PubSub inside GCP. The reason is because FireBase tools share some products with Google Cloud Platform. I'm leaving this answer as step by step guide and reference for other users that may encounter this issue.
PUBSUB on Google Cloud Platform
To access PUBSUB:
Note: You can 'pin' your most used products in the Navigation Menu. For more details about the PUBSUB, click here.
Logs on Google Cloud Platform
To see operation logs:
Note: Logs will need to be streamed into the log explorer first. Logging will suggest jobs to do this operation automatically. For more details about the Logging, click here.
Upvotes: 1