Skip to main content

No project description provided

Project description

LambdaBase

A library to support development of enterprise Serverless applications.

Serverless computing allows you to build and run applications without expending time and effort managing a server. Code is executed and billed only when called. Whilst this model provides many advantages such as horizontal scalability and reduced operational costs it creates it's own set of drawbacks such as debugging, testing and packaging.

There are numerous articles detailing the advantages and disadvantages of serverless architectures. It's worth considering all the salient points before starting down the serverless path however, in general, the zero configuration horizontal scalability and cost efficiencies are the most significant driving factors. The architecture described here helps to mitigate the disadvantages whilst magnifying the advantages.

As with any architecture there is no one size fits all solution, however, I've seen the following pattern implemented successfully in both Java and Python across multiple domains. I believe it provides a reasonable amount of flexibility whilst being sufficiently structured to help developers rapidly implement clean code. One of the guiding principles of this pattern is to overcome one of the most significant issues with Serverless - the difficulty of debugging and testing Serverless ready code in a local environment.

The key design points and the basis for this architecture are as follows:

  • Lambdas are grouped into functional areas. Each group contains multiple lambdas with different handlers for each function. This is to allow related lambdas to share common ode more easily and to simplify packaging and application structure.
  • It should always be possible to execute and debug the lambda code locally.
  • The configuration for each environment is packaged with each lambda. Which configuration file to use is specified by an environment variable which is specified at deployment time.
  • The code to package and deploy each of the lambdas lives with the runtime code
  • One click deployment to new environments should be trivial, and the concept of infrastructure as code should be maintained at all times.
  • Dependency injection is used to allow alternative services to be injected into lambdas depending on where they are running.

The proposed architecture is designed to fulfill these high level goals whilst maintaining a flexibility which should allow future extension and resilience to changing project requirements.

Push to PyPi:

python setup.py bdist_wheel python -m twine upload lambdabase-0.x-py2-none-any.whl

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lambdabase-0.6.tar.gz (15.5 kB view details)

Uploaded Source

Built Distribution

lambdabase-0.6-py2-none-any.whl (25.5 kB view details)

Uploaded Python 2

File details

Details for the file lambdabase-0.6.tar.gz.

File metadata

  • Download URL: lambdabase-0.6.tar.gz
  • Upload date:
  • Size: 15.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15

File hashes

Hashes for lambdabase-0.6.tar.gz
Algorithm Hash digest
SHA256 dc628dcc47194a9193ea4976e8f05959b0242896cc84fd64eea5e50a8f58a9d2
MD5 f5d78d73c9a9d99a29324e5daec36514
BLAKE2b-256 9c16d67922e73c85acf6ce9be0957dc09ae7cee84c98d3bb7e1b252ce41eafcf

See more details on using hashes here.

File details

Details for the file lambdabase-0.6-py2-none-any.whl.

File metadata

  • Download URL: lambdabase-0.6-py2-none-any.whl
  • Upload date:
  • Size: 25.5 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/39.0.1 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15

File hashes

Hashes for lambdabase-0.6-py2-none-any.whl
Algorithm Hash digest
SHA256 cb629ab5b8a6b022e436536cba1f0f1a1bdda596d370a2fc6f1f319f7f490a0d
MD5 dcb765439923f7b3a9d0133238310f40
BLAKE2b-256 93f5e10e72f7fd5983b5bde825c302675eca579f27f6ed69c5f6db90233c77cc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page