Command-line Tools

    The current command line tool supports three commands of , describe , and create.

    Go to the inlong-manager directory , modify the following configurations of the conf/application.properties file.

    1. server.host=127.0.0.1
    2. server.port=8080
    3. default.admin.user=admin
    4. default.admin.password=inlong
    1. Usage: managerctl list [command] [command options]
    2. Commands:
    3. stream Get stream main information
    4. Usage: stream [options]
    5. Options:
    6. * -g, --group
    7. inlong group id
    8. group Get group details
    9. Usage: group [options]
    10. Options:
    11. -g, --group
    12. inlong group id
    13. -n, --num
    14. the number displayed
    15. Default: 10
    16. -s, --status
    17. ( CREATE | REJECTED | INITIALIZING | OPERATING |
    18. STARTED | FAILED | STOPPED | FINISHED | DELETED )
    19. sink Get sink details
    20. Usage: sink [options]
    21. Options:
    22. * -g, --group
    23. group id
    24. * -s, --stream
    25. stream id
    26. source Get source details
    27. Usage: source [options]
    28. Options:
    29. * -g, --group
    30. inlong group id
    31. * -s, --stream
    32. inlong stream id
    33. -t, --type
    34. sink type
    1. Usage: managerctl describe [command] [command options]
    2. Commands:
    3. stream Get stream details
    4. Usage: stream [options]
    5. Options:
    6. * -g, --group
    7. inlong group id
    8. group Get group details
    9. Usage: group [options]
    10. Options:
    11. -g, --group
    12. inlong group id
    13. -n, --num
    14. the number displayed
    15. Default: 10
    16. -s, --status
    17. Default: 0
    18. sink Get sink details
    19. Usage: sink [options]
    20. Options:
    21. * -g, --group
    22. * -s, --stream
    23. inlong stream id
    24. source Get source details
    25. Usage: source [options]
    26. Options:
    27. * -g, --group
    28. inlong group id
    29. * -s, --stream
    30. inlong stream id
    31. * -t, --type
    32. sink type

    The describe command is used to show the details of the Inlong Group / Stream / Sink / Source and output in JSON format.

    The create command does not need to submit for review , just prepare the configured information in the JSON file.

    Json files have five parts: groupConfstreamConfstreamSourcestreamSink and streamFieldList

    1. {
    2. "groupConf": {
    3. "groupName": "test_group",
    4. "description": "",
    5. "proxyClusterId": "1",
    6. "mqBaseConf": {
    7. "type": "PULSAR",
    8. "pulsarServiceUrl": "pulsar://127.0.0.1:6650",
    9. "pulsarAdminUrl": "http://127.0.0.1:8080",
    10. "tenant": "tenant",
    11. "namespace": "namespace",
    12. "enableCreateResource": false
    13. },
    14. "sortBaseConf": {
    15. "type": "FLINK",
    16. "serviceUrl": "127.0.0.1:8081"
    17. },
    18. "zookeeperEnabled": false,
    19. "dailyRecords": 10000000,
    20. "peakRecords": 100000,
    21. "maxLength": 10000
    22. },
    23. "streamConf": {
    24. "name": "test_stream",
    25. "description": "",
    26. "dataSeparator": "|",
    27. "strictlyOrdered": true,
    28. "topic": "topic"
    29. },
    30. "streamSource": {
    31. "sourceType": "KAFKA",
    32. "bootstrapServers": "127.0.0.1:9092",
    33. "topic": "kafka_topic",
    34. "sourceName": "kafka_sourceName",
    35. "dataFormat": "json",
    36. "autoOffsetReset": "EARLIEST"
    37. },
    38. "streamSink": {
    39. "sinkType": "HIVE",
    40. "dbName": "test_db",
    41. "jdbcUrl": "jdbc:hive2://127.0.0.1:10000",
    42. "authentication": {
    43. "userName": "hive",
    44. "password": "hive"
    45. },
    46. "fileFormat": "TextFile",
    47. "dataSeparator": "|",
    48. "dataPath": "hdfs://127.0.0.1:9000/user/hive/warehouse/test_db",
    49. "sinkFields": [
    50. {
    51. "id": 0,
    52. "fieldType": "STRING",
    53. "fieldName": "name",
    54. "sourceFieldType": "STRING",
    55. "sourceFieldName": "name"
    56. }
    57. "tableName": "test_table",
    58. "sinkName": "test",
    59. "dataFormat": "json"
    60. "streamFieldList": [
    61. {
    62. "id": 0,
    63. "fieldType": "STRING",
    64. "fieldName": "name",
    65. "fieldComment": null,
    66. "fieldValue": null
    67. }
    68. ]
    69. }

    streamSource

      1. "streamSource": {
      2. "sourceType": "KAFKA",
      3. "sourceName": "sourceName",
      4. "bootstrapServers": "127.0.0.1:9092",
      5. "topic": "kafka_topic",
      6. "dataFormat": "json",
      7. "autoOffsetReset": "EARLIEST"
      8. },
    • MySQL Binlog

    • File

    streamSink

    • Hive

      1. "mqBaseConf": {
      2. "type": "KAFKA",
      3. "bootstrapServers": "pulsar://100.76.43.216:6650",
      4. "topicName": "http://100.76.43.216:8080",
      5. "dataFormat": "JSON",
      6. "boolean": false,
      7. }
    • ClickHouse