Apache openserverless

Clone this repo:

Branches

  1. d9365b1 Merge pull request #5 from giusdp/main by Francesco Timperi Tiberi · 3 weeks ago main
  2. 8280952 docs: update readme by Giuseppe De Palma · 3 weeks ago
  3. db57681 test: add complete flow test by Giuseppe De Palma · 3 weeks ago
  4. ebcefef feat: add GET endpoints by Giuseppe De Palma · 3 weeks ago
  5. 6e1d620 fix: early close channel by Giuseppe De Palma · 4 weeks ago

Apache OpenServerless Streamer (incubating)

The OpenServerless streamer is a tool to relay a stream from OpenWhisk actions to an outside HTTP client.

The streamer is a simple HTTP server that exposes an endpoint /stream/{namespace}/{action} to invoke the relative OpenWhisk action, open a socket for the action to write to, and relay the output to the client.

It expects 2 environment variables to be set:

  • OW_APIHOST: the OpenWhisk API host
  • STREAMER_ADDR: the address of the streamer server for the OpenWhisk actions to connect to

Other environment variables can be set to configure the streamer:

  • HTTP_SERVER_PORT: the port the streamer server listens on (default: 8181)

Endpoints

The streamer exposes the following endpoints (use POST in case you need to send arguments to the action):

  • GET/POST /action/{namespace}/{action}: to invoke the OpenWhisk action on the given namespace, default package, and action name. It requires an a Authorization header with Bearer token with the OpenWhisk AUTH token

  • GET/POST /action/{namespace}/{package}/{action}: to invoke the OpenWhisk action on the given namespace, custom package, and action name. It requires an a Authorization header with Bearer token with the OpenWhisk AUTH token

  • GET/POST /web/{namespace}/{action}: to invoke an OpenWhisk web action on the given namespace, default package, and action name.

  • GET/POST /web/{namespace}/{package}/{action}: to invoke an OpenWhisk web action on the given namespace, custom package, and action name.