From 8bee8a4b95a15dc21ee842646f66788172d9512a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Milo=C5=A1=20Mula=C4=8D?= Date: Mon, 31 Jan 2005 15:14:12 +0000 Subject: [PATCH] man page for glite-lb-logevent --- org.glite.lb.client/Makefile | 18 ++++- org.glite.lb.client/doc/glite-lb-logevent.1 | 100 +++++++++++++++++++++++++ org.glite.lb.client/project/version.properties | 2 +- 3 files changed, 116 insertions(+), 4 deletions(-) create mode 100644 org.glite.lb.client/doc/glite-lb-logevent.1 diff --git a/org.glite.lb.client/Makefile b/org.glite.lb.client/Makefile index 190755e..e8c58f0 100644 --- a/org.glite.lb.client/Makefile +++ b/org.glite.lb.client/Makefile @@ -23,7 +23,7 @@ CXX:=g++ -include Makefile.inc -VPATH=${top_srcdir}/src:${top_srcdir}/test:${top_srcdir}/examples +VPATH=${top_srcdir}/src:${top_srcdir}/test:${top_srcdir}/examples:${top_srcdir}/doc AT3=perl -I${top_srcdir}/project ${top_srcdir}/project/at3 GENSAM=${top_srcdir}/examples/gen_sample_job @@ -138,6 +138,9 @@ TOOLS:=dump load purge EXAMPLES:=log_usertag_proxy job_log job_reg feed_shark notify query_ext query_seq_code stats abort_job FAKE_EXAMPLES:=job_log_fake +MAN_GZ:=glite-lb-logevent.1.gz +MAN = $(MAN_GZ:.gz=) + version_info=-version-info `echo ${version} | cut -d. -f1,2 | tr . :` ${LIB}: ${LIBOBJS} @@ -187,6 +190,11 @@ ${LIBTHROBJS} ${FAKELIBTHROBJS}: %.thr.o: %.c logevent_fake.o: logevent.c ${COMPILE} ${GLOBUSINC} -c $< -o $@ +${MAN_GZ}: ${MAN} + cp $? . + gzip $(notdir $?) + + # catches $TOOLS and logevent compilation %.o: %.c ${CC} ${CFLAGS} ${GLOBUSINC} -c $< @@ -209,7 +217,7 @@ logevent_fake.o: logevent.c default: all -compile all: check_version ${LIB} ${THRLIB} ${TOOLS} logevent ${PLUSLIB} ${THRPLUSLIB} examples +compile all: check_version ${LIB} ${THRLIB} ${TOOLS} logevent ${PLUSLIB} ${THRPLUSLIB} examples ${MAN_GZ} examples: ${EXAMPLES} ${sh_PROGS} @@ -225,8 +233,10 @@ producer_test: producer_test.o prod_proto_test.o producer_test.o: %.o: %.cpp ${CXX} -c ${CXXFLAGS} ${TEST_INC} ${GLOBUSINC} $< + +man: ${MAN_GZ} -stage: compile ${FAKELIB} ${FAKETHRLIB} +stage: compile ${FAKELIB} ${FAKETHRLIB} $(MAKE) install PREFIX=${stagedir} ${INSTALL} -m 644 ${FAKELIB} ${FAKETHRLIB} ${stagedir}/lib @@ -247,6 +257,7 @@ install: mkdir -p ${PREFIX}/bin mkdir -p ${PREFIX}/lib mkdir -p ${PREFIX}/share/doc/${package}-${version} + mkdir -p ${PREFIX}/share/man/man1 ${INSTALL} -m 644 ${LIB} ${THRLIB} ${PLUSLIB} ${THRPLUSLIB} ${PREFIX}/lib ${INSTALL} -m 644 ${top_srcdir}/LICENSE ${PREFIX}/share/doc/${package}-${version} ${INSTALL} -m 644 ${top_srcdir}/doc/README-fake ${top_srcdir}/doc/README-notify ${PREFIX}/share/doc/${package}-${version} @@ -257,6 +268,7 @@ install: for p in ${TOOLS} logevent ${EXAMPLES} ${sh_PROGS}; do \ ${INSTALL} -m 755 "$$p" "${PREFIX}/examples/glite-lb-$$p"; \ done + ${INSTALL} -m 644 ${MAN_GZ} ${PREFIX}/share/man/man1 clean: diff --git a/org.glite.lb.client/doc/glite-lb-logevent.1 b/org.glite.lb.client/doc/glite-lb-logevent.1 new file mode 100644 index 0000000..4a79400 --- /dev/null +++ b/org.glite.lb.client/doc/glite-lb-logevent.1 @@ -0,0 +1,100 @@ +.TH GLITE-LB-LOGEV 1 "May 2003" "EU EGEE Project" "Logging&Bookkeeping" + +.SH NAME +glite-lb-logev - program for logging events to L&B subsystem + +.SH SYNOPSIS +.B glite-lb-logev +.B -s Application -e UserTag +.B -j +.I JOBID +.B -c +.I SEQCODE +.B --name +.I NAME +.B --value +.I VALUE +.br + +.SH DESCRIPTION +.B glite-lb-logev +is a low-level program for logging events to the L&B service. +It is used internally by WMS components. +At the user level it is supposed to be used only for logging user tag events and changing job ACL's in L&B enventually. + +.SH USAGE +Besides +.I NAME +and +.I VALUE +of the tag, which are user defined, the user has to specify a valid +.I JOBID\fR,\fP +and +.I SEQCODE +(L&B event sequence code). + +The user application is always executed from within a +.I JobWrapper +script. The wrapper sets the appropriate JobId in the environment variable +EDG_WL_JOBID. The user should pass this value to the -j option of +.B edg-wl-logev. + +Similarly, the wrapper sets an initial value of the event sequence code +in the environment variable EDG_WL_SEQUENCE_CODE. +If the user application calls +.B edg-wl-logev +just once, it is sufficient to pass this value to the -c option. +However, if there are more subsequent calls, the user is responsible for +capturing an updated sequence code from the +.B stdout +of +.B edg-wl-logev +and using it in subsequent calls. +The L&B design requires the sequence codes in order to be able to sort +events correctly while not relying on strictly synchronized clocks. + +.SH EXAMPLE +The example bellow is a job consisting of 100 phases. +A user tag +.I phase +is used to log the phase currently being executed. +Subsequently, the user may monitor execution of the job phases +as a part of the job status returned by L&B. + +.nf +#!/bin/sh + +for p in `seq 1 100`; do + + # log the UserTag event + EDG_WL_SEQUENCE_CODE=`edg-wl-logev -s Application + -e UserTag + -j $EDG_WL_JOBID -c $EDG_WL_SEQUENCE_CODE + --name=phase --value=$p` + + # do the actual computation here +done + +.fi + + + +.SH OTHER OPTIONS +See command line help (edg-wl-logev -h) for extensive help on all options. +However, GLITE users should follow the usage shown in SYNOPSIS strictly. +Logging other events may confuse the L&B service and cause wrong job status +information to be reported. + +.SH FILES +No configuration files needed. + +.SH REPORTING BUGS +Please, report all bugs to EU EGEE Bug Tracking System located at https://savannah.cern.ch/bugs/?func=additem&group=jra1mdw + +.SH SEE ALSO +.B edg-wl-bkserver\fR(8),\fP edg-wl-interlogd\fR(8),\fP edg-wl-logd\fR(8) + +L&B API Reference, DataGrid-01-TED-0139 + +.SH AUTHOR +EU DataGrid Work Package 1, CESNET group. diff --git a/org.glite.lb.client/project/version.properties b/org.glite.lb.client/project/version.properties index 39c080f..4d58c75 100644 --- a/org.glite.lb.client/project/version.properties +++ b/org.glite.lb.client/project/version.properties @@ -1,4 +1,4 @@ #Wed Jan 12 04:11:49 CET 2005 -module.version=1.1.0 +module.version=1.1.1 module.build=145 module.age=1 -- 1.8.2.3