Skip to content

Support for timers #2

Description

@woile

Goal

Execute scheduled functions

Discussion

Ideas

1. Decorator

fromdamimportsend, timer@timer(ms=20)asyncdefhello():
send("a-topic", {"name": "jon"}

2. Add them in a list

This would follow a similar approach to routes

fromdamimportTimer, Appfrom .myappimporthellotimers= [
Timer(hello, ms=20)
]
App(timers=timers)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions