add sandbox observability contracts
This commit is contained in:
parent
e9ef178b15
commit
a86e1ee8c7
6 changed files with 131 additions and 0 deletions
|
|
@ -24,6 +24,8 @@ class SandboxSessionRepository(Protocol):
|
|||
|
||||
def list_expired(self, now: datetime) -> list[SandboxSession]: ...
|
||||
|
||||
def count_active(self) -> int: ...
|
||||
|
||||
def save(self, session: SandboxSession) -> None: ...
|
||||
|
||||
def delete(self, session_id: UUID) -> None: ...
|
||||
|
|
@ -86,6 +88,13 @@ class Metrics(Protocol):
|
|||
attrs: Attrs | None = None,
|
||||
) -> None: ...
|
||||
|
||||
def set(
|
||||
self,
|
||||
name: str,
|
||||
value: int | float,
|
||||
attrs: Attrs | None = None,
|
||||
) -> None: ...
|
||||
|
||||
|
||||
class Span(Protocol):
|
||||
def set_attribute(self, name: str, value: AttrValue) -> None: ...
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue