1110class.mql 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218
  1. /**
  2. scope(file)
  3. timeout(3m)
  4. **/
  5. ;
  6. create class if not exists /test() with namespace="test"
  7. ;
  8. create class if not exists /test/bucketpromdb (
  9. host varchar,
  10. prom bucket {
  11. "type" : "promdb",
  12. "ttl" : 2,
  13. "dict" : true,
  14. "version": 1,
  15. "slot" : 5
  16. } 'prom',
  17. pprom bucket {
  18. "type" : "promdb",
  19. "ttl" : 2,
  20. "dict" : true,
  21. "version": 1,
  22. "slot" : 5
  23. } 'pprom',
  24. keys(host),
  25. indexes(host)
  26. ) with key=manu, nickname='bucketpromdb'
  27. ;
  28. create class if not exists /test/bucketpromdbmp (
  29. host varchar,
  30. ip varchar,
  31. prommp bucket {
  32. "type" : "promdb",
  33. "ttl" : 2,
  34. "dict" : true,
  35. "version": 1,
  36. "slot" : 5,
  37. "pattern": "{\"partition\":[15]}"
  38. } 'prommp',
  39. keys(host),
  40. indexes(host)
  41. ) with key=manu, nickname='bucketpromdbmp', partition=(ip)
  42. ;
  43. create class if not exists /test/bucketpromdbdelay (
  44. host varchar,
  45. promdelay bucket {
  46. "type" : "promdb",
  47. "ttl" : 2,
  48. "slot" : 5,
  49. "collect": 10
  50. } 'delay',
  51. keys(host),
  52. indexes(host)
  53. ) with key=manu, nickname='bucketpromdbdelay'
  54. ;
  55. create class if not exists /test/bucketpromdbsync (
  56. host varchar,
  57. prom_sync bucket {
  58. "type" : "promdb",
  59. "syncdc": true,
  60. "ttl" : 2,
  61. "slot" : 5
  62. } 'full',
  63. keys(host),
  64. indexes(host)
  65. ) with key=manu, nickname='bucketpromdbsync'
  66. ;
  67. create class if not exists /test/bucketsplit (
  68. host varchar,
  69. prom_split bucket {
  70. "type" : "promdb",
  71. "ttl" : 2,
  72. "slot" : 5
  73. } 'full',
  74. keys(host),
  75. indexes(host)
  76. ) with key=manu, nickname='bucketsplit'
  77. ;
  78. create class if not exists /test/promdb_string (
  79. host varchar,
  80. prom_str bucket {
  81. "type" : "promdb",
  82. "ttl" : 2,
  83. "slot" : 5
  84. } 'full',
  85. keys(host),
  86. indexes(host)
  87. ) with key=manu, nickname='promdb_string'
  88. ;
  89. create class if not exists /test/promdb_string2 (
  90. host varchar,
  91. prom_str2 bucket {
  92. "cache" : false,
  93. "type" : "promdb",
  94. "ttl" : 2,
  95. "slot" : 5
  96. } 'full',
  97. keys(host),
  98. indexes(host)
  99. ) with key=manu, nickname='promdb_string2'
  100. ;
  101. create class if not exists /test/bucketpromdb2 (
  102. host varchar,
  103. prom2 bucket {
  104. "type" : "promdb",
  105. "single": true,
  106. "ttl" : 2,
  107. "slot" : 5
  108. } 'full',
  109. keys(host),
  110. indexes(host)
  111. ) with key=manu, nickname='bucketpromdb2'
  112. ;
  113. create class if not exists /test/bucketpromdb3 (
  114. host varchar,
  115. prom3 bucket {
  116. "type" : "promdb",
  117. "single": true,
  118. "share" : true,
  119. "ttl" : 2,
  120. "slot" : 5
  121. } 'full',
  122. keys(host),
  123. indexes(host)
  124. ) with key=manu, nickname='bucketpromdb3'
  125. ;
  126. create class if not exists /test/bucketpromdb4 (
  127. host varchar,
  128. prom4 bucket {
  129. "type" : "promdb",
  130. "share" : true,
  131. "ttl" : 2,
  132. "slot" : 5
  133. } 'full',
  134. keys(host),
  135. indexes(host)
  136. ) with key=manu, nickname='bucketpromdb4'
  137. ;
  138. create class if not exists /test/bucketpromdbnocache (
  139. host varchar,
  140. prom_nocache bucket {
  141. "type" : "promdb",
  142. "cache" : false,
  143. "ttl" : 1,
  144. "slot" : 5
  145. } 'full',
  146. keys(host),
  147. indexes(host)
  148. ) with key=manu, nickname='bucketpromdbnocache'
  149. ;
  150. create class if not exists /test/bucketpromdb/subpromdb () with nickname ='subpromdb' ;
  151. create class if not exists /test/bucketpromdb/subpromdb2 () with nickname ='subpromdb2' ;
  152. create class if not exists /test/bucketpromdb2/subpromdbs() with nickname ='subpromdbs' ;
  153. create class if not exists /test/bucketpromdb2/subpromdbss() with nickname ='subpromdbss' ;
  154. create class if not exists /test/bucketpromdb2/subpromdbsss() with nickname ='subpromdbsss' ;