prabhastechie commented on issue #221: Unable to create trigger from openwhisk kafka feed that listens to a Generic Kafka instance in a Local ubuntu installation URL: https://github.com/apache/incubator-openwhisk-package-kafka/issues/221#issuecomment-343738915 I found out the ip address of the docker running kafka on port 9092 and replaced the localhost:9092 with that ip address in the trigger create command. But the same error remains. My trigger create command was: `bin/wsk -i trigger create MyKafkaTrigger -f /guest/messaging/kafkaFeed -p brokers "172.17.0.6:9092" -p topic test -p isJSONData true --insecure` I looked through the issue #210 and got the idea to scan the wsk logs. In the logs I am getting: ``` bin/wsk -i activation logs 0250dd4292c3427b90dd4292c3627b72 2017-11-11T18:07:30.465220155Z stdout: Error creating trigger: { 2017-11-11T18:07:30.465321917Z stdout: "name": "StatusCodeError", 2017-11-11T18:07:30.465330104Z stdout: "statusCode": 404, 2017-11-11T18:07:30.46533561Z stdout: "message": "404 - {\"error\":\"The requested resource does not exist.\",\"code\":378}", 2017-11-11T18:07:30.465345409Z stdout: "error": { 2017-11-11T18:07:30.465350631Z stdout: "error": "The requested resource does not exist.", 2017-11-11T18:07:30.465355994Z stdout: "code": 378 2017-11-11T18:07:30.465360882Z stdout: }, 2017-11-11T18:07:30.465365572Z stdout: "options": { 2017-11-11T18:07:30.465371622Z stdout: "method": "PUT", 2017-11-11T18:07:30.465378249Z stdout: "url": "https://172.17.0.1/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http", 2017-11-11T18:07:30.465383764Z stdout: "rejectUnauthorized": false, 2017-11-11T18:07:30.465388753Z stdout: "json": true, 2017-11-11T18:07:30.465393569Z stdout: "body": { 2017-11-11T18:07:30.465422611Z stdout: "authKey": "23bc46b1-71f6-4ed5-8c54-816aa4f8c502:123zO3xZCLrMN6v2BKK1dXYFpXlPkccOFqm12CdAsMgRU4VrNZ9lyGVCGuMDGIwP", 2017-11-11T18:07:30.465428612Z stdout: "isJSONData": true, 2017-11-11T18:07:30.465433576Z stdout: "brokers": "172.17.0.6:9092", 2017-11-11T18:07:30.465438729Z stdout: "topic": "test", 2017-11-11T18:07:30.465443762Z stdout: "triggerName": "/guest/MyKafkaTrigger" 2017-11-11T18:07:30.465448991Z stdout: }, 2017-11-11T18:07:30.465453641Z stdout: "headers": { 2017-11-11T18:07:30.465458582Z stdout: "Content-Type": "application/json", 2017-11-11T18:07:30.465463711Z stdout: "Accept": "text/plain", 2017-11-11T18:07:30.465468781Z stdout: "User-Agent": "whisk" 2017-11-11T18:07:30.465473843Z stdout: }, 2017-11-11T18:07:30.465478532Z stdout: "simple": true, 2017-11-11T18:07:30.465483446Z stdout: "resolveWithFullResponse": false, 2017-11-11T18:07:30.465488452Z stdout: "transform2xxOnly": false 2017-11-11T18:07:30.465493383Z stdout: }, 2017-11-11T18:07:30.465498076Z stdout: "response": { 2017-11-11T18:07:30.465502992Z stdout: "statusCode": 404, 2017-11-11T18:07:30.465507869Z stdout: "body": { 2017-11-11T18:07:30.465512767Z stdout: "error": "The requested resource does not exist.", 2017-11-11T18:07:30.465518095Z stdout: "code": 378 2017-11-11T18:07:30.46552294Z stdout: }, 2017-11-11T18:07:30.465527654Z stdout: "headers": { 2017-11-11T18:07:30.465532536Z stdout: "server": "nginx/1.11.13", 2017-11-11T18:07:30.465537655Z stdout: "date": "Sat, 11 Nov 2017 18:07:30 GMT", 2017-11-11T18:07:30.465542848Z stdout: "content-type": "application/json", 2017-11-11T18:07:30.465548026Z stdout: "content-length": "70", 2017-11-11T18:07:30.465560008Z stdout: "connection": "close" 2017-11-11T18:07:30.465566005Z stdout: }, 2017-11-11T18:07:30.465570782Z stdout: "request": { 2017-11-11T18:07:30.465575761Z stdout: "uri": { 2017-11-11T18:07:30.465580669Z stdout: "protocol": "https:", 2017-11-11T18:07:30.465585902Z stdout: "slashes": true, 2017-11-11T18:07:30.465590931Z stdout: "auth": null, 2017-11-11T18:07:30.465595848Z stdout: "host": "172.17.0.1", 2017-11-11T18:07:30.465601004Z stdout: "port": 443, 2017-11-11T18:07:30.465605965Z stdout: "hostname": "172.17.0.1", 2017-11-11T18:07:30.465611131Z stdout: "hash": null, 2017-11-11T18:07:30.46561604Z stdout: "search": null, 2017-11-11T18:07:30.465621016Z stdout: "query": null, 2017-11-11T18:07:30.465625996Z stdout: "pathname": "/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http", 2017-11-11T18:07:30.465631461Z stdout: "path": "/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http", 2017-11-11T18:07:30.465636884Z stdout: "href": "https://172.17.0.1/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http" 2017-11-11T18:07:30.465642324Z stdout: }, 2017-11-11T18:07:30.465647068Z stdout: "method": "PUT", 2017-11-11T18:07:30.465652784Z stdout: "headers": { 2017-11-11T18:07:30.465657956Z stdout: "Content-Type": "application/json", 2017-11-11T18:07:30.465663304Z stdout: "Accept": "text/plain", 2017-11-11T18:07:30.465668504Z stdout: "User-Agent": "whisk", 2017-11-11T18:07:30.465673635Z stdout: "content-length": 214 2017-11-11T18:07:30.46567863Z stdout: } 2017-11-11T18:07:30.465683354Z stdout: } 2017-11-11T18:07:30.465688084Z stdout: } 2017-11-11T18:07:30.465692796Z stdout: } ``` So it seems like trigger create is expecting the resource; `https://172.17.0.1/api/v1/web/whisk.system/messagingWeb/kafkaFeedWeb.http ` But I have the following resources: ``` bin/wsk -i package get --summary /guest/messaging --insecure package /guest/messaging: Returns a result based on parameters endpoint, isBinaryKey, isBinaryValue, isJSONData, kafka_admin_url, kafka_brokers_sasl, password, topic and user (parameters: *endpoint, isBinaryKey, isBinaryValue, isJSONData, kafka_admin_url, kafka_brokers_sasl, password, topic, user) action /guest/messaging/kafkaProduce: Produce a message to a Kafka cluster (parameters: base64DecodeKey, base64DecodeValue, brokers, key, topic, value) action /guest/messaging/messageHubProduce: Produce a message to Message Hub (parameters: base64DecodeKey, base64DecodeValue, kafka_brokers_sasl, key, password, topic, user, value) feed /guest/messaging/kafkaFeed: Feed to listen to Kafka messages (parameters: brokers, endpoint, isBinaryKey, isBinaryValue, isJSONData, topic) feed /guest/messaging/messageHubFeed: Feed to list to Message Hub messages (parameters: endpoint, isBinaryKey, isBinaryValue, isJSONData, kafka_admin_url, kafka_brokers_sasl, password, topic, user) ``` So there are two issues: i. My trigger create is referring to kafkaFeed, but internally it is searching for 'kafkaFeedWeb' ii. Even for 'kafkaFeed' my deployment has deployed it as /guest/messaging/kafkaFeed . How can I deploy it under /whisk.system/messaging ? In case its relevant, I was able to deploy the alarms feed under whisk.system by following the ansible scripts mentioned in https://github.com/apache/incubator-openwhisk-package-alarms/issues/51#issuecomment-294010619
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
