PartitioningSettings.php 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. <?php
  2. # Generated by the protocol buffer compiler. DO NOT EDIT!
  3. # source: protos/ydb_topic.proto
  4. namespace Ydb\Topic;
  5. use Google\Protobuf\Internal\GPBType;
  6. use Google\Protobuf\Internal\RepeatedField;
  7. use Google\Protobuf\Internal\GPBUtil;
  8. /**
  9. * Partitioning settings for topic.
  10. *
  11. * Generated from protobuf message <code>Ydb.Topic.PartitioningSettings</code>
  12. */
  13. class PartitioningSettings extends \Google\Protobuf\Internal\Message
  14. {
  15. /**
  16. * Minimum partition count auto merge would stop working at.
  17. * Zero value means default - 1.
  18. *
  19. * Generated from protobuf field <code>int64 min_active_partitions = 1 [(.Ydb.value) = ">= 0"];</code>
  20. */
  21. protected $min_active_partitions = 0;
  22. /**
  23. * Limit for total partition count, including active (open for write) and read-only partitions.
  24. * Zero value means default - 100.
  25. *
  26. * Generated from protobuf field <code>int64 partition_count_limit = 2 [(.Ydb.value) = ">= 0"];</code>
  27. */
  28. protected $partition_count_limit = 0;
  29. /**
  30. * Constructor.
  31. *
  32. * @param array $data {
  33. * Optional. Data for populating the Message object.
  34. *
  35. * @type int|string $min_active_partitions
  36. * Minimum partition count auto merge would stop working at.
  37. * Zero value means default - 1.
  38. * @type int|string $partition_count_limit
  39. * Limit for total partition count, including active (open for write) and read-only partitions.
  40. * Zero value means default - 100.
  41. * }
  42. */
  43. public function __construct($data = NULL) {
  44. \GPBMetadata\Protos\YdbTopic::initOnce();
  45. parent::__construct($data);
  46. }
  47. /**
  48. * Minimum partition count auto merge would stop working at.
  49. * Zero value means default - 1.
  50. *
  51. * Generated from protobuf field <code>int64 min_active_partitions = 1 [(.Ydb.value) = ">= 0"];</code>
  52. * @return int|string
  53. */
  54. public function getMinActivePartitions()
  55. {
  56. return $this->min_active_partitions;
  57. }
  58. /**
  59. * Minimum partition count auto merge would stop working at.
  60. * Zero value means default - 1.
  61. *
  62. * Generated from protobuf field <code>int64 min_active_partitions = 1 [(.Ydb.value) = ">= 0"];</code>
  63. * @param int|string $var
  64. * @return $this
  65. */
  66. public function setMinActivePartitions($var)
  67. {
  68. GPBUtil::checkInt64($var);
  69. $this->min_active_partitions = $var;
  70. return $this;
  71. }
  72. /**
  73. * Limit for total partition count, including active (open for write) and read-only partitions.
  74. * Zero value means default - 100.
  75. *
  76. * Generated from protobuf field <code>int64 partition_count_limit = 2 [(.Ydb.value) = ">= 0"];</code>
  77. * @return int|string
  78. */
  79. public function getPartitionCountLimit()
  80. {
  81. return $this->partition_count_limit;
  82. }
  83. /**
  84. * Limit for total partition count, including active (open for write) and read-only partitions.
  85. * Zero value means default - 100.
  86. *
  87. * Generated from protobuf field <code>int64 partition_count_limit = 2 [(.Ydb.value) = ">= 0"];</code>
  88. * @param int|string $var
  89. * @return $this
  90. */
  91. public function setPartitionCountLimit($var)
  92. {
  93. GPBUtil::checkInt64($var);
  94. $this->partition_count_limit = $var;
  95. return $this;
  96. }
  97. }