Home

/autoactions/recent_violations

Gets a list of recent AutoAction violations.

Request
GET http://unravel-host:3000/api/v1/autoactions/recent_violations?start_time={timestamp}&end_time={timestamp}&limit={integer}"
Path parameters

None.

Query parameters

Required parameters are highlighted.

Name

Type

Description

start_time

string

Starting date of date range. Format: YYYY-MM-DD.

end_time

string

Ending date of date range. Format: YYYY-MM-DD.

limit

integer

Maximum number of violations to return.

Default: 100

Response body

Name

Type

Description

[violation]

array

JSON structure containing a list of violations

Violation

Name

Type

Description

entityType

integer

Application type:

1: Hive
2: MapReduce
3: Spark

clusterName

string

Cluster name on which the AutAction violation occurred.

appId

string

App Id which violated the AutoAction.

eventTime

integer

Time of the violation in Unix epoch format.

eventName

string

AutoAction name assigned at creation.

entityId

string

Each violation has an entityId assigned by Unravel.

user

string

The user who created the AutoAction, typically admin.

queue

string

The queue name on which the AuotAction violation occurred.

Examples

Request:

curl -X GET "http://tnode75.unraveldata.com:3000/api/v1/autoactions/recent_violations?start_time=2019-11-01&end_time=2019-11-31&limit=1" -H "accept: application/json" -H  "Authorization: JWT token"

Response body:

[
  {
   "entityType": 0,
   "clusterName": "N/A",
   "appId": "http://node.company.com:3000/#/app/operations/charts/impala?from=1578397319224&to=1578397919224&at=1578397619224&interval=1m",
   "eventTime": 1578397619224,
   "eventName": "Long running impala query",
   "entityId": "8496537073757152411",
   "user": "N/A",
   "queue": "N/A"
   }
]