event_sources
Creates, updates, deletes, gets or lists an event_sources
resource.
Overview
Name | event_sources |
Type | Resource |
Id | azure.time_series_insights.event_sources |
Fields
The following fields are returned by SELECT
queries:
- get
- list_by_environment
The event source definition was successfully retrieved and is in the response.
Name | Datatype | Description |
---|---|---|
kind | string | The kind of the event source. |
location | string | The geo-location where the resource lives |
tags | object | Resource tags. |
Environments returned successfully.
Name | Datatype | Description |
---|---|---|
kind | string | The kind of the event source. |
location | string | The geo-location where the resource lives |
tags | object | Resource tags. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | subscriptionId , resourceGroupName , environmentName , eventSourceName | Gets the event source with the specified name in the specified environment. | |
list_by_environment | select | subscriptionId , resourceGroupName , environmentName | Lists all the available event sources associated with the subscription and within the specified resource group and environment. | |
create_or_update | insert | subscriptionId , resourceGroupName , environmentName , eventSourceName , data__kind | Create or update an event source under the specified environment. | |
update | update | subscriptionId , resourceGroupName , environmentName , eventSourceName , data__kind | Updates the event source with the specified name in the specified subscription, resource group, and environment. | |
delete | delete | subscriptionId , resourceGroupName , environmentName , eventSourceName | Deletes the event source with the specified name in the specified subscription, resource group, and environment |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
environmentName | string | The name of the Time Series Insights environment associated with the specified resource group. |
eventSourceName | string | The name of the Time Series Insights event source associated with the specified environment. |
resourceGroupName | string | The name of the resource group. The name is case insensitive. |
subscriptionId | string | The ID of the target subscription. |
SELECT
examples
- get
- list_by_environment
Gets the event source with the specified name in the specified environment.
SELECT
kind,
location,
tags
FROM azure.time_series_insights.event_sources
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND environmentName = '{{ environmentName }}' -- required
AND eventSourceName = '{{ eventSourceName }}' -- required
;
Lists all the available event sources associated with the subscription and within the specified resource group and environment.
SELECT
kind,
location,
tags
FROM azure.time_series_insights.event_sources
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND environmentName = '{{ environmentName }}' -- required
;
INSERT
examples
- create_or_update
- Manifest
Create or update an event source under the specified environment.
INSERT INTO azure.time_series_insights.event_sources (
data__kind,
data__localTimestamp,
data__location,
data__tags,
subscriptionId,
resourceGroupName,
environmentName,
eventSourceName
)
SELECT
'{{ kind }}' /* required */,
'{{ localTimestamp }}',
'{{ location }}',
'{{ tags }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ environmentName }}',
'{{ eventSourceName }}'
RETURNING
kind,
location,
tags
;
# Description fields are for documentation purposes
- name: event_sources
props:
- name: subscriptionId
value: string
description: Required parameter for the event_sources resource.
- name: resourceGroupName
value: string
description: Required parameter for the event_sources resource.
- name: environmentName
value: string
description: Required parameter for the event_sources resource.
- name: eventSourceName
value: string
description: Required parameter for the event_sources resource.
- name: kind
value: string
description: |
The kind of the event source.
valid_values: ['Microsoft.EventHub', 'Microsoft.IoTHub']
- name: localTimestamp
value: object
description: |
An object that represents the local timestamp property. It contains the format of local timestamp that needs to be used and the corresponding timezone offset information. If a value isn't specified for localTimestamp, or if null, then the local timestamp will not be ingressed with the events.
- name: location
value: string
description: |
The location of the resource.
- name: tags
value: object
description: |
Key-value pairs of additional properties for the resource.
UPDATE
examples
- update
Updates the event source with the specified name in the specified subscription, resource group, and environment.
UPDATE azure.time_series_insights.event_sources
SET
data__kind = '{{ kind }}',
data__tags = '{{ tags }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND environmentName = '{{ environmentName }}' --required
AND eventSourceName = '{{ eventSourceName }}' --required
AND data__kind = '{{ kind }}' --required
RETURNING
kind,
location,
tags;
DELETE
examples
- delete
Deletes the event source with the specified name in the specified subscription, resource group, and environment
DELETE FROM azure.time_series_insights.event_sources
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND environmentName = '{{ environmentName }}' --required
AND eventSourceName = '{{ eventSourceName }}' --required
;