buyer2.txt 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. curl -H 'Content-Type: application/json' -u jybid:Top2023_JEB01i@31 -XPUT http://127.0.0.1:19908/buyer_v1 -d '{
  2. "settings": {
  3. "index": {
  4. "analysis": {
  5. "analyzer": {
  6. "my_ngram": {
  7. "tokenizer": "my_ngram"
  8. }
  9. },
  10. "tokenizer": {
  11. "my_ngram": {
  12. "min_gram": "2",
  13. "type": "nGram",
  14. "max_gram": "2"
  15. }
  16. }
  17. },
  18. "number_of_shards": "9",
  19. "number_of_replicas": "0"
  20. }
  21. },
  22. "mappings": {
  23. "dynamic":false,
  24. "properties": {
  25. "name": {
  26. "analyzer": "my_ngram",
  27. "type": "text"
  28. },
  29. "buyer_name": {
  30. "type": "keyword"
  31. },
  32. "buyerclass": {
  33. "type": "keyword"
  34. },
  35. "id": {
  36. "type": "keyword"
  37. },
  38. "is_contact":{
  39. "type": "boolean"
  40. },
  41. "createtime":{
  42. "type": "long"
  43. },
  44. "updatetime":{
  45. "type": "long"
  46. },
  47. "province": {
  48. "type": "keyword"
  49. },
  50. "seo_id": {
  51. "type": "long"
  52. },
  53. "city": {
  54. "type": "keyword"
  55. }
  56. }
  57. }
  58. }'