Returns events related to Cache Clusters, Cache Security Groups, and Cache Parameter Groups for
the past 14 days. Events specific to a particular Cache Cluster, Cache Security Group, or Cache
Parameter Group can be obtained by providing the name as a parameter. By default, the past hour
of events are returned.
Access
Parameters
Parameter |
Type |
Required |
Description |
$opt
|
array
|
Optional
|
An associative array of parameters that can have the following keys:
SourceIdentifier - string - Optional - The identifier of the event source for which events will be returned. If not specified, then all sources are included in the response.SourceType - string - Optional - The event source to retrieve events for. If no value is specified, all events are returned. [Allowed values: cache-cluster , cache-parameter-group , cache-security-group , cache-subnet-group ]StartTime - string - Optional - The beginning of the time interval to retrieve events for, specified in ISO 8601 format. May be passed as a number of seconds since UNIX Epoch, or any string compatible with strtotime() .EndTime - string - Optional - The end of the time interval for which to retrieve events, specified in ISO 8601 format. May be passed as a number of seconds since UNIX Epoch, or any string compatible with strtotime() .Duration - integer - Optional - The number of minutes to retrieve events for.MaxRecords - integer - Optional - The maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a marker is included in the response so that the remaining results may be retrieved.Marker - string - Optional - An optional marker provided in the previous DescribeCacheClusters request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.curlopts - array - Optional - A set of values to pass directly into curl_setopt() , where the key is a pre-defined CURLOPT_* constant.returnCurlHandle - boolean - Optional - A private toggle specifying that the cURL handle be returned rather than actually completing the request. This toggle is useful for manually managed batch requests. |
Returns
Examples
Describe all events.
In this example, there are no results.
$elasticache = new AmazonElastiCache();
$response = $elasticache->describe_events();
print_r($response->body->DescribeEventsResult);
Result:
CFSimpleXML Object
(
[Events] => CFSimpleXML Object
(
)
)
Source
Method defined in services/elasticache.class.php | Toggle source view (18 lines) | View on GitHub
public function describe_events($opt = null)
{
if (!$opt) $opt = array();
// Optional DateTime
if (isset($opt['StartTime']))
{
$opt['StartTime'] = $this->util->convert_date_to_iso8601($opt['StartTime']);
}
// Optional DateTime
if (isset($opt['EndTime']))
{
$opt['EndTime'] = $this->util->convert_date_to_iso8601($opt['EndTime']);
}
return $this->authenticate('DescribeEvents', $opt);
}