コード例 #1
0
from flux.bindings import docket, platoon
from flux.bundles import API
from flux.operations import OPERATIONS
from flux.resources import *

Executor = bind(platoon, 'platoon/1.0/executor')
Intent = bind(docket, 'docket/1.0/intent')
Registration = bind(docket, 'docket/1.0/registration')
SubscribedTask = bind(platoon, 'platoon/1.0/subscribedtask')

ENTITY_REGISTRATIONS = [
    Registration(
        id='flux:workflow',
        name='workflow',
        title='Workflow',
        specification=API.describe(['workflow']),
        cached_attributes={
            'is_service': {
                'type': 'boolean'
            },
            'type': {
                'type': 'text'
            },
        },
    ),
    Registration(
        id='flux:run',
        name='run',
        title='Run',
        specification=API.describe(['run']),
        change_event='run:changed',
コード例 #2
0
ファイル: components.py プロジェクト: siq/flux
from flux.bindings import docket, platoon
from flux.bundles import API
from flux.operations import OPERATIONS
from flux.resources import *

Executor = bind(platoon, "platoon/1.0/executor")
Intent = bind(docket, "docket/1.0/intent")
Registration = bind(docket, "docket/1.0/registration")
SubscribedTask = bind(platoon, "platoon/1.0/subscribedtask")

ENTITY_REGISTRATIONS = [
    Registration(
        id="flux:workflow",
        name="workflow",
        title="Workflow",
        specification=API.describe(["workflow"]),
        cached_attributes={"is_service": {"type": "boolean"}, "type": {"type": "text"}},
    ),
    Registration(
        id="flux:run",
        name="run",
        title="Run",
        specification=API.describe(["run"]),
        change_event="run:changed",
        cached_attributes={"status": {"type": "text"}},
    ),
    Registration(
        id="flux:request",
        name="request",
        title="Request",
        specification=API.describe(["request"]),
コード例 #3
0
ファイル: components.py プロジェクト: siq/flux
from flux.bindings import docket, platoon
from flux.bundles import API
from flux.operations import OPERATIONS
from flux.resources import *

Executor = bind(platoon, 'platoon/1.0/executor')
Intent = bind(docket, 'docket/1.0/intent')
Registration = bind(docket, 'docket/1.0/registration')
SubscribedTask = bind(platoon, 'platoon/1.0/subscribedtask')

ENTITY_REGISTRATIONS = [
    Registration(
        id='flux:workflow',
        name='workflow',
        title='Workflow',
        specification=API.describe(['workflow']),
        cached_attributes={
            'is_service': {'type': 'boolean'},
            'type': {'type': 'text'},
        },
    ),
    Registration(
        id='flux:run',
        name='run',
        title='Run',
        specification=API.describe(['run']),
        change_event='run:changed',
        cached_attributes={
            'status': {'type': 'text'},
        },
    ),
コード例 #4
0
ファイル: components.py プロジェクト: siq-legacy/flux
from spire.core import Component, Dependency
from spire.mesh import MeshDependency, MeshServer
from spire.runtime import onstartup

import flux.models
from flux.bindings import docket, platoon
from flux.bundles import API
from flux.operations import OPERATIONS
from flux.resources import *

Executor = bind(platoon, "platoon/1.0/executor")
Intent = bind(docket, "docket/1.0/intent")
Registration = bind(docket, "docket/1.0/registration")

ENTITY_REGISTRATIONS = [
    Registration(id="flux:workflow", name="workflow", title="Workflow", specification=API.describe(["workflow"])),
    Registration(
        id="flux:run",
        name="run",
        title="Run",
        specification=API.describe(["run"]),
        change_event="run:changed",
        cached_attributes={"status": {"type": "text"}},
    ),
]

GENERATED_BY = Intent(id="generated-by", name="Generated by", exclusive=True)


class Flux(Component):
    api = MeshServer.deploy(bundles=[API])