Simple Log Service can ship logs to Object Storage Service (OSS) and store them in JSON format.
Parameters
When you create an OSS data shipping job (new version), if you set Storage Format to json, configure the following parameters.
|
Parameter |
Description |
|
Ship Tag |
Specifies whether to ship log tag fields. Example: __tag__:abc. |
URLs of OSS objects
The following table lists sample OSS object URLs after data shipping.
-
If you specify an object suffix when you create a data shipping job, the objects use that suffix.
-
If you do not specify an object suffix when you create a data shipping job, the objects use a default suffix based on the compression type.
|
Compression type |
Object suffix |
Sample URL |
Description |
|
Not compressed |
If you specify an object suffix, the specified suffix is used. Example: .json. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.json |
Download the JSON file and open it as a text file. Sample content:
|
|
If you do not specify an object suffix, the object does not have a suffix. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937 |
||
|
Snappy |
If you specify an object suffix, the specified suffix is used. Example: .json. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.json |
For information about Snappy compression and decompression, see Decompression tools for Snappy-compressed files. Problem: If you use Snappy to compress objects and read them with Hive in an E-MapReduce (EMR) cluster, the following error may occur.
Solution: Run the |
|
If you do not specify an object suffix, the .snappy suffix is used. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.snappy |
||
|
gzip |
If you specify an object suffix, the specified suffix is used. Example: .json. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.json |
To decompress gzip-compressed objects, install gzip and run the corresponding gzip commands. |
|
If you do not specify an object suffix, the .gz suffix is used. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.gz |
||
|
Zstandard |
If you specify an object suffix, the specified suffix is used. Example: .json. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.json |
To decompress Zstandard-compressed objects, install Zstandard and run the corresponding Zstandard commands. |
|
If you do not specify an object suffix, the .zst suffix is used. |
oss://oss-shipper-chengdu/ecs_test/2022/01/26/20/54_1453812893059571256_937.zst |