Returns a SpillConfig with every serializable field set to a non-default value, making it easy to detect fields that were silently dropped.
| 168 | // Returns a SpillConfig with every serializable field set to a non-default |
| 169 | // value, making it easy to detect fields that were silently dropped. |
| 170 | SpillConfig makeFullConfig() { |
| 171 | SpillConfig cfg; |
| 172 | cfg.fileNamePrefix = "test_spill"; |
| 173 | cfg.maxFileSize = 512UL * 1024 * 1024; |
| 174 | cfg.spillUringEnabled = true; |
| 175 | cfg.writeBufferSize = 8UL * 1024 * 1024; |
| 176 | cfg.minSpillableReservationPct = 10; |
| 177 | cfg.spillableReservationGrowthPct = 25; |
| 178 | cfg.startPartitionBit = 29; |
| 179 | cfg.joinPartitionBits = 4; |
| 180 | cfg.joinRepartitionBits = 2; |
| 181 | cfg.maxSpillLevel = 3; |
| 182 | cfg.maxSpillRunRows = 100'000; |
| 183 | cfg.writerFlushThresholdSize = 64UL * 1024 * 1024; |
| 184 | cfg.testSpillPct = 5; |
| 185 | cfg.compressionKind = CompressionKind_ZSTD; |
| 186 | cfg.fileCreateConfig = R"({"option":"value"})"; |
| 187 | cfg.rowBasedSpillMode = RowBasedSpillMode::RAW; |
| 188 | cfg.singlePartitionSerdeKind = "Arrow"; |
| 189 | cfg.spillPartitionsAdaptiveThreshold = 64; |
| 190 | cfg.jitEnabled = false; |
| 191 | cfg.needSetNextEqual = true; |
| 192 | cfg.aggBypassHTEqualNum = 42; |
| 193 | return cfg; |
| 194 | } |
| 195 | |
| 196 | void assertFieldsEqual(const SpillConfig& e, const SpillConfig& a) { |
| 197 | EXPECT_EQ(e.fileNamePrefix, a.fileNamePrefix); |