Skip to content

Commit a2b2f7e

Browse files
committed
Stardog Patches: WriteBatch + WriteBufferManager
1 parent fbed72f commit a2b2f7e

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

include/rocksdb/write_batch.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,10 @@ class WriteBatch : public WriteBatchBase {
173173
// Otherwise returns Status::OK().
174174
Status PopSavePoint() override;
175175

176+
void setContentFlag(uint32_t theContentFlag) {
177+
content_flags_.store(theContentFlag,std::memory_order_seq_cst);
178+
}
179+
176180
// Support for iterating over the contents of a batch.
177181
class Handler {
178182
public:

include/rocksdb/write_buffer_manager.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,12 @@ class WriteBufferManager {
8787
}
8888
}
8989

90+
void SetBufferSize(size_t new_size) {
91+
buffer_size_ = new_size;
92+
}
93+
9094
private:
91-
const size_t buffer_size_;
95+
std::atomic<size_t> buffer_size_;
9296
const size_t mutable_limit_;
9397
std::atomic<size_t> memory_used_;
9498
// Memory that hasn't been scheduled to free.

0 commit comments

Comments
 (0)