Create Collector
This API is useful for creating a new collector instance of given type( like cisco-aci,vims,kafka-collector )
Package name to be used to create collector e.g. cisco-aci, smarts-metrics
cisco-aci
Name of the collector instance. If no name is provided then it is created as a dm collector. DM collectors do not show up by default on the UI.
demo-collector
Provision a new collector Block.
{
"source": {
"topic": "metrics1",
"type": "json_metrics",
"mapping_name": "KMD RegEx",
"properties": {
"bootstrap.servers": "localhost:9092",
"username": "string",
"password": "string",
"application.id": "omega-kafka-collector",
"auto.offset.reset": "earliest",
"group.id": "omega-consumer-group",
"key.deserializer": "org.apache.kafka.common.serialization.StringDeserializer",
"value.deserializer": "org.apache.kafka.common.serialization.StringDeserializer"
}
},
"sink": {
"topic": "vsa_metrics_raw"
}
}
Source cluster details e.g. source topic name , mapping name etc.
Target kafka cluster topic name
Returns Block Config for the newly created block
{
"blockID": "cisco-aci",
"message": "Block successfully deployed",
"time": "2023-11-22 08:17:04.144411",
"name": "test-aci",
"instanceId": "test-aci",
"containerId": "test-aci",
"display_name": "test-aci",
"params": "{\n \"collect\": {\n \"collectormode\": \"acidiscovery\"\n },\n \"aci\": {\n \"host\": [\n {\n \"hostname\": \"localhost\",\n \"username\": \"admin\",\n \"password\": \"{6F0B1CB041DEB7A3CA71B3E15A56CDB1F11850A1C66911793CAD2A12DF38B94C5C6291BEB130396AF49ED2C988617FB0}\",\n \"port\": \"443\",\n \"protocol\": \"https\"\n }\n ]\n },\n \"controllerNode\": [\n {\n \"host\": \"localhost\"\n }\n ],\n \"kafka\": {\n \"cluster\": {\n \"node\": [\n {\n \"host\": \"localhost\",\n \"port\": \"9092\"\n }\n ],\n \"topic\": \"default-topic\",\n \"auth\": \"true\",\n \"username\": \"admin\",\n \"password\": \"{16A8027BDEAB404C2D696034921260F488BB4E6A591CE696DBB5F9C7177C1409A575AB5E93CE1165829EE1C7CB6E81F3}\"\n }\n },\n \"memory_max\": \"1024\",\n \"advanced_options\": \"true\",\n \"discovery_threads\": \"20\",\n \"collection_interval\": \"240\"\n }"
}
The package type of the collector created
The instanceId of the collector created.
The container Id of the collector created.
The name of the collector as provided by the user
This attribute provides information regarding the faiure or success of collector creation
The configuration with which the collector was set.
The time of creation of the collector object
Invalid Request sent by the user
User authentication failed
Access to the requested resource/operation is forbidden
Cannot find requested resource
Internal server error
curl -X POST -H 'Authorization: <value>' -H 'Content-Type: application/json' -d '{"source:"object","sink:"object"}' https://{api_host}/dcc/v1/collectors