~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/message/transaction_writer.cc

Added code necessary for building plugins dynamically.
Merged in changes from lifeless to allow autoreconf to work.
Touching plugin.ini files now triggers a rebuid - so config/autorun.sh is no
longer required to be run after touching those.
Removed the duplicate plugin names - also removed the issue that getting them
different would silently fail weirdly later.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
 */
23
23
 
24
24
#include "drizzled/global.h"
 
25
#include "drizzled/hash/crc32.h"
 
26
#include "drizzled/gettext.h"
 
27
#include "drizzled/replication_services.h"
25
28
 
26
29
#include <sys/types.h>
27
30
#include <sys/stat.h>
224
227
  sf_meta->set_name("a");
225
228
  sf_meta->set_type(message::Table::Field::VARCHAR);
226
229
 
227
 
  header->add_set_value("5");
228
 
 
229
230
  /* Add new values... */
230
231
  message::UpdateData *data= statement->mutable_update_data();
231
232
  data->set_segment_id(1);
233
234
 
234
235
  message::UpdateRecord *record1= data->add_record();
235
236
 
 
237
  record1->add_after_value("5");
236
238
  record1->add_key_value("1");
237
239
 
238
240
  statement->set_end_timestamp(getNanoTimestamp());
263
265
  sf_meta->set_name("a");
264
266
  sf_meta->set_type(message::Table::Field::VARCHAR);
265
267
 
266
 
  header->add_set_value("5");
267
 
 
268
268
  /* Add new values... */
269
269
  message::UpdateData *data= statement->mutable_update_data();
270
270
  data->set_segment_id(1);
273
273
  message::UpdateRecord *record1= data->add_record();
274
274
  message::UpdateRecord *record2= data->add_record();
275
275
 
 
276
  record1->add_after_value("5");
276
277
  record1->add_key_value("1");
 
278
  record2->add_after_value("5");
277
279
  record2->add_key_value("2");
278
280
 
279
 
 
280
281
  statement->set_end_timestamp(getNanoTimestamp());
281
282
}
282
283
 
288
289
 
289
290
  size_t length= buffer.length();
290
291
 
291
 
  output->WriteLittleEndian64(static_cast<uint64_t>(length));
 
292
  output->WriteLittleEndian32(static_cast<uint32_t>(ReplicationServices::TRANSACTION));
 
293
  output->WriteLittleEndian32(static_cast<uint32_t>(length));
292
294
  output->WriteString(buffer);
 
295
  output->WriteLittleEndian32(drizzled::hash::crc32(buffer.c_str(), length)); /* checksum */
293
296
}
294
297
 
295
298
int main(int argc, char* argv[])