Commit 2197ba80 authored by Mike Hibler's avatar Mike Hibler
Browse files

Attempt to un-rot the eventsys code in frisbee.

Back in the day, when the paper was written, I had an eventsys interface
to the client to provide a syncronized interface to multiple running
instances. I rejuvenated the bits, so the eventsys control works again,
however some logic in the client has changed such that a second attempt
to run within the same client hangs. More work needed.
parent 4804b4cb
......@@ -116,7 +116,11 @@ SERVEROBJS = server.o $(SHAREDOBJS)
# Default master server config
MSERVERFLAGS = -DUSE_NULL_CONFIG $(CFLAGS) -I$(OBJDIR)
MSERVEROBJS = mserver.o $(SHAREDOBJS) config.o config_null.o
ifeq ($(SYSTEM),Linux)
MSERVERLIBS = -lrt
else
MSERVERLIBS =
endif
# Master server based image uploader client
UPLOADFLAGS = $(CFLAGS)
......@@ -200,10 +204,11 @@ endif
#CFLAGS += -DNEVENTS=500000
# Turn on client event handling
#CFLAGS += -DDOEVENTS
#CLIENTOBJS += event.o $(OBJDIR)/event/lib/event.o $(OBJDIR)/event/lib/util.o
#CLIENTLIBS += `elvin-config --libs vin4c`
#EVENTFLAGS = $(CFLAGS) `elvin-config --cflags vin4c` -I$(TESTBED_SRCDIR)
# XXX renaming of PacketSend is to avoid a namespace collision with pubsub
#CFLAGS += -DDOEVENTS -DPacketSend=_frisPacketSend
#CLIENTOBJS += event.o $(OBJDIR)/lib/event/event.o $(OBJDIR)/lib/event/util.o
#CLIENTLIBS += -lpubsub
#EVENTFLAGS = $(CFLAGS) -I/usr/local/include/pubsub -I$(TESTBED_SRCDIR)
frisbee-debug: $(CLIENTOBJS)
$(CC) $(LDFLAGS) $(CLIENTFLAGS) $(CLIENTOBJS) $(CLIENTLIBS) $(IUZLIBS) -o $@
......
......@@ -581,17 +581,17 @@ main(int argc, char **argv)
event.data.start.chunkbufs <= MAXCHUNKBUFS)
maxchunkbufs = event.data.start.chunkbufs;
else
maxchunkbufs = MAXCHUNKBUFS;
maxchunkbufs = DEFCHUNKBUFS;
if (event.data.start.writebufmem >= 0 &&
event.data.start.writebufmem < MAXWRITEBUFMEM)
maxwritebufmem = event.data.start.writebufmem;
else
maxwritebufmem = MAXWRITEBUFMEM;
maxwritebufmem = DEFWRITEBUFMEM;
if (event.data.start.maxmem >= 0 &&
event.data.start.maxmem < MAXMEMUSE)
maxmem = event.data.start.maxmem;
else
maxmem = MAXMEMUSE;
maxmem = 0;
if (event.data.start.readahead >= 0 &&
event.data.start.readahead <= maxchunkbufs)
maxreadahead = event.data.start.readahead;
......
/*
* Copyright (c) 2002, 2003 University of Utah and the Flux Group.
* Copyright (c) 2002-2013 University of Utah and the Flux Group.
*
* {{{EMULAB-LICENSE
*
......@@ -28,6 +28,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <netdb.h>
#include <unistd.h>
#include <sys/types.h>
......@@ -37,7 +38,7 @@
#include <sys/time.h>
#include "lib/libtb/tbdefs.h"
#include "event/lib/event.h"
#include "lib/event/event.h"
#include "decls.h"
#include "log.h"
......@@ -330,7 +331,7 @@ EventInit(char *server)
tuple->site = ADDRESSTUPLE_ANY;
tuple->group = ADDRESSTUPLE_ANY;
tuple->expt = ADDRESSTUPLE_ANY;
tuple->objtype = TBDB_OBJECTTYPE_FRISBEE;
tuple->objtype = TBDB_OBJECTTYPE_CUSTOM;
tuple->objname = ADDRESSTUPLE_ANY;
tuple->eventtype = ADDRESSTUPLE_ANY;
......
......@@ -47,6 +47,9 @@
#include <sys/wait.h>
#include <errno.h>
#include <assert.h>
#ifdef WITH_IGMP
#include <sys/time.h>
#endif
#include "decls.h"
#include "utils.h"
#include "configdefs.h"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment