~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to plugin/archive/concurrency_test.cc

  • Committer: Lee Bieber
  • Date: 2010-11-07 19:34:48 UTC
  • mfrom: (1910.1.2 build)
  • Revision ID: kalebral@gmail.com-20101107193448-64kdu912qej354sh
Merge Stewart - including adapting and expanding the "differences from mysql" page from the wiki.
Merge Stewart - fix bug 668143: drizzleslap with --commit runs second iteration data load in a transaction

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* -*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil; -*-
2
2
 *  vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
3
3
 *
4
 
 *  Copyright (C) 2009 Sun Microsystems, Inc.
 
4
 *  Copyright (C) 2009 Sun Microsystems
5
5
 *
6
6
 *  This program is free software; you can redistribute it and/or modify
7
7
 *  it under the terms of the GNU General Public License as published by
37
37
#ifndef __WIN__
38
38
#include <sys/wait.h>
39
39
#endif
40
 
#include <memory>
41
40
 
42
41
#ifdef __WIN__
43
42
#define srandom  srand
45
44
#define snprintf _snprintf
46
45
#endif
47
46
 
48
 
#include <boost/scoped_ptr.hpp>
49
 
 
50
47
#include "azio.h"
51
48
 
52
49
#define DEFAULT_INITIAL_LOAD 10000
139
136
{
140
137
  unsigned int x;
141
138
  uint64_t total;
142
 
  boost::scoped_ptr<azio_stream> writer_handle_ap(new azio_stream);
143
 
  azio_stream &writer_handle= *writer_handle_ap.get();
 
139
  azio_stream writer_handle;
144
140
  thread_context_st *context;
145
141
  pthread_t mainthread;            /* Thread descriptor */
146
142
  pthread_attr_t attr;          /* Thread attributes */
267
263
  uint64_t count;
268
264
  int ret;
269
265
  int error;
270
 
  boost::scoped_ptr<azio_stream> reader_handle_ap(new azio_stream);
271
 
  azio_stream &reader_handle= *reader_handle_ap.get();
 
266
  azio_stream reader_handle;
272
267
 
273
268
  if (!(ret= azopen(&reader_handle, TEST_FILENAME, O_RDONLY,
274
269
                    context->use_aio)))