streamsx.rest_primitives module¶
-
class
streamsx.rest_primitives.ActiveService(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElement
-
class
streamsx.rest_primitives.ActiveVersion(json_active_version)¶ Bases:
object
-
class
streamsx.rest_primitives.ActiveView(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe deprecated active view element resource provides access to information about a view that is active.
-
class
streamsx.rest_primitives.ConfiguredView(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe deprecated configured view element resource provides access to configuration information for a view.
-
class
streamsx.rest_primitives.Domain(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe domain element resource provides access to information about an InfoSphere Streams domain.
-
get_active_services()¶
-
get_hosts()¶
-
get_instances()¶
-
get_resource_allocations()¶
-
get_resources()¶
-
-
class
streamsx.rest_primitives.ExportedStream(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElement
-
class
streamsx.rest_primitives.Host(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe host element resource provides access to information about a host that is allocated to a domain as a resource for running Streams services and applications.
-
class
streamsx.rest_primitives.ImportedStream(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElement
-
class
streamsx.rest_primitives.Installation(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElement
-
class
streamsx.rest_primitives.Instance(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe instance element resource provides access to information about a Streams instance.
-
get_active_services()¶
-
get_active_views()¶
-
get_configured_views()¶
-
get_domain()¶
-
get_exported_streams()¶
-
get_hosts()¶
-
get_imported_streams()¶
-
get_jobs(id=None, name=None)¶
-
get_operator_connections()¶
-
get_operators()¶
-
get_pe_connections()¶
-
get_pes()¶
-
get_resource_allocations()¶
-
get_views()¶
-
-
class
streamsx.rest_primitives.Job(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe job element resource provides access to information about a submitted job within a specified instance.
-
cancel(force=False)¶ Cancel this job.
Parameters: force (bool) – Forcefully cancel this job. Returns: True if the job was cancelled, otherwise False if an error occurred.
-
get_active_views()¶
-
get_domain()¶
-
get_hosts()¶
-
get_instance()¶
-
get_operator_connections()¶
-
get_operators()¶
-
get_pe_connections()¶
-
get_pes()¶
-
get_resource_allocations()¶
-
get_views()¶
-
-
class
streamsx.rest_primitives.Metric(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementMetric resource provides access to information about a Streams metric.
-
class
streamsx.rest_primitives.Operator(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe operator element resource provides access to information about a specific operator in a job.
-
get_metrics(name=None)¶ Get metrics for an operator.
Parameters: name (str) – Only return metrics matching nameas a regular expression usingre.match(name, metric_name. If name is not supplied then all metrics for this operator are returned.Returns: list – List of matching metrics. Return type: Metric
-
-
class
streamsx.rest_primitives.OperatorConnection(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe operator connection element resource provides access to information about a connection between two operator ports.
-
class
streamsx.rest_primitives.PE(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe processing element (PE) resource provides access to information about a PE.
-
class
streamsx.rest_primitives.PEConnection(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe processing element (PE) connection resource provides access to information about a connection between two processing element (PE) ports.
-
class
streamsx.rest_primitives.Resource(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElement-
get_resource()¶
-
-
class
streamsx.rest_primitives.ResourceAllocation(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElement
-
class
streamsx.rest_primitives.ResourceTag(json_resource_tag)¶ Bases:
object
-
class
streamsx.rest_primitives.StreamingAnalyticsService(rest_client, credentials)¶ Bases:
objectStreaming Analytics service running on IBM Bluemix cloud platform.
-
class
streamsx.rest_primitives.StreamsRestClient(username, password, resource_url)¶ Bases:
objectHandles the session connection with the Streams REST API.
Parameters: - username (str.) – The username of an authorized Streams user.
- password (str.) – The password associated with the username.
- resource_url – The resource endpoint of the instance. Can be found with st geturl –api for local Streams
installs. :type resource_url: str.
-
make_request(url)¶
-
class
streamsx.rest_primitives.View(json_view, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementThe view element resource provides access to information about a view that is associated with an active job, and exposes methods to retrieve data from the View’s Stream.
-
get_domain()¶
-
get_instance()¶
-
get_job()¶
-
get_view_items()¶
-
start_data_fetch()¶
-
stop_data_fetch()¶
-
-
class
streamsx.rest_primitives.ViewItem(json_rep, rest_client)¶ Bases:
streamsx.rest_primitives._ResourceElementRepresents the data of a tuple, it’s type, and the time when it was collected from the stream.
-
class
streamsx.rest_primitives.ViewThread(view)¶ Bases:
threading.ThreadA thread which, when invoked, begins fetching data from the supplied view and populates the View.items queue.
-
streamsx.rest_primitives.get_view_obj(_view, rc)¶