logdump now understands newbrtnode. Addresses #11

git-svn-id: file:///svn/tokudb@706 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
Bradley C. Kuszmaul 2007-11-21 21:41:57 +00:00
parent aab4d54f85
commit 40912f3b88
3 changed files with 21 additions and 4 deletions

View file

@ -46,6 +46,7 @@ BINS = $(REGRESSION_TESTS) \
# This line intentially kept commented so I can have a \ on the end of the previous line
logdump: LDFLAGS+=-lz
logdump: log-internal.h brttypes.h yerror.h log.h kv-pair.h
libs: log.o
bins: $(BINS)

View file

@ -1,8 +1,8 @@
#include "yerror.h"
#include <stdio.h>
#include "log.h"
#include <sys/types.h>
#include "yerror.h"
#include "log.h"
#define LOGGER_BUF_SIZE (1<<24)
struct tokulogger {

View file

@ -1,13 +1,14 @@
/* Dump the log from stdin to stdout. */
#include <stdio.h>
#include "brttypes.h"
#include "log-internal.h"
#include <sys/types.h>
#include <ctype.h>
#include <stdlib.h>
#include <zlib.h>
#include <assert.h>
#include "brttypes.h"
#include "log-internal.h"
u_int32_t crc=0;
u_int32_t actual_len=0;
@ -194,6 +195,21 @@ int main (int argc, char *argv[]) {
printf("\n");
goto next;
case LT_NEWBRTNODE:
printf("NEWBRTNODE:");
transcribe_lsn();
transcribe_txnid();
transcribe_filenum();
transcribe_diskoff();
printf(" height=%d", get_uint32());
printf(" nodesize=%d", get_uint32());
printf(" is_dup_sort=%d", get_char());
printf(" rand=%u", get_uint32());
transcribe_crc32();
transcribe_len();
printf("\n");
goto next;
case LT_UNLINK:
case LT_BLOCK_RENAME:
case LT_CHECKPOINT: