GetLog

更新时间:
复制 MD 格式

Retrieves log entries.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

ClusterId

string

Yes

The cluster ID.

xxljob-b6ec1xxxx

AppName

string

No

The application name.

test-app

JobExecutionId

string

No

The job execution ID.

1310630367761285120

StartTime

integer

No

The start time. This value is a UNIX timestamp.

1721636220

EndTime

integer

No

The end time. This value is a UNIX timestamp.

1721636220

Level

string

No

The log level.

INFO

Keyword

string

No

The keyword to search for.

hello word

Offset

integer

No

The offset.

0

LineNum

integer

No

The number of log entries to return.

2

Reverse

boolean

No

Specifies whether to sort the results in descending order.

  • true: sorts the results in descending order.

  • false: sorts the results in ascending order.

true

LogId

integer

No

The log ID.

344008

WorkerAddr

string

No

The worker address.

192.168.1.100

ScheduleTime

integer

No

The time when the job was scheduled. This value is a UNIX timestamp.

2023-10-01 12:00:00

Response elements

Element

Type

Description

Example

object

The response object.

RequestId

string

The request ID.

C78E2AD2-5985-515B-BAD2-31A248AFC263

Code

integer

The response code.

200

Success

boolean

Indicates whether the request was successful.

  • true: The request was successful.

  • false: The request failed.

true

Message

string

The error message.

Parameter check error

Data

array

The log entries.

string

The log information.

ip : 10.**.***.53:58098 executionId : 74_1310******761285120_0 level : INFO log : hello word!; time : 2024-10-31 16:43:51

Examples

Success response

JSON format

{
  "RequestId": "C78E2AD2-5985-515B-BAD2-31A248AFC263",
  "Code": 200,
  "Success": true,
  "Message": "Parameter check error",
  "Data": [
    "ip : 10.**.***.53:58098\nexecutionId : 74_1310******761285120_0\nlevel : INFO\nlog : hello word!;\ntime : 2024-10-31 16:43:51"
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidParameter Parameter error: %s. Parameter error: %s
401 IllegalRequest IllegalRequest: %s. Illegal request:%s
500 InternalError InternalError: %s. System Internal Error: %s
403 NoPermission No permission to perform this operation: %s. No permission to perform this operation: %s
404 NotFound Not found: %s. The resource does not exist: %s

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.