Skip to content

Commit 3bbe1e6

Browse files
committed
init
1 parent cf7576e commit 3bbe1e6

File tree

7 files changed

+47
-0
lines changed

7 files changed

+47
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
# cloud-runtimes-python
2+
23
Cloud Runtimes Specification for the Python3

api/__init__.py

Whitespace-only changes.

api/cloud_runtimes.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
from api.domain.configuration_runtimes import ConfigurationRuntimes
2+
from api.domain.logging_runtimes import LoggingRuntimes
3+
from api.domain.pubsub_runtimes import PubSubRuntimes
4+
5+
6+
class CloudRuntimes(ConfigurationRuntimes, PubSubRuntimes, LoggingRuntimes):
7+
pass

api/domain/__init__.py

Whitespace-only changes.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
from abc import abstractmethod
2+
from typing import Any
3+
4+
5+
class ConfigurationRuntimes(object):
6+
7+
@abstractmethod
8+
def get_configuration(self, store_name: str, app_id: str, group: str, label: str, keys: [str],
9+
metadata: dict) -> Any:
10+
pass
11+
12+
@abstractmethod
13+
def save_configuration(self):
14+
pass
15+
16+
@abstractmethod
17+
def delete_configuration(self):
18+
pass
19+
20+
@abstractmethod
21+
def subscribe_configuration(self, store_name: str, app_id: str, group: str, label: str, keys: [str],
22+
metadata: dict, func: callable) -> None:
23+
pass

api/domain/logging_runtimes.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
from abc import abstractmethod
2+
3+
4+
class LoggingRuntimes(object):
5+
6+
@abstractmethod
7+
def log(self, title: str, message: str, level: str, metadata: dict):
8+
pass

api/domain/pubsub_runtimes.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
from abc import abstractmethod
2+
3+
4+
class PubSubRuntimes(object):
5+
6+
@abstractmethod
7+
def publish_event(self, pubsub_name: str, topic_name: str, data: object, metadata: dict) -> str:
8+
pass

0 commit comments

Comments
 (0)