apache/openwhisk-package-alarms

Cannot create alarms trigger

Closed this issue · 6 comments

I get an openssl error when trying to create an alarms trigger. I installed the alarms package as follows (this is on a new vagrant openwhisk install):

$ ./installCatalog.sh $AUTH_KEY 172.17.0.1 $COUCHDB_HOST:$COUCHDB_PORT test $API_HOST
...
ok: updated action alarmsWeb/alarmWebAction
$ wsk package list /whisk.system
packages
/whisk.system/alarms                                                   shared
/whisk.system/watson-speechToText                                      shared
...
$ wsk action get --summary /whisk.system/alarms/alarm
action /whisk.system/alarms/alarm: Fire trigger when alarm occurs
$ wsk trigger create everyEightSeconds --feed /whisk.system/alarms/alarm -p cron "*/8 * * * * *" -p trigger_payload "{\"name\":\"Mork\", \"place\":\"Ork\"}"
ok: invoked /whisk.system/alarms/alarm with id 184b0aa219564013b4885b659f883908
{
    "activationId": "184b0aa219564013b4885b659f883908",
    "annotations": [
        {
            "key": "limits",
            "value": {
                "logs": 10,
                "memory": 256,
                "timeout": 60000
            }
        },
        {
            "key": "path",
            "value": "whisk.system/alarms/alarm"
        }
    ],
    "duration": 268,
    "end": 1499885736936,
    "logs": [],
    "name": "alarm",
    "namespace": "guest",
    "publish": false,
    "response": {
        "result": {
            "error": {
                "code": "EPROTO",
                "errno": "EPROTO",
                "syscall": "write"
            }
        },
        "status": "application error",
        "success": false
    },
    "start": 1499885736668,
    "subject": "guest",
    "version": "0.0.3"
}
ok: invoked /whisk.system/alarms/alarm with id 257f96bef7a94236a1c3eae1496b21bd
{
    "activationId": "257f96bef7a94236a1c3eae1496b21bd",
    "annotations": [
        {
            "key": "limits",
            "value": {
                "logs": 10,
                "memory": 256,
                "timeout": 60000
            }
        },
        {
            "key": "path",
            "value": "whisk.system/alarms/alarm"
        }
    ],
    "duration": 179,
    "end": 1499885737144,
    "logs": [],
    "name": "alarm",
    "namespace": "guest",
    "publish": false,
    "response": {
        "result": {
            "error": {
                "code": "EPROTO",
                "errno": "EPROTO",
                "syscall": "write"
            }
        },
        "status": "application error",
        "success": false
    },
    "start": 1499885736965,
    "subject": "guest",
    "version": "0.0.3"
}
ok: deleted trigger everyEightSeconds
$ wsk activation logs 257f96bef7a94236a1c3eae1496b21bd
2017-07-12T18:55:37.142606606Z stdout: alarm: Error invoking whisk action: { Error: write EPROTO 139767976155008:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:794:
2017-07-12T18:55:37.142654856Z stdout:
2017-07-12T18:55:37.142659802Z stdout: at exports._errnoException (util.js:1026:11)
2017-07-12T18:55:37.142664127Z stdout: at WriteWrap.afterWrite (net.js:799:14) code: 'EPROTO', errno: 'EPROTO', syscall: 'write' }

Not sure if this has to do with my openwhisk install or this package.

I can not create alarm trigger successfully

  • wsk trigger create every-20-seconds --feed /whisk.system/alarms/alarm --param cron "*/20*****" -i
    ok: invoked /whisk.system/alarms/alarm with id 74a8193604df44b8a52e1cca29e0c56a
    {
    "activationId": "74a8193604df44b8a52e1cca29e0c56a",
    "annotations": [
    {
    "key": "limits",
    "value": {
    "logs": 10,
    "memory": 256,
    "timeout": 60000
    }
    },
    {
    "key": "path",
    "value": "whisk.system/alarms/alarm"
    }
    ],
    "duration": 574,
    "end": 1500452940219,
    "logs": [],
    "name": "alarm",
    "namespace": "whisk.system",
    "publish": false,
    "response": {
    "result": {
    "error": {
    "code": "ENOTFOUND",
    "errno": "ENOTFOUND",
    "host": "https",
    "hostname": "https",
    "port": 443,
    "syscall": "getaddrinfo"
    }
    },
    "status": "application error",
    "success": false
    },
    "start": 1500452939645,
    "subject": "whisk.system",
    "version": "0.0.2"
    }
    ok: invoked /whisk.system/alarms/alarm with id ed3531ef43fd4d2890acc603e5505ac8
    {
    "activationId": "ed3531ef43fd4d2890acc603e5505ac8",
    "annotations": [
    {
    "key": "limits",
    "value": {
    "logs": 10,
    "memory": 256,
    "timeout": 60000
    }
    },
    {
    "key": "path",
    "value": "whisk.system/alarms/alarm"
    }
    ],
    "duration": 78,
    "end": 1500452941264,
    "logs": [],
    "name": "alarm",
    "namespace": "whisk.system",
    "publish": false,
    "response": {
    "result": {
    "error": {
    "code": "ENOTFOUND",
    "errno": "ENOTFOUND",
    "host": "https",
    "hostname": "https",
    "port": 443,
    "syscall": "getaddrinfo"
    }
    },
    "status": "application error",
    "success": false
    },
    "start": 1500452941186,
    "subject": "whisk.system",
    "version": "0.0.2"
    }
    ok: deleted trigger every-20-seconds
    Run 'wsk --help' for usage.

  • wsk activation logs ed3531ef43fd4d2890acc603e5505ac8 -i
    2017-07-19T08:29:01.263479037Z stdout: alarm: Error invoking whisk action: { Error: getaddrinfo ENOTFOUND https https:443
    2017-07-19T08:29:01.263512011Z stdout: at errnoException (dns.js:28:10)
    2017-07-19T08:29:01.26351504Z stdout: at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:76:26)
    2017-07-19T08:29:01.263517885Z stdout: code: 'ENOTFOUND',
    2017-07-19T08:29:01.263520075Z stdout: errno: 'ENOTFOUND',
    2017-07-19T08:29:01.263522205Z stdout: syscall: 'getaddrinfo',
    2017-07-19T08:29:01.263524304Z stdout: hostname: 'https',
    2017-07-19T08:29:01.263526515Z stdout: host: 'https',
    2017-07-19T08:29:01.263528911Z stdout: port: 443 }

Did you start up the alarms service provider or just install the actions? The installCatalog.sh script only installs the actions. You also need to build the alarms provider docker image and run it.

I noticed the dockerfile in there... I didn't know if that's something I have to build, or if the image is pulled from somewhere. Are there instructions regarding installing the service provider?

Please see the following issue for building and running the service provider:
#51

We will be adding ansible support soon for deploying the service provider and installing the actions.

That link helps. I'm deploying on kubernetes, so those instructions won't quite work as-is. It shouldn't be too hard to figure out though.

@csantanapr - can you please close this issue.