feat(ft): convert hocon files to the new format

This commit is contained in:
Ilya Averyanov 2023-04-21 19:14:24 +03:00
parent ebb75b275e
commit b951de4c6e
3 changed files with 76 additions and 289 deletions

View File

@ -1,29 +1,13 @@
emqx_ft_api { emqx_ft_api {
file_list { file_list.desc:
desc { """List all uploaded files."""
en: "List all uploaded files."
zh: "列出所有上传的文件。"
}
label: {
en: "List all uploaded files"
zh: "列出所有上传的文件"
}
}
} }
emqx_ft_storage_exporter_fs_api { emqx_ft_storage_exporter_fs_api {
file_get { file_get.desc:
desc { """Get a file by its id."""
en: "Get a file by its id."
zh: "根据文件 id 获取文件。"
}
label: {
en: "Get a file by its id"
zh: "根据文件 id 获取文件"
}
}
} }

View File

@ -1,177 +1,56 @@
emqx_ft_schema { emqx_ft_schema {
init_timeout { init_timeout.desc:
desc { """Timeout for initializing the file transfer.<br/>
en: "Timeout for initializing the file transfer.<br/>" After reaching the timeout, `init` message will be acked with an error"""
"After reaching the timeout, `init` message will be acked with an error"
zh: ""
}
label {
en: "File Transfer Init Timeout"
zh: ""
}
}
assemble_timeout { assemble_timeout.desc:
desc { """Timeout for assembling and exporting file segments into a final file.<br/>
en: "Timeout for assembling and exporting file segments into a final file.<br/>" After reaching the timeout, `fin` message will be acked with an error"""
"After reaching the timeout, `fin` message will be acked with an error"
zh: ""
}
label {
en: "File Assemble Timeout"
zh: ""
}
}
store_segment_timeout { store_segment_timeout.desc:
desc { """Timeout for storing a file segment.<br/>
en: "Timeout for storing a file segment.<br/>" After reaching the timeout, message with the segment will be acked with an error"""
"After reaching the timeout, message with the segment will be acked with an error"
zh: ""
}
label {
en: "Store Segment Timeout"
zh: ""
}
}
storage { storage.desc:
desc { """Storage settings for file transfer."""
en: "Storage settings for file transfer."
zh: "文件传输的存储设置。"
}
label: {
en: "Storage settings"
zh: "存储设置"
}
}
local_type { local_type.desc:
desc { """Use local file system to store uploaded fragments and temporary data."""
en: "Use local file system to store uploaded fragments and temporary data."
zh: "使用本地文件系统来存储上传的文件和临时数据。"
}
label: {
en: "Local Storage"
zh: "本地存储"
}
}
local_storage_segments { local_storage_segments.desc:
desc { """Settings for local segments storage, which include uploaded transfer fragments and temporary data."""
en: "Settings for local segments storage, which include uploaded transfer fragments and temporary data."
zh: "保存上传文件和临时数据的文件系统路径。"
}
label: {
en: "Local Segments Storage"
zh: "本地存储根"
}
}
local_storage_segments_root { local_storage_segments_root.desc:
desc { """File system path to keep uploaded fragments and temporary data."""
en: "File system path to keep uploaded fragments and temporary data."
zh: "保存上传文件和临时数据的文件系统路径。"
}
label: {
en: "Local Segments Storage Filesystem Root"
zh: "本地存储根"
}
}
local_storage_exporter { local_storage_exporter.desc:
desc { """Exporter for the local file system storage backend.<br/>
en: "Exporter for the local file system storage backend.<br/>" Exporter defines where and how fully transferred and assembled files are stored."""
"Exporter defines where and how fully transferred and assembled files are stored."
zh: ""
}
label: {
en: "Local Storage Exporter"
zh: ""
}
}
local_storage_exporter_type { local_storage_exporter_type.desc:
desc { """Exporter type for the exporter to the local file system"""
en: "Exporter type for the exporter to the local file system"
zh: ""
}
label: {
en: "Local Storage Exporter Type"
zh: ""
}
}
s3_exporter_type { s3_exporter_type.desc:
desc { """Exporter type for the exporter to S3"""
en: "Exporter type for the exporter to S3"
zh: ""
}
label: {
en: "S3 Exporter Type"
zh: ""
}
}
local_storage_exporter_root { local_storage_exporter_root.desc:
desc { """File system path to keep uploaded files."""
en: "File system path to keep uploaded files."
zh: ""
}
label: {
en: "Local Filesystem Exporter Root"
zh: ""
}
}
local_storage_segments_gc { local_storage_segments_gc.desc:
desc { """Garbage collection settings for the intermediate and temporary files in the local file system."""
en: "Garbage collection settings for the intermediate and temporary files in the local file system."
zh: ""
}
label: {
en: "Local Storage GC"
zh: ""
}
}
storage_gc_interval { storage_gc_interval.desc:
desc { """Interval of periodic garbage collection."""
en: "Interval of periodic garbage collection."
zh: ""
}
label: {
en: "GC Interval"
zh: ""
}
}
storage_gc_max_segments_ttl { storage_gc_max_segments_ttl.desc:
desc { """Maximum TTL of a segment kept in the local file system.<br/>
en: "Maximum TTL of a segment kept in the local file system.<br/>" This is a hard limit: no segment will outlive this TTL, even if some file transfer specifies a
"This is a hard limit: no segment will outlive this TTL, even if some file transfer specifies a " TTL more than that."""
"TTL more than that."
zh: ""
}
label: {
en: "Max segment TTL"
zh: ""
}
}
storage_gc_min_segments_ttl {
desc {
en: "Minimum TTL of a segment kept in the local file system.<br/>"
"This is a hard limit: no segment will be garbage collected before reaching this TTL, "
"even if some file transfer specifies a TTL less than that."
zh: ""
}
label: {
en: "Min segment TTL"
zh: ""
}
}
storage_gc_min_segments_ttl.desc:
"""Minimum TTL of a segment kept in the local file system.<br/>
This is a hard limit: no segment will be garbage collected before reaching this TTL,
even if some file transfer specifies a TTL less than that."""
} }

