~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/slave/replication_schema.h

  • Committer: Monty Taylor
  • Date: 2011-02-13 17:26:39 UTC
  • mfrom: (2157.2.2 give-in-to-pkg-config)
  • mto: This revision was merged to the branch mainline in revision 2166.
  • Revision ID: mordred@inaugust.com-20110213172639-nhy7i72sfhoq13ms
Merged in pkg-config fixes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* - mode: c; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
 
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
3
 
 *
4
 
 *  Copyright (C) 2011 David Shrewsbury
5
 
 *
6
 
 *  This program is free software; you can redistribute it and/or modify
7
 
 *  it under the terms of the GNU General Public License as published by
8
 
 *  the Free Software Foundation; either version 2 of the License, or
9
 
 *  (at your option) any later version.
10
 
 *
11
 
 *  This program is distributed in the hope that it will be useful,
12
 
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 
 *  GNU General Public License for more details.
15
 
 *
16
 
 *  You should have received a copy of the GNU General Public License
17
 
 *  along with this program; if not, write to the Free Software
18
 
 *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
19
 
 */
20
 
 
21
 
#pragma once
22
 
 
23
 
#include <plugin/slave/sql_executor.h>
24
 
 
25
 
namespace slave
26
 
{
27
 
 
28
 
class ReplicationSchema : public SQLExecutor
29
 
{
30
 
public:
31
 
  ReplicationSchema() : SQLExecutor("slave", "replication")
32
 
  { }
33
 
 
34
 
  bool create();
35
 
 
36
 
  /**
37
 
   * Set initial value of the last applied COMMIT_ID value in applier_state.
38
 
   *
39
 
   * This is used when the server is started with --slave.max-commit-id to
40
 
   * begin reading from the master transaction log at a given point. This
41
 
   * method will persist the value to the applier_state table. If it wasn't
42
 
   * permanently stored immediately, we risk the possibility of losing the
43
 
   * value if the server is again restarted without ever having received
44
 
   * another event from the master (which causes persistence of the value).
45
 
   * An edge case, but still possible.
46
 
   *
47
 
   * @param[in] value The initial value.
48
 
   */
49
 
  bool setInitialMaxCommitId(uint64_t value);
50
 
};
51
 
 
52
 
} /* namespace slave */
53