Index: third_party/leveldatabase/env_chromium.h |
diff --git a/third_party/leveldatabase/env_chromium.h b/third_party/leveldatabase/env_chromium.h |
index 51f28666c34479125e9f150877a2dac6b23ed983..6cc5d45ee330bf05878b975e0994177fb87f4b88 100644 |
--- a/third_party/leveldatabase/env_chromium.h |
+++ b/third_party/leveldatabase/env_chromium.h |
@@ -97,6 +97,15 @@ int GetNumCorruptionCodes(); |
std::string GetCorruptionMessage(const leveldb::Status& status); |
bool IndicatesDiskFull(const leveldb::Status& status); |
+// Determine the appropriate leveldb write buffer size to use. The default size |
+// (4MB) may result in a log file too large to be compacted given the available |
+// storage space. This function will return smaller values for smaller disks, |
+// and the default leveldb value for larger disks. |
+// |
+// |path| is the path to any file or directory on the partition on which the |
+// leveldb will be created/opened. |
+size_t WriteBufferSize(const base::FilePath& path); |
+ |
class UMALogger { |
public: |
virtual void RecordErrorAt(MethodID method) const = 0; |