config2.json 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. {
  2. "job": {
  3. "setting": {
  4. "speed": {
  5. "channel": 3
  6. },
  7. "errorLimit": {
  8. "record": 0,
  9. "percentage": 0.02
  10. }
  11. },
  12. "content": [
  13. {
  14. "reader": {
  15. "name": "mysqlreader",
  16. "parameter": {
  17. "username": "root",
  18. "password": "happylay",
  19. "splitPk": "",
  20. "connection": [
  21. {
  22. "querySql": [
  23. "select id, txn_amount, txn_type from test_4 where txn_date >= FROM_UNIXTIME(${lastTime}) and txn_date < FROM_UNIXTIME(${currentTime})"
  24. ],
  25. "jdbcUrl": [
  26. "jdbc:mysql://192.168.199.107:10086/test-db?useSSL=false"
  27. ]
  28. }
  29. ]
  30. }
  31. },
  32. "writer": {
  33. "name": "hdfswriter",
  34. "parameter": {
  35. "defaultFS": "hdfs://192.168.199.27:9000",
  36. "fileType": "text",
  37. "path": "/home/sxkj/bigdata/apache-hive-2.3.9-bin/warehouse/test_h4/${partition}",
  38. "fileName": "000000",
  39. "writeMode": "append",
  40. "fieldDelimiter": ",",
  41. "column": [
  42. {
  43. "name": "id",
  44. "type": "int"
  45. },
  46. {
  47. "name": "txn_amount",
  48. "type": "double"
  49. },
  50. {
  51. "name": "txn_type",
  52. "type": "string"
  53. }
  54. ]
  55. }
  56. }
  57. }
  58. ]
  59. }
  60. }