【问题标题】:How can I check that Openwhisk (IBM Cloud Functions) gets invoked?如何检查 Openwhisk (IBM Cloud Functions) 是否被调用?
【发布时间】:2016-07-05 09:45:07
【问题描述】:
我有一个将数据上传到 Cloudant 数据库的 Web 应用程序。更改事件应触发 OpenWhisk / IBM Cloud Functions 激活或操作。如何检查是否调用了 OpenWhisk,是否有调试机制?我尝试使用仪表板,但有什么我可以在命令行上使用的吗?
我正在试验 node.js 和 Docker 操作,所以如果解决方案独立于操作是在 node.js、Swift 还是 Docker 容器中,那就太好了。
【问题讨论】:
标签:
node.js
docker
ibm-cloud
serverless-framework
openwhisk
【解决方案1】:
我在OpenWhisk documentation找到它:
wsk activation poll
成功了。它将激活日志流式传输到我的 shell:
wsk activation poll
Hit Ctrl-C to exit.
Polling for logs
Activation: echo (36e3d136f55d439e8e901b4d8b9dxxxx)
Activation: wordCount (e001309b627c451991f477ab349cxxxx)
2016-03-18T15:10:38.529050288Z stdout: The message 'John says hello to OpenWhisk and the wonderful world of Cloud Computing' has 12 words