eubr-bigsea / stand

Lemonade execution monitoring API
Apache License 2.0
1 stars 2 forks source link

Standardize logs #28

Closed mgonc closed 5 years ago

mgonc commented 7 years ago

On a job execution, step's logs must be the same either recovered by the get request or by socket requests. Suggestion of info:

"logs": [
  {
    "id": 5396,
    "status": "RUNNING",
    "date": "2017-11-01T20:27:50+00:00",
    "message": "Task running",
    "type": "TEXT"
    "task_id": "ba5b9904-89a7-11e7-8c51-0242ac150008"
}
]

Same to frames

frame = {
    "id": 5396,
    "status": "RUNNING",
    "date": "2017-11-01T20:27:50+00:00",
    "message": "Task running",
    "type": "TEXT"
    "task_id": "ba5b9904-89a7-11e7-8c51-0242ac150008"
}
mgonc commented 6 years ago

Error message needed to enter in this standard too. Current format is

{ 
  id: "39b492cb-f024-4f37-bb57-dc076e3ed62e",
  msg: "Error",
  status: "error"
 }

To apply the same standard

{ 
  id: log_id,
  status: "ERROR",
  date: "2017-11-01T20:27:50+00:00",
  message: spark_error,
  type: "TEXT",
  task: { id: "39b492cb-f024-4f37-bb57-dc076e3ed62e" }
}
mgonc commented 6 years ago

Result frame and result array need to setted to the standard

id: result_id,
message: "Resultado gerado"
operation: {id: "70"}
operation_id: "70"
status: "completed"
task_id: "ba5b96de-89a7-11e7-8c51-0242ac150008"
title: "Passagem/Valor (sumarização)"
type: "VISUALIZATION"
waltersf commented 6 years ago

@mgonc First version is deployed. But it is difficult to find all cases. Please, test and report if there are more cases to be standardized.

mgonc commented 6 years ago

Error message is not standardized. Error must be a log too

waltersf commented 5 years ago

Fixed