View File

@ -1,114 +1,38 @@
emqx_s3_schema { emqx_s3_schema {
access_key_id {
desc { access_key_id.desc:
en: "The access key ID of the S3 bucket." """The access key ID of the S3 bucket."""
zh: ""
} secret_access_key.desc:
label { """The secret access key of the S3 bucket."""
en: "Access Key ID"
zh: "" bucket.desc:
} """The name of the S3 bucket."""
}
secret_access_key { host.desc:
desc { """The host of the S3 endpoint."""
en: "The secret access key of the S3 bucket."
zh: "" port.desc:
} """The port of the S3 endpoint."""
label {
en: "Secret Access Key" url_expire_time.desc:
zh: "" """The time in seconds for which the signed URLs to the S3 objects are valid."""
}
} min_part_size.desc:
bucket { """The minimum part size for multipart uploads.<br/>
desc {
en: "The name of the S3 bucket."
zh: ""
}
label {
en: "Bucket"
zh: ""
}
}
host {
desc {
en: "The host of the S3 endpoint."
zh: ""
}
label {
en: "S3 endpoint Host"
zh: ""
}
}
port {
desc {
en: "The port of the S3 endpoint."
zh: ""
}
label {
en: "S3 endpoint port"
zh: ""
}
}
url_expire_time {
desc {
en: "The time in seconds for which the signed URLs to the S3 objects are valid."
zh: ""
}
label {
en: "Signed URL expiration time"
zh: ""
}
}
min_part_size {
desc {
en: """The minimum part size for multipart uploads.<br/>
Uploaded data will be accumulated in memory until this size is reached.""" Uploaded data will be accumulated in memory until this size is reached."""
zh: ""
} max_part_size.desc:
label { """The maximum part size for multipart uploads.<br/>
en: "Minimum multipart upload part size"
zh: ""
}
}
max_part_size {
desc {
en: """The maximum part size for multipart uploads.<br/>
S3 uploader won't try to upload parts larger than this size.""" S3 uploader won't try to upload parts larger than this size."""
zh: ""
} acl.desc:
label { """The ACL to use for the uploaded objects."""
en: "Maximum multipart upload part size"
zh: "" transport_options.desc:
} """Options for the HTTP transport layer used by the S3 client."""
}
acl { ipv6_probe.desc:
desc { """Whether to probe for IPv6 support."""
en: "The ACL to use for the uploaded objects."
zh: ""
}
label {
en: "ACL"
zh: ""
}
}
transport_options {
desc {
en: "Options for the HTTP transport layer used by the S3 client."
zh: ""
}
label {
en: "Transport Options"
zh: ""
}
}
ipv6_probe {
desc {
en: "Whether to probe for IPv6 support."
zh: ""
}
label {
en: "IPv6 probe"
zh: ""
}
}
} }