Serverless Model Type

Merlijn Sebrechts merlijn.sebrechts at
Thu Nov 16 16:32:19 UTC 2017


With some care, one solution could be used for both containers, serverless
functions and more. We just need two new types of charms:

 - A "platform" charm which connects to the serverless platform and deploys
the function.
 - A "job" charm which describes the function. This is basically a bundle
of metadata.

Connecting the `platform` to the `job` charm will cause a `job-joined` hook
in the platform charm, which can then use `job-get` to get the metadata
describing the function and deploy the function on the platform. This way,
you empower the community to create new "platform" charms for whichever
platforms they see fit: AWS lambda, Kubernetes, Heroku and even Apache

 - Juju doesn't need to know the details of each platform because the
connection to the platform is part of the charm.
 - Juju doesn't need to know the details of each "job" type, because the
"job" charm is just a bunch of metadata.

Now add the ability for "job" charms to optionally include relation hooks,
and you can seamlessly connect serverless functions to your existing
infrastructure. Or connect Apache Spark jobs to your existing

We've created a number of prototypes of this to model and deploy Kubernetes
and Apache Storm topologies in Juju. We used normal charms and relations
for our "platform" and "job" charms. This works really wel, the only issue
is that deploying an entire Juju Agent is waaaay too much overhead for
modeling a single Docker container, so we would be really happy if Juju
could introduce the idea of "job" charms.

Kind regards

2017-11-16 17:04 GMT+01:00 James Beedy <jamesbeedy at>:

> How do people feel about Juju supporting a serverless model type, and
> serverless charm?
> Some innovative wrappers popping up that facilitate deploying lambda
> functions:
>   - `serverless deploy` -
>   - `zappa deploy` -
> I feel like Juju has the proper constructs needed to support a SL model
> type, and a special SL type charm.
> Just an idea, thought I would throw it out there....
> Thoughts?
> --
> Juju-dev mailing list
> Juju-dev at
> Modify settings or unsubscribe at:
> mailman/listinfo/juju-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the Juju mailing list