Getting Details for a Stream

Get the details for a stream in the Streaming service. Stream details include the Messages endpoint and the stream OCID.

  • On the Streams list page, select the stream that you want to work with. If you need help finding the list page or the stream, see Listing Streams.
  • Use the oci streaming admin stream get command and required parameters to get details for a stream:

    oci streaming admin stream get --stream-id <stream_OCID>

    For example:

    oci streaming admin stream get --stream-id ocid1.stream.oc1.phx.exampleuniqueID
    {
      "data": {
        "compartment-id": "ocid1.tenancy.oc1..exampleuniqueID",
        "defined-tags": {},
        "freeform-tags": {},
        "id": "ocid1.stream.oc1.phx.exampleuniqueID",
        "lifecycle-state": "ACTIVE",
        "lifecycle-state-details": null,
        "messages-endpoint": "https://cell-1.streaming.us-phoenix-1.oci.oraclecloud.com",
        "name": "MyStream",
        "partitions": 5,
        "retention-in-hours": 24,
        "stream-pool-id": "ocid1.streampool.oc1.phx.exampleuniqueID",
        "time-created": "2020-11-02T19:12:22.385000+00:00"
      },
      "etag": "\"0613d634-86ab-4446-973f-268d175313d4-12e9725e-5574-4f6b-995b-7dcc80271666\""
    }

    For a complete list of parameters and values for CLI commands, see the CLI Command Reference.

  • Run the GetStream operation to get details for a stream.

Using Resource Manager and Terraform

Use the oci_streaming_stream data source to get the details for a stream.

For example:

data "oci_streaming_stream" "test_stream" {
  #Required
  stream_id = oci_streaming_stream.stream.id
}
About Resource Manager and Terraform

Resource Manager is an Oracle Cloud Infrastructure (OCI) service that allows you to automate the process of provisioning your OCI resources. Using Terraform, Resource Manager helps you install, configure, and manage resources through the "infrastructure-as-code" model.

A Terraform configuration codifies your infrastructure in declarative configuration files. The configuration defines the resources you intend to provision, variables, and specific instructions for provisioning the resources

You can use Resource Manager or the Terraform CLI with the OCI Terraform provider to see how your streams and stream pools are represented in Terraform configuration files.

For more information about writing configurations for use with Resource Manager, see Terraform Configurations for Resource Manager and Terraform Configuration.