You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
642 B

9 months ago
  1. syntax = "proto3";
  2. package schema_pb;
  3. option go_package = "github.com/seaweedfs/seaweedfs/weed/pb/schema_pb";
  4. message RecordType {
  5. repeated Field fields = 2;
  6. }
  7. message Field {
  8. string name = 1;
  9. Type type = 2;
  10. int32 index = 3;
  11. bool is_optional = 4;
  12. bool is_repeated = 5;
  13. }
  14. message Type {
  15. oneof kind {
  16. ScalarType scalar_type = 1;
  17. RecordType record_type = 2;
  18. MapType map_type = 3;
  19. }
  20. }
  21. enum ScalarType {
  22. BOOLEAN = 0;
  23. INTEGER = 1;
  24. LONG = 3;
  25. FLOAT = 4;
  26. DOUBLE = 5;
  27. BYTES = 6;
  28. STRING = 7;
  29. }
  30. message MapType {
  31. // key is always string
  32. Type value = 1;
  33. }