4

I am using firebase functions Database Triggers.

My Function :

exports.function_name = functions.database
  .ref("/transact/{entry_type}/{id1}/{id2}/trigger_cross_entry_function")
  .onCreate((data, context) => {
    console.log("trigger_cross_entry_function value", data.val());

    if (data.val() == true) {

      console.log("Function Calling parent data");

      return data.ref.parent.once('value').then(function(snapshot){


      }, function(error) {
        // The Promise was rejected.
        console.error("THIS IS THE ERROR:"+error);
      });

    } else {
      console.log("Function Returned");
      return 0;
    }
 });

Whenever I want to trigger this function I put trigger_cross_entry_function into that partcular path from the Mobile App. Everything works fine and function is called as expected.

After sometime If I again try to do the same thing it gives me

Function execution took 16 ms, finished with status: 'connection error'

If I restart the function than it again works perfectly. and If I trigger it continously than it has no issue.

But once I keep it idle and try to trigger it again after sometime, it gives me this error.

And I am using Firebase Pay as you go Plan.

Also, as you can see I am returning all the promises correctly and function is being triggered everytime but It doesnt go into the function. it just exit with connection error.

What might be the cause for this ? I have a spent a day finding this.

3
  • we're seeing the exact same issue, and a few others on firebase slack are too. I've been in contact with support, and they say their engineers are on it. Commented Dec 20, 2018 at 15:14
  • Yeah, also experiencing this intermittently starting today. Commented Dec 20, 2018 at 15:32
  • Thank you. Even I contacted them so they replied the same Commented Dec 21, 2018 at 9:31

1 Answer 1

1

Experiencing the same issue. Looks like Google changed the status of the service to down https://status.firebase.google.com/incident/Functions/18046 https://status.firebase.google.com/

So most likely the Google side problem.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.