~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/transaction_log/docs/index.rst

  • Committer: Brian Aker
  • Date: 2010-12-08 22:35:56 UTC
  • mfrom: (1819.9.158 update-innobase)
  • Revision ID: brian@tangent.org-20101208223556-37mi4omqg7lkjzf3
Merge in Stewart's changes, 1.3 changes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Transaction Log
 
2
===============
 
3
 
 
4
Description
 
5
-----------
 
6
 
 
7
The Drizzle Transaction Log contains a sequence of
 
8
`Google Protocol Buffer <http://code.google.com/p/protobuf/>`_
 
9
messages that describe the transactions which have been run.
 
10
 
 
11
 
 
12
Configuration
 
13
-------------
 
14
 
 
15
Several server variables control the transaction log.
 
16
 
 
17
**transaction-log.enable**
 
18
 
 
19
   Enable transaction log.
 
20
 
 
21
**transaction-log.enable-checksum**
 
22
 
 
23
   Enable CRC32 Checksumming of each written transaction log entry
 
24
 
 
25
**transaction-log.file**
 
26
 
 
27
  Path to the file to use for transaction log. The default will be
 
28
  :file:`transaction.log`.
 
29
 
 
30
**transaction-log.use-replicator**
 
31
 
 
32
   Name of the replicator plugin to use (default='default_replicator')
 
33
 
 
34
**transaction-log.flush-frequency**
 
35
 
 
36
   * 0 : rely on operating system to sync log file (default)
 
37
   * 1 : sync file at each transaction write
 
38
   * 2 : sync log file once per second
 
39
 
 
40
**transaction-log.num-write-buffers**
 
41
 
 
42
   Number of slots for in-memory write buffers (default=8).
 
43
 
 
44
 
 
45
Transaction Log Messages
 
46
------------------------
 
47
 
 
48
Replication events are recorded using messages in the `Google Protocol Buffer
 
49
<http://code.google.com/p/protobuf/>`_ (GPB) format. See the :doc:`Replication
 
50
documentation </replication>` for more information.
 
51
 
 
52
 
 
53
Transaction Log Format
 
54
----------------------
 
55
 
 
56
Currently, the transaction log file uses a simple, single-file, append-only
 
57
format. The format of each entry in the transaction log file is::
 
58
 
 
59
      4-bytes        4-bytes
 
60
  +--------------+--------------+----------------------+
 
61
  |  Entry Type  |    Length    |  Serialized Message  |
 
62
  +--------------+--------------+----------------------+
 
63
 
 
64
The fields in the entry are:
 
65
 
 
66
* **Entry Type** - Type of message this entry contains. Currently,
 
67
  this is always a Transaction GPB message.
 
68
* **Length** - The length, in bytes, of the serialized message.
 
69
* **Serialized Message** - The actual message data.