summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorSanjay Ghemawat <sanjay@google.com>2012-10-16 16:17:53 -0700
committerSanjay Ghemawat <sanjay@google.com>2012-10-16 16:17:53 -0700
commit40768657bc8ec3ded60712eeeab7c25b1b07deca (patch)
treeafb7f5df7d0c66b0e3c27b359eb0f41621ad66b0 /doc
parent946e5b5a4ce7980917b22a408f090a4e86c3fa44 (diff)
downloadleveldb-40768657bc8ec3ded60712eeeab7c25b1b07deca.tar.gz
Small fixes.v1.7
Details: * Fix shared library building. * Reorganize linking commands so flags like --as-needed can be passed. * C binding exports version numbers. * Fix small typos in documention.
Diffstat (limited to 'doc')
-rw-r--r--doc/index.html6
-rw-r--r--doc/log_format.txt4
-rw-r--r--doc/table_format.txt12
3 files changed, 12 insertions, 10 deletions
diff --git a/doc/index.html b/doc/index.html
index cd29341..3ed0ed9 100644
--- a/doc/index.html
+++ b/doc/index.html
@@ -420,7 +420,7 @@ The preceding code associates a
based filtering policy with the database. Bloom filter based
filtering relies on keeping some number of bits of data in memory per
key (in this case 10 bits per key since that is the argument we passed
-to NewBloomFilter). This filter will reduce the number of unnecessary
+to NewBloomFilterPolicy). This filter will reduce the number of unnecessary
disk reads needed for <code>Get()</code> calls by a factor of
approximately a 100. Increasing the bits per key will lead to a
larger reduction at the cost of more memory usage. We recommend that
@@ -430,7 +430,7 @@ lot of random reads set a filter policy.
If you are using a custom comparator, you should ensure that the filter
policy you are using is compatible with your comparator. For example,
consider a comparator that ignores trailing spaces when comparing keys.
-<code>NewBloomFilter</code> must not be used with such a comparator.
+<code>NewBloomFilterPolicy</code> must not be used with such a comparator.
Instead, the application should provide a custom filter policy that
also ignores trailing spaces. For example:
<pre>
@@ -438,7 +438,7 @@ also ignores trailing spaces. For example:
private:
FilterPolicy* builtin_policy_;
public:
- CustomFilterPolicy() : builtin_policy_(NewBloomFilter(10)) { }
+ CustomFilterPolicy() : builtin_policy_(NewBloomFilterPolicy(10)) { }
~CustomFilterPolicy() { delete builtin_policy_; }
const char* Name() const { return "IgnoreTrailingSpacesFilter"; }
diff --git a/doc/log_format.txt b/doc/log_format.txt
index 3a0414b..5228f62 100644
--- a/doc/log_format.txt
+++ b/doc/log_format.txt
@@ -4,8 +4,8 @@ exception is that the tail of the file may contain a partial block.
Each block consists of a sequence of records:
block := record* trailer?
record :=
- checksum: uint32 // crc32c of type and data[]
- length: uint16
+ checksum: uint32 // crc32c of type and data[] ; little-endian
+ length: uint16 // little-endian
type: uint8 // One of FULL, FIRST, MIDDLE, LAST
data: uint8[length]
diff --git a/doc/table_format.txt b/doc/table_format.txt
index d0f3065..ca8f9b4 100644
--- a/doc/table_format.txt
+++ b/doc/table_format.txt
@@ -18,6 +18,8 @@ The file contains internal pointers. Each such pointer is called
a BlockHandle and contains the following information:
offset: varint64
size: varint64
+See https://developers.google.com/protocol-buffers/docs/encoding#varints
+for an explanation of varint64 format.
(1) The sequence of key/value pairs in the file are stored in sorted
order and partitioned into a sequence of data blocks. These blocks
@@ -41,11 +43,11 @@ BlockHandle for the data block.
(6) At the very end of the file is a fixed length footer that contains
the BlockHandle of the metaindex and index blocks as well as a magic number.
- metaindex_handle: char[p]; // Block handle for metaindex
- index_handle: char[q]; // Block handle for index
- padding: char[40-p-q]; // 0 bytes to make fixed length
- // (40==2*BlockHandle::kMaxEncodedLength)
- magic: fixed64; // == 0xdb4775248b80fb57
+ metaindex_handle: char[p]; // Block handle for metaindex
+ index_handle: char[q]; // Block handle for index
+ padding: char[40-p-q]; // zeroed bytes to make fixed length
+ // (40==2*BlockHandle::kMaxEncodedLength)
+ magic: fixed64; // == 0xdb4775248b80fb57 (little-endian)
"filter" Meta Block
-------------------