Table of Contents

Search

  1. Preface
  2. Introduction to Edge Data Streaming Custom Entity Types
  3. Managing Custom Entity Types
  4. Custom Entities from Maven Archetypes
  5. REST APIs
  6. HTTP Request and Response Parameters
  7. Sample JSON Requests and Responses
  8. Glossary

Developer Guide

Developer Guide

Update Aggregator

Update Aggregator

Use the POST method to update an aggregator in EDS.

POST Request in JSON Format

Generate a POST request. For example, the following POST request updates an aggregator:
POST /api/dataflows/{dataflowId:\\d+}/aggregators Content-Type: application/json Accept: application/json x-http-method-override: PUT

POST Body in JSON Format

{ "config": { "description": "", "eventQueueSize": "100000", "topicName": "", "topicDescription": "", "topicExpiresIn": "", "topicResponderAccess": "NAMED_PROPERTIES" }, "stats": [{ "name": "Bytes Received", "value": 10501, "type": 101 }, { "name": "Events Received", "value": 10503, "type": 101 }, { "name": "Receive Rate(Per Sec)", "value": 10504, "type": 101 }, { "name": "Bytes Sent", "value": 10001, "type": 101 }, { "name": "Events Sent", "value": 10003, "type": 101 }, { "name": "Send Rate(Per Sec)", "value": 10005, "type": 101 }, { "name": "Events Reassigned", "value": 10505, "type": 101 }, { "name": "Events to be Processed", "value": 10601, "type": 101 }], "name": "aggregator_updated", "pluginId": "_VDS_AGGREGATOR", "topics": [], "topicProperties": [] }

POST Response in JSON Format

The following is a sample response for the 200 OK code:
{ "id": 4, "name": "aggregator_updated", "self": { "rel": "self", "href": "api/dataflows/1/aggregator/4", "title": "aggregator_updated", "id": 4 }, "dataflow": { "rel": "dataflow", "href": "api/dataflows/1", "title": "Data flow", "id": 1 }, "type": "AGGREGATOR", "valid": true, "createDate": "2015-07-22T02:17:02-07:00", "createdBy": "Administrator", "predefined": false, "deployable": false, "force": false, "pluginId": "_VDS_AGGREGATOR", "schedulable": false, "config": { "topicExpiresIn": "", "topicDescription": "", "description": "", "topicResponderAccess": "NAMED_PROPERTIES", "topicName": "", "eventQueueSize": "100000" }, "stats": [{ "name": "Bytes Received", "value": 10501, "type": 101 }, { "name": "Events Received", "value": 10503, "type": 101 }, { "name": "Receive Rate(Per Sec)", "value": 10504, "type": 101 }, { "name": "Bytes Sent", "value": 10001, "type": 101 }, { "name": "Events Sent", "value": 10003, "type": 101 }, { "name": "Send Rate(Per Sec)", "value": 10005, "type": 101 }, { "name": "Events Reassigned", "value": 10505, "type": 101 }, { "name": "Events to be Processed", "value": 10601, "type": 101 }], "topics": [], "topicProperties": [] }
The following is the sample response for the 404 Not Found code:
{ "success": false, "errors": [ { "code": AGGREGATOR_NOT_FOUND, "parameters": [{aggregator-id}], "errorMessage": "Aggregator with Id: {aggregator-id} not found" } ] }
The following is a sample response for the 400 Bad Request code:
{ "success": false, "errors": [ { "code": AGGREGATOR_NAME_ALREADY_EXISTS, "parameters": null, "errorMessage": "Aggregator name already exists." } ] }
The following is a sample response for the 500 Internal Server Error code:
{ "success": false, "errors": [ { "code": INTERNAL_SERVER_ERROR, "parameters": [{error-message}], "errorMessage": "Failed to update aggregator. Exception : {error-message}" } ] }

0 COMMENTS

We’d like to hear from you!