client_cmd_request.go 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. package client
  2. type AutoMigrateRequest struct {
  3. Items []AutoMigrateItem
  4. }
  5. type AutoMigrateItem struct {
  6. TablePrefixWithSchema string
  7. Version string
  8. TableModelDescribe map[string]string
  9. }
  10. type InsertRequest struct {
  11. TablePrefixWithSchema string
  12. Version string
  13. KeyColumns []string
  14. TableRow map[string]any
  15. UserID string
  16. }
  17. type InsertBatchRequest struct {
  18. Items []InsertTableRowItem
  19. UserID string
  20. }
  21. type InsertTableRowItem struct {
  22. TablePrefixWithSchema string
  23. Version string
  24. KeyColumns []string
  25. TableRows []map[string]any
  26. }
  27. type DeleteRequest struct {
  28. TablePrefixWithSchema string
  29. Version string
  30. KeyValues map[string]string
  31. UserID string
  32. }
  33. type DeleteBatchRequest struct {
  34. Items []DeleteTableRowItem
  35. UserID string
  36. }
  37. type DeleteTableRowItem struct {
  38. TablePrefixWithSchema string
  39. Version string
  40. KeyValues []map[string]string
  41. }
  42. type UpdateRequest struct {
  43. TablePrefixWithSchema string
  44. Version string
  45. KeyValues map[string]string
  46. NewTableRow map[string]any
  47. UserID string
  48. }
  49. type ReplayRequest struct {
  50. TablePrefixWithSchema string
  51. Version string
  52. KeyValues map[string]string
  53. UserID string
  54. }