# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import copy
import warnings
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
from .. import _utilities
from . import outputs

__all__ = [
    'GetExternalExadataStorageServerOpenAlertHistoryResult',
    'AwaitableGetExternalExadataStorageServerOpenAlertHistoryResult',
    'get_external_exadata_storage_server_open_alert_history',
    'get_external_exadata_storage_server_open_alert_history_output',
]

@pulumi.output_type
class GetExternalExadataStorageServerOpenAlertHistoryResult:
    """
    A collection of values returned by getExternalExadataStorageServerOpenAlertHistory.
    """
    def __init__(__self__, alerts=None, external_exadata_storage_server_id=None, id=None):
        if alerts and not isinstance(alerts, list):
            raise TypeError("Expected argument 'alerts' to be a list")
        pulumi.set(__self__, "alerts", alerts)
        if external_exadata_storage_server_id and not isinstance(external_exadata_storage_server_id, str):
            raise TypeError("Expected argument 'external_exadata_storage_server_id' to be a str")
        pulumi.set(__self__, "external_exadata_storage_server_id", external_exadata_storage_server_id)
        if id and not isinstance(id, str):
            raise TypeError("Expected argument 'id' to be a str")
        pulumi.set(__self__, "id", id)

    @property
    @pulumi.getter
    def alerts(self) -> Sequence['outputs.GetExternalExadataStorageServerOpenAlertHistoryAlertResult']:
        """
        A list of open alerts.
        """
        return pulumi.get(self, "alerts")

    @property
    @pulumi.getter(name="externalExadataStorageServerId")
    def external_exadata_storage_server_id(self) -> str:
        return pulumi.get(self, "external_exadata_storage_server_id")

    @property
    @pulumi.getter
    def id(self) -> str:
        """
        The provider-assigned unique ID for this managed resource.
        """
        return pulumi.get(self, "id")


class AwaitableGetExternalExadataStorageServerOpenAlertHistoryResult(GetExternalExadataStorageServerOpenAlertHistoryResult):
    # pylint: disable=using-constant-test
    def __await__(self):
        if False:
            yield self
        return GetExternalExadataStorageServerOpenAlertHistoryResult(
            alerts=self.alerts,
            external_exadata_storage_server_id=self.external_exadata_storage_server_id,
            id=self.id)


def get_external_exadata_storage_server_open_alert_history(external_exadata_storage_server_id: Optional[str] = None,
                                                           opts: Optional[pulumi.InvokeOptions] = None) -> AwaitableGetExternalExadataStorageServerOpenAlertHistoryResult:
    """
    This data source provides details about a specific External Exadata Storage Server Open Alert History resource in Oracle Cloud Infrastructure Database Management service.

    Gets the open alerts from the specified Exadata storage server.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_oci as oci

    test_external_exadata_storage_server_open_alert_history = oci.DatabaseManagement.get_external_exadata_storage_server_open_alert_history(external_exadata_storage_server_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
    ```


    :param str external_exadata_storage_server_id: The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Exadata storage server.
    """
    __args__ = dict()
    __args__['externalExadataStorageServerId'] = external_exadata_storage_server_id
    opts = pulumi.InvokeOptions.merge(_utilities.get_invoke_opts_defaults(), opts)
    __ret__ = pulumi.runtime.invoke('oci:DatabaseManagement/getExternalExadataStorageServerOpenAlertHistory:getExternalExadataStorageServerOpenAlertHistory', __args__, opts=opts, typ=GetExternalExadataStorageServerOpenAlertHistoryResult).value

    return AwaitableGetExternalExadataStorageServerOpenAlertHistoryResult(
        alerts=__ret__.alerts,
        external_exadata_storage_server_id=__ret__.external_exadata_storage_server_id,
        id=__ret__.id)


@_utilities.lift_output_func(get_external_exadata_storage_server_open_alert_history)
def get_external_exadata_storage_server_open_alert_history_output(external_exadata_storage_server_id: Optional[pulumi.Input[str]] = None,
                                                                  opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetExternalExadataStorageServerOpenAlertHistoryResult]:
    """
    This data source provides details about a specific External Exadata Storage Server Open Alert History resource in Oracle Cloud Infrastructure Database Management service.

    Gets the open alerts from the specified Exadata storage server.

    ## Example Usage

    ```python
    import pulumi
    import pulumi_oci as oci

    test_external_exadata_storage_server_open_alert_history = oci.DatabaseManagement.get_external_exadata_storage_server_open_alert_history(external_exadata_storage_server_id=%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))
    ```


    :param str external_exadata_storage_server_id: The [OCID](https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm) of the Exadata storage server.
    """
    ...
