Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/firebase/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何使用Firebase emulator使用Firestore触发器测试Java云函数?_Java_Firebase_Google Cloud Firestore_Google Cloud Functions - Fatal编程技术网

如何使用Firebase emulator使用Firestore触发器测试Java云函数?

如何使用Firebase emulator使用Firestore触发器测试Java云函数?,java,firebase,google-cloud-firestore,google-cloud-functions,Java,Firebase,Google Cloud Firestore,Google Cloud Functions,我正在尝试将Java11运行时用于GoogleCloud/firebase函数,这是最近发布的。我想在本地机器上测试firestore触发器功能。互联网上的指南似乎正在使用firebase functions:shell命令,该命令本身启动所需的仿真过程。但是,我没有找到任何方法为firebase函数指定.jar文件:shell命令。或任何指定函数的方法。我知道它不会加载我的Java http函数,因为它显示了加载的函数,而helloWorld不是其中之一: gintas-mac:functio

我正在尝试将Java11运行时用于GoogleCloud/firebase函数,这是最近发布的。我想在本地机器上测试firestore触发器功能。互联网上的指南似乎正在使用firebase functions:shell命令,该命令本身启动所需的仿真过程。但是,我没有找到任何方法为firebase函数指定.jar文件:shell命令。或任何指定函数的方法。我知道它不会加载我的Java http函数,因为它显示了加载的函数,而helloWorld不是其中之一:

gintas-mac:functions gintas$ firebase functions:shell
⚠  Your requested "node" version "10" doesn't match your global version "8"
i  functions: Loaded functions: helloWorld
⚠  functions: The following emulators are not running, calls to these services will affect production: firestore, database, pubsub

不可能使用Firebase CLI测试用Java编写的函数。Firebase仅支持在nodejs上使用Firebase函数模块编写的函数。

Firebase函数仅允许nodejs作为运行时。您可以尝试的一件事是使用并查看本地测试。