Skip to main content

Tailored OPerations for serverLESS

Project description

Action Execution Model

The Topless actionexecution model is processed in two different steps:

  1. Action Handler Registration Every action created with one of the provided decorators (route, schedule, bucket or topic) is registered on the main Topless app instance. The instance is created on the client side (main.py file), and is shared throghouth the framework modules by a singleton pattern.

Flow of execution:

sequenceDiagram
    box Client
    participant C1 as bootstrap.py
    participant C2 as main.py
    end

    box Core
    participant T1 as bootstrap.py
    participant T2 as app.py
    participant T3 as handler.py
    end


    C1->>C2: Import main.py
    C2-->>C1: Topless instance and registrations
    C1->>T1: Start framework bootstrap
    T1->>T2: Load all modules
    T2->>T3: Map action handlers
    T1-->>C1: Finish setup
    
  1. Action Handler Execution When lambda is called, the client bootstrap.py handle method is executed. Every lambda resource on the template.yaml (dinamically generated by topless framework), will call this method at first, which will dispatch the bootstrap.handle method, to localize the action handler that is needed on that call.
sequenceDiagram
    participant L as Lambda Event
    participant CA as app.py (Client)
    participant CB as bootstrap.py (Client)
    participant TA as app.py (Core)
    participant TB as bootstrap.py (Core)
    participant TD as dispatcher.py (Core)
    participant TH as handler.py (Core)

    L->>CB: Trigger Lambda Function
    CB->>TB: Call framework bootstrap handler
    TB->>TD: Execute Dispatcher
    TD-->>TB: Construct action envelope and look for the correct action to be executed

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

topless-0.1.0.tar.gz (14.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

topless-0.1.0-py3-none-any.whl (20.0 kB view details)

Uploaded Python 3

File details

Details for the file topless-0.1.0.tar.gz.

File metadata

  • Download URL: topless-0.1.0.tar.gz
  • Upload date:
  • Size: 14.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.6.1 CPython/3.9.13 Darwin/22.3.0

File hashes

Hashes for topless-0.1.0.tar.gz
Algorithm Hash digest
SHA256 88f8a622b8a025f317f5de7b41b50aab56eb13fe4a81db6449dc70bfb2c84d37
MD5 137c5312c1430bd74095ee003f2baea0
BLAKE2b-256 9c2d1c4130d98c5de26dbb8be7b09979126934acb75c5a3d60835831a2d2661c

See more details on using hashes here.

File details

Details for the file topless-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: topless-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 20.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.6.1 CPython/3.9.13 Darwin/22.3.0

File hashes

Hashes for topless-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7b3647f9591a5096a8019239e74640afc44edeea26c82a7c615ace66f9cb4a9a
MD5 a9dce1b9b3b51df19101dc618852191f
BLAKE2b-256 0db2eb9ec689db3259b30b3a31ce937b1ba9afd6889c4173b956037e4ea8e9eb

See more details on using hashes here.

Supported by

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