Skip to content

Commit

Permalink
feat(sources): support no local to mqtt source config
Browse files Browse the repository at this point in the history
  • Loading branch information
ysfscream authored and Kinplemelon committed Dec 25, 2024
1 parent c36c016 commit 17c1ab1
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 3 deletions.
3 changes: 2 additions & 1 deletion src/schemaText/actionText/action-label-en.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"ssl": "Enable SSL"
},
"mqtt": {
"source_topic": "Topic"
"source_topic": "Topic",
"no_local": "No Local"
}
}
3 changes: 2 additions & 1 deletion src/schemaText/actionText/action-label-zh.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"ssl": "启用SSL"
},
"mqtt": {
"source_topic": "主题"
"source_topic": "主题",
"no_local": "禁止本地转发"
}
}
8 changes: 8 additions & 0 deletions src/types/schemas/bridges.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -334,6 +334,11 @@ export interface EmqxSslClientOpts {
server_name_indication?: EmqxSslClientOptsServerNameIndication
}

export interface ConnectorMqttStaticClientidEntry {
node: string
ids: string[]
}

export interface ConnectorMqttIngressRemote {
topic: string
qos?: number
Expand Down Expand Up @@ -445,6 +450,7 @@ export interface BridgeMqttPut {
mode?: BridgeMqttPutMode
server: string
clientid_prefix?: string
static_clientids?: ConnectorMqttStaticClientidEntry[]
/** @deprecated */
reconnect_interval?: string
proto_ver?: BridgeMqttPutProtoVer
Expand Down Expand Up @@ -498,6 +504,7 @@ export interface BridgeMqttPost {
mode?: BridgeMqttPostMode
server: string
clientid_prefix?: string
static_clientids?: ConnectorMqttStaticClientidEntry[]
/** @deprecated */
reconnect_interval?: string
proto_ver?: BridgeMqttPostProtoVer
Expand Down Expand Up @@ -554,6 +561,7 @@ export interface BridgeMqttGet {
mode?: BridgeMqttGetMode
server: string
clientid_prefix?: string
static_clientids?: ConnectorMqttStaticClientidEntry[]
/** @deprecated */
reconnect_interval?: string
proto_ver?: BridgeMqttGetProtoVer
Expand Down
2 changes: 2 additions & 0 deletions src/types/schemas/configs.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,8 @@ export interface EmqxSysmonOs {
export interface EmqxSysmon {
vm?: EmqxSysmonVm
os?: EmqxSysmonOs
mnesia_tm_mailbox_size_alarm_threshold?: number
broker_pool_mailbox_size_alarm_threshold?: number
}

export type EmqxSysTopicsSysHeartbeatInterval = string | 'disabled'
Expand Down
8 changes: 8 additions & 0 deletions src/types/schemas/connectors.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,11 @@ export interface ConnectorNodeStatus {
status_reason?: string
}

export interface ConnectorMqttStaticClientidEntry {
node: string
ids: string[]
}

export interface ConnectorMqttResourceOpts {
health_check_interval?: string
start_after_created?: boolean
Expand Down Expand Up @@ -344,6 +349,7 @@ export interface ConnectorMqttPutConnector {
mode?: ConnectorMqttPutConnectorMode
server: string
clientid_prefix?: string
static_clientids?: ConnectorMqttStaticClientidEntry[]
/** @deprecated */
reconnect_interval?: string
proto_ver?: ConnectorMqttPutConnectorProtoVer
Expand Down Expand Up @@ -398,6 +404,7 @@ export interface ConnectorMqttPostConnector {
mode?: ConnectorMqttPostConnectorMode
server: string
clientid_prefix?: string
static_clientids?: ConnectorMqttStaticClientidEntry[]
/** @deprecated */
reconnect_interval?: string
proto_ver?: ConnectorMqttPostConnectorProtoVer
Expand Down Expand Up @@ -467,6 +474,7 @@ export interface ConnectorMqttGetConnector {
mode?: ConnectorMqttGetConnectorMode
server: string
clientid_prefix?: string
static_clientids?: ConnectorMqttStaticClientidEntry[]
/** @deprecated */
reconnect_interval?: string
proto_ver?: ConnectorMqttGetConnectorProtoVer
Expand Down
2 changes: 1 addition & 1 deletion src/types/schemas/gateways.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -686,7 +686,7 @@ export type EmqxGatewayApiGatewayNodeStatusNode =

// eslint-disable-next-line @typescript-eslint/no-redeclare
export const EmqxGatewayApiGatewayNodeStatusNode = {
'emqx@1721702': 'emqx@172.17.0.2',
'emqx@127001': 'emqx@127.0.0.1',
} as const

export interface EmqxGatewayApiGatewayNodeStatus {
Expand Down
1 change: 1 addition & 0 deletions src/types/schemas/sources.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -336,6 +336,7 @@ export const BridgeMqttPublisherPostSourceType = {
} as const

export interface BridgeMqttPublisherIngressParameters {
no_local?: boolean
topic: string
qos?: number
}
Expand Down

0 comments on commit 17c1ab1

Please sign in to comment.