[complement-svn] SF.net SVN: complement: [1778] trunk/complement/explore/app
Status: Pre-Alpha
Brought to you by:
complement
From: <com...@us...> - 2007-10-26 09:39:53
|
Revision: 1778 http://complement.svn.sourceforge.net/complement/?rev=1778&view=rev Author: complement Date: 2007-10-26 02:39:51 -0700 (Fri, 26 Oct 2007) Log Message: ----------- intercessor, request proxy from web server (scripting, as php) to reportware Added Paths: ----------- trunk/complement/explore/app/intercessor/ trunk/complement/explore/app/intercessor/Makefile trunk/complement/explore/app/intercessor/Makefile.inc trunk/complement/explore/app/intercessor/README trunk/complement/explore/app/intercessor/doc/ trunk/complement/explore/app/intercessor/doc/Bib.bib trunk/complement/explore/app/intercessor/doc/IntercessorSoftwareArchitecture.tex trunk/complement/explore/app/intercessor/doc/UseCaseSpec.tex trunk/complement/explore/app/intercessor/doc/intercessor-depl.fig trunk/complement/explore/app/intercessor/doc/intercessor-events.fig trunk/complement/explore/app/intercessor/doc/intercessor-layers.fig trunk/complement/explore/app/intercessor/doc/intercessor-obj.fig trunk/complement/explore/app/intercessor/doc/intercessor-time-neg.fig trunk/complement/explore/app/intercessor/doc/intercessor-time.fig trunk/complement/explore/app/intercessor/doc/rup.sty trunk/complement/explore/app/intercessor/http.cc trunk/complement/explore/app/intercessor/http.h trunk/complement/explore/app/intercessor/intercessor.cc trunk/complement/explore/app/intercessor/intercessor.h trunk/complement/explore/app/intercessor/intercessor_main.cc trunk/complement/explore/app/intercessor/server.cc trunk/complement/explore/app/intercessor/server.h trunk/complement/explore/app/intercessor/unit/ trunk/complement/explore/app/intercessor/unit/Makefile trunk/complement/explore/app/intercessor/unit/Makefile.inc trunk/complement/explore/app/intercessor/unit/dummy_srv.cc trunk/complement/explore/app/intercessor/unit/dummy_srv.h trunk/complement/explore/app/intercessor/unit/unit_test.cc Property changes on: trunk/complement/explore/app/intercessor ___________________________________________________________________ Name: svn:ignore + obj Added: trunk/complement/explore/app/intercessor/Makefile =================================================================== --- trunk/complement/explore/app/intercessor/Makefile (rev 0) +++ trunk/complement/explore/app/intercessor/Makefile 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,31 @@ +# -*- Makefile -*- Time-stamp: <07/02/21 15:30:24 ptr> + +SRCROOT := ../.. +# CoMT_DIR := ../external/complement/explore + +include Makefile.inc +include ${SRCROOT}/Makefiles/gmake/top.mak + +INCLUDES += -I${CoMT_INCLUDE_DIR} -I${BOOST_INCLUDE_DIR} +LDFLAGS += -L${INSTALL_LIB_DIR} -Wl,-rpath=${INSTALL_LIB_DIR} + +release-shared: LDLIBS = -lxmt -lsockios -lstem -lboost_regex -lboost_fs -lboost_program_options +dbg-shared: LDLIBS = -lxmtg -lsockiosg -lstemg -lboost_regexg -lboost_fsg -lboost_program_optionsg +stldbg-shared: LDLIBS = -lxmtstlg -lsockiosstlg -lstemstlg -lboost_regexstlg -lboost_fsstlg -lboost_program_optionsstlg + +check-shared: all-shared + $(MAKE) -C unit check || exit 1 + +check-release-shared: release-shared + $(MAKE) -C unit check-release-shared || exit 1 + +check-dbg-shared: dbg-shared + $(MAKE) -C unit check-dbg-shared || exit 1 + +ifndef WITHOUT_STLPORT +check-stldbg-shared: stldbg-shared + $(MAKE) -C unit check-stldbg-shared || exit 1 +endif + +depend:: + $(MAKE) -C unit depend Added: trunk/complement/explore/app/intercessor/Makefile.inc =================================================================== --- trunk/complement/explore/app/intercessor/Makefile.inc (rev 0) +++ trunk/complement/explore/app/intercessor/Makefile.inc 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,8 @@ +# -*- Makefile -*- + +PRGNAME = intercessor +SRC_CC = intercessor_main.cc \ + http.cc \ + intercessor.cc \ + server.cc + Added: trunk/complement/explore/app/intercessor/README =================================================================== --- trunk/complement/explore/app/intercessor/README (rev 0) +++ trunk/complement/explore/app/intercessor/README 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,50 @@ +This is intercessor, request proxy from php to reportware. + +Options: + -h [ --help ] print help message + -p [ --port=] arg (=8080) listen port (default 8080) + -s [ --save ] arg store uploaded stream to files in this catalog (default none) + -t [ --timeout=] arg (=3) timeout for response from ReportWare Server, seconds (default 3) + -d [ --daemon ] become daemon + +Compilation (on fresh commit): + +./configure +make + +The results will be in build/bin and build/lib +For installation you will need following files: + +build/bin: +intercessor* + +build/lib: following command give you names of required files + +ldd build/bin/intercessor | grep /build/lib/ | awk '{ v = system( "readlink " $3); b = system( "basename " $3 ); }' + +If you developer, and and use 'svn update', following make tags may be useful for you: +make check --- Build and run all possible unit tests for libraries and applications + related to 'intercessor' application. + +make depend --- calculate build dependencies + +make clean --- Delete object files, intermediate depenedency files + that are created by building the program. However, + don't delete the files that record the configuration. + Also preserve dependencies file, tags files and resulting + program or library. + +make distclean --- Same as 'clean' plus delete resulting program(s) or + libraie(s) files, dependencies file and directories that + used for compilation and linking (directories should be + empty at this stage). `make distclean' should leave only + the files that were in the distribution. + + +Projects, that was used in 'intercessor': + - Boost (http://www.boost.org) [program_options, regex, filesystem, test] + - STLport (http://stlport.sourceforge.net) + - Complement (http://complement.sourceforge.net) [xmt, sockios, StEM, Makefiles] + +Architecture desicions and more complete documentation you can found in +doc/IntercessorSoftwareArchitecture.pdf Property changes on: trunk/complement/explore/app/intercessor/doc ___________________________________________________________________ Name: svn:ignore + *.log *.aux *.toc *.dvi *.bbl *.blg *.out *.bak Added: trunk/complement/explore/app/intercessor/doc/Bib.bib =================================================================== --- trunk/complement/explore/app/intercessor/doc/Bib.bib (rev 0) +++ trunk/complement/explore/app/intercessor/doc/Bib.bib 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,62 @@ +@misc { + RFC2616, + author = "R. Fielding and J. Gettys and J. Mogul and H. Frystyk and L. Masinter and P. Leach and T. Berners-Lee", + title = "{RFC} 2616. {H}ypertext {T}ransfer {P}rotocol --- {HTTP}/1.1", + howpublished = "Website", + year = {1999}, + note = "\url{http://www.w3.org/Protocols/rfc2616/rfc2616.html}" +} + +@misc { + ComplementProject, + author = "Petr Ovtchenkov", + title = "``{C}omplement'' project", + howpublished = "Website", + year = {2007}, + note = "\url{http://complement.sourceforge.net}" +} + +@misc { + BoostProject:filesystem, + author = "Beman Dawes", + title = "``{B}oost'', {F}ilesystem", + howpublished = "Website", + year = {2005}, + note = "\url{http://www.boost.org/libs/filesystem/doc/index.htm}" +} + +@misc { + BoostProject:programoptions, + author = "Vladimir Prus", + title = "``{B}oost'', {P}rogram {O}ptions", + howpublished = "Website", + year = {2004}, + note = "\url{http://www.boost.org/doc/html/program_options.html}" +} + +@misc { + BoostProject:regex, + author = "John Maddock", + title = "``{B}oost'', {R}eg{E}x", + howpublished = "Website", + year = {2004}, + note = "\url{http://www.boost.org/libs/regex/doc/index.html}" +} + +@misc { + BoostProject:testutf, + author = "Gennadiy Rozental", + title = "``{B}oost'', {U}nit {T}est {F}ramework", + howpublished = "Website", + year = {2005}, + note = "\url{http://www.boost.org/libs/test/doc/components/utf/index.html}" +} + +@misc { + STLportProject, + author = "Boris Fomitchev and Francois Dumont and Petr Ovtchenkov", + title = "{STL}port", + howpublished = "Website", + year = {2006}, + note = "\url{http://stlport.sourceforge.net}" +} Added: trunk/complement/explore/app/intercessor/doc/IntercessorSoftwareArchitecture.tex =================================================================== --- trunk/complement/explore/app/intercessor/doc/IntercessorSoftwareArchitecture.tex (rev 0) +++ trunk/complement/explore/app/intercessor/doc/IntercessorSoftwareArchitecture.tex 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,720 @@ +% -*- LaTeX -*- + +\documentclass[a4paper,twoside]{article} + +% \usepackage[koi8-r]{inputenc} +\usepackage[T1]{fontenc} +\usepackage[pdftex]{graphics} +\usepackage{pslatex} +% \usepackage[dvips,final]{epsfig} +% \usepackage{cm-super} +\usepackage[colorlinks,urlcolor=blue]{hyperref} +\usepackage{url} +\usepackage{rup} + +%% Define a new 'leo' style for the package that will use a smaller font. +\makeatletter +\def\url@leostyle{% + \@ifundefined{selectfont}{\def\UrlFont{\sf}}{\def\UrlFont{\small\ttfamily}}} +\makeatother +%% Now actually use the newly defined style. +\urlstyle{leo} + +\version{1.2} +\title{Software Architecture Document} + +\project{Intercessor} + +\RevHistory{% +19 Feb 2007 & 1.0 & Initial document & Petr Ovtchenkov \cr \hline +05 Mar 2007 & 1.1 & Functionality changes: early error processing added & Petr Ovtchenkov \cr \hline +07 Mar 2007 & 1.2 & Detailed error codes & Petr Ovtchenkov \cr \hline +} + +\newcommand{\Inter}{{\fontseries{b}\selectfont ``Intercessor''}} + +\begin{document} + +\maketitle + +% [Note: The following template is provided for use with the +% Rational Unified Process. Text enclosed +% in square brackets and displayed in blue italics is included +% to provide guidance to the author and should be deleted before publishing the +% document. A paragraph entered following this style will automatically be set to +% normal.] + +% toc +\tableofcontents + +\section{Introduction} + +% [The introduction of the Software Architecture +% Document should provide an overview of the entire Software +% Architecture Document. It should include the purpose, scope, +% definitions, acronyms, abbreviations, references, and overview of the Software +% Architecture Document.] + +\subsection{Purpose} + +This document provides a comprehensive architectural overview of the \Inter{} server, using a +number of different architectural views to depict different aspects of the +\Inter{}. It is intended to capture and +convey the significant architectural decisions which have been made on the +system. + +\subsection{Scope} + +Software Architecture Document applies to \Inter{} proxy server, +middleware that help +to publish reports related to some server via Web service. + +\subsection{Definitions, Acronyms and Abbreviations} + +% [This subsection should provide the definitions of all terms, +% acronyms, and abbreviations required to properly interpret the Software +% Architecture Document. This information may be provided by +% reference to the project Glossary.] +\begin{description} + \item[HTTP] Hypertext Transfer Protocol + \item[TCP/IP] Transmission Control Protocol and the Internet Protocol (the set of network communications protocols) + \item[URL] Universal Resource Locator + \item[LWP] LightWeight Process + \item[SMP] Symmetrical MultiProcessing + \item[OE] Operational Environment + \item[EDA] Event-Driven Architecture + \item[POSIX] Portable Operating System Interface + \item[BSD] Berkeley Software Distribution + \item[pid] Process ID +\end{description} + +\subsection{References} + +\bibliographystyle{plain} +\bibliography{Bib} + +\subsection{Overview} + +% [This subsection should describe what the rest of the Software +% Architecture Document contains and explain how the Software +% Architecture Document is organized.] + +Following Software Architecture Document consider \Inter{} design and usage from various +points of view (sections~\ref{ArchRep}--\ref{DataView}), performance (section~\ref{SizePerf}) and +aspects of self-testing and quality of \Inter{} (section~\ref{Quality}). + +\section{Architectural Representation\label{ArchRep}} + +% [This section describes what software architecture is for the +% current system, and how it is represented. Of the Use-Case, Logical, +% Process, Deployment, and Implementation +% Views, it enumerates the views that are necessary, and for each view, +% explains what types of model elements it contains.] + +Architectural Representation illustrates \Inter{} design from various aspects: +goals (section~\ref{ArchGoals}), usage (section~\ref{UCView}), logical decomposition (section~\ref{LogicalView}), +concurrency (section~\ref{ProcessView}), deployment (section~\ref{DeplView}), implementation (section~\ref{ImplView}). + +Software Architecture Document contains description of project goals and constraints (section~\ref{ArchGoals}). + +Section~\ref{UCView} shows intended usage of this software and explains why this software +needed. + +Section~\ref{LogicalView} demonstrates the logical position of this software and +interaction with neighbours. + +Section~\ref{ProcessView} focuses on the processes and LWP, this may give useful info for running +this software on SMP OE and estimations of performance scaling of this software. + +Section~\ref{DeplView} describes what shipped within this software, OE requirements +for proper functionality and how to integrate this software into production. + +Section~\ref{ImplView} demonstrates how \Inter{} was implemented. It includes horizontal +and vertical decomposition. + +\section{Architectural Goals and Constraints\label{ArchGoals}} + +Request from some server Web interface to some report generation server +may take a some (unpredictable) time. Because of time restrictions for answer +on Web server side, we need to complete request in a short time, and allow +to read complete result (when it will be ready) in another request. + +There are unconfirmed information, that ReportWare Server accept only \verb|POST| requests. + +It is known, that body of request MUST be XML request (see section~\ref{DataView} for +request sample), otherwise ReportWare Server drop connection without any response. + +Some problems (like wrong ReportWare server URL, bad request content, ans so on) may produce empty response or quick negative response. +It will be good if script on Web Server side receive negative response in such +cases immediately. + +If the error is reported by ReportWare Server, \Inter{} should immediately return +all the ReportWare Server response in addition to error code. + + + +% [This section describes the software requirements and +% objectives that have some significant impact on the architecture, for example, +% safety, security, privacy, use of an off-the-shelf product, portability, +% distribution, and reuse. It also captures the special constraints that may +% apply: design and implementation strategy, development tools, team structure, +% schedule, legacy code, and so on.] + +\section{Use-Case View\label{UCView}} + +Client makes request for report generation. Because report generation takes +some time, and connection between client and web server may be lost during +report generation, client sees something like ``Waiting...'' and then, after +some time, browser refreshes page and user will see report (or error message). + +\subsection{Use-Case Realizations} + +%[This section illustrates how the software actually works by +%giving a few selected use-case (or scenario) realizations, and explains how the +%various design model elements contribute to their functionality.] + +Script running within scope of Web server forward request to \Inter. +\Inter{} validate request and re-translate request to ReportWare server. +If request from script was ill-formed, \Inter{} give negative response to script; +otherwise it gives positive response. + +\Inter{} asynchronously transmit request to ReportWare Server, read response and +save content of the response to a file. + +Script, running within scope of Web server, may check file with ReportWare response +some time later and deliver content (may be after additional processing) to user, +within separate HTTP-request from Web browser to Web Server. + +\section{Logical View\label{LogicalView}} + +% [This section describes the architecturally significant parts +% of the design model, such as its decomposition into subsystems and packages. +% And for each significant package, its decomposition into classes and class +% utilities. You should introduce architecturally significant classes and +% describe their responsibilities, as well as a few very important relationships, +% operations, and attributes.] + +\subsection{Overview} + +The \Inter{} looks like HTTP proxy, but has significant difference: content +delivery isn't transparent for script. + +\Inter{} accept request from script, validate this request, and forward request +(as event) to object responsible for communication with ReportWare Server (fig.~\ref{IntercessorObjDiagram}). +This object check +the ability to perform request and sends it to ReportWare Server. If this object +see positive HTTP response from ReportWare Server (i.e. request was accepted by ReportWare Server) +within time limit (3 seconds), it notify script about success (fig.~\ref{IntercessorTimeDiagram}); otherwise it +notify script about request failure (fig.~\ref{IntercessorTimeDiagramNeg}). + +The content, received from +ReportWare Server, will be stored in special catalog under name, was specified in initial +request (fig.~\ref{IntercessorObjDiagram}, \ref{IntercessorTimeDiagram}). + +% [This subsection describes the overall decomposition of the +% design model in terms of its package hierarchy and layers.] + +\begin{figure} +\begin{center} +% \input intercessor-obj.pstex_t +% \resizebox{3in}{!}{\includegraphics{intercessor-obj.pdf}} +\scalebox{0.8}{\includegraphics{intercessor-obj.pdf}} +\end{center} +\caption{Position of \Inter{}, data flow and objects interaction diagram.\label{IntercessorObjDiagram}} +\end{figure} + +\begin{figure} +\begin{center} +% \input intercessor-time.pstex_t +\scalebox{0.8}{\includegraphics{intercessor-time.pdf}} +\end{center} +\caption{Position of \Inter{}, time diagram.\label{IntercessorTimeDiagram}} +\end{figure} + +\begin{figure} +\begin{center} +\scalebox{0.8}{\includegraphics{intercessor-time-neg.pdf}} +\end{center} +\caption{Position of \Inter{}, time diagram. Behaviour when response from ReportWare Server come beyond expected time interval.\label{IntercessorTimeDiagramNeg}} +\end{figure} + +\subsection{Architecturally Significant Design Packages} + +\subsubsection{``Boost'' project, filesystem} + +``Filesystem'' (\cite{BoostProject:filesystem}) provide facilities to query and manipulate paths, files, and directories. + +\subsubsection{``Boost'' project, program options} + +``Program Options'' (\cite{BoostProject:programoptions}) provide convenient +and uniform way for command line options processing. + +\subsubsection{``Boost'' project, regex} + +``RegEx'' (\cite{BoostProject:regex}) implements fast and rich regular expressions +implementation; it used in HTTP protocol implementation. + +\subsubsection{``Boost'' project, unit test framework} + +``Unit Test Framework'' (\cite{BoostProject:testutf}) used for unit test of \Inter{}. + +\subsubsection{STLport} + +STLport (\cite{STLportProject}) used for effective STL implementation +and important extentions to base STL (access to file descriptor in fstreams---useful utilities from ``Complement'' project \cite{ComplementProject}). + +\subsubsection{``Complement'' project} + +``Complement'' project (\cite{ComplementProject}) provide high level of abstraction for multi-thread programming, +IPC, work with BSD sockets and EDA paradigm implementation. + + +% +% +%[For each significant package, include a subsection with its +%name, its brief description, and a diagram with all significant classes and +%packages contained within the package. +% +%For each significant class in the package, include its name, +%brief description, and, optionally a description of some of its major +%responsibilities, operations and attributes.] + +\section{Process View\label{ProcessView}} + +% [This section describes the system's decomposition into +% lightweight processes (single threads of control) and heavyweight processes +% (groupings of lightweight processes). Organize the section by groups of +% processes that communicate or interact. Describe the main modes of +% communication between processes, such as message passing, interrupts, and +% rendezvous.] + +\Inter{} was designed as multi-threaded server. The number of threads is restricted +in the connection processing server (\verb|sockios|, \cite{ComplementProject}) and +depends upon intensity of requests to server. Default threads limit is 32 (for HTTP-server +part of \Inter{}). + +The ``client'' part of \Inter{} is based on event-driven architecture (\verb|stem|, \cite{ComplementProject}). +It take at least 2 threads. + +\Inter{} may be run as daemon (\verb|-d| or \verb|--daemon| option for \verb|intercessor|). + +\section{Deployment View\label{DeplView}} + +\subsection{Repository} + +Commit project from SVN repository. + +\subsection{Build} + +\begin{verbatim} +(cd intercessor; ./configure; make) +\end{verbatim} + +\subsection{Check build\label{DeplCheck}} + +Run unit tests of all components of \Inter{}: +\begin{verbatim} +(cd intercessor; make check 2>&1) | tee int.log +grep -ie "\(error\)\|\(fail\)" int.log | grep -v exec_fail +\end{verbatim} +Check that result contain only ``\verb|*** No errors detected|'' (or ``\verb|**** no errors detected|'') records. + +For deployment you will need: +\begin{itemize} + \item binary \verb|intercessor/build/bin/intercessor| + \item shared libraries listed as result of output + \verb+v=`ldd intercessor/build/bin/intercessor | \+ \\ + \verb+grep intercessor/build/lib | \+ \\ + \verb+awk '{ print $3 "*"; }'`; for f in $v; do echo $f; done+ ' % $ +% \item files listed as result of output \verb=ldd intercessor/build/bin/intercessor | \= \\ +% \verb=grep intercessor/build/lib | \= \\ +% \verb=awk '{ print $3 "*"; }' | xargs /bin/sh -c 'ls $@'= +\end{itemize} + +\subsection{Deployment} + +\begin{figure} +\begin{center} +% \input intercessor-depl.pstex_t +\scalebox{0.8}{\includegraphics{intercessor-depl.pdf}} +\end{center} +\caption{\Inter{} deployment.\label{IntercessorDeplDiagram}} +\end{figure} + +\Inter{} should be installed so it can share same filesystem as scripts +running in the Web Server space (see fig.~\ref{IntercessorDeplDiagram}). The place for stored files should +be accessible from scripts running in the Web Server space. By security +reasons, this catalog shouldn't be used for other purposes. + +\Inter{} should has ability to connect to ReportWare Server via TCP/IP connection. + +\Inter{} should has ability to listen one TCP port. + +Libraries that shipped with \Inter{} should be searchable by loader: +ones should be situated either in catalogs mentioned in \verb|/etc/ld.so.conf| +or in catalogs from \verb|LD_LIBRARY_PATH| environment variable. You can check +that all libraries accessible with \verb|ldd intercessor|. The dynamic libraries, +that was built within \Inter{} project are: +\begin{itemize} + \item \verb|libxmt.so.1.10| + \item \verb|libsockios.so.1.11| + \item \verb|libstem.so.4.4| + \item \verb|libboost_regex.so.1.33| + \item \verb|libboost_fs.so.1.33| + \item \verb|libboost_program_options.so.1.33| + \item \verb|libstlport.so.5.2| +\end{itemize} + +Unit test (\verb|ut_intercessor|) required additional libraries: +\begin{itemize} + \item \verb|libboost_test_utf.so.1.33| +\end{itemize} + +Available options for \Inter{}: +\begin{itemize} + \item \verb|-h|, \verb|--help| print help message; + \item \verb|-d|, \verb|--daemon| start as daemon (detach from terminal); + \item \verb|-p number|, \verb|--port=number| listen TCP port for incoming requests, default 8080; + \item \verb|-s catalog|, \verb|--save=catalog| save content from ReportWare in this catalog (no default value) + \item \verb|-t number|, \verb|--timeout=number| timeout for response from ReportWare Server, seconds (default 3) +\end{itemize} + +\subsection{Deployment check} + +Start \Inter{} daemon: +\begin{verbatim} +intercessor -p 8095 -s /tmp -d +\end{verbatim} + +Simulate the request from script with \verb|curl|: +\begin{verbatim} +curl -x localhost:8095 -H "X-API-ReportFileName: test.xxx" \ +-d 'xmlrequest=<?xml version="1.0"?>\ +<RWRequest><REQUEST domain="network" service=\"ComplexReport" nocache="n" \ +contact_id="1267" entity="1" filter_entity_id="1" \ +clientName="ui.ent"><ROWS><ROW type="group" priority="1" ref="entity_id" \ +includeascolumn="n"/><ROW type="group" priority=\"2" \ +ref="advertiser_line_item_id" includeascolumn="n"/><ROW type="total"/></ROWS><COLUMNS> \ +<COLUMN \ +ref="advertiser_line_item_name"/><COLUMN ref="seller_imps"/><COLUMN \ +ref="seller_clicks"/><COLUMN ref="seller_convs"/><COLUMN \ +ref="click_rate"/><COLUMN ref="conversion_rate"/><COLUMN ref="roi"/><COLUMN \ +ref="network_revenue"/><COLUMN ref="network_gross_cost"/><COLUMN \ +ref="network_gross_profit"/><COLUMN ref="network_revenue_ecpm"/><COLUMN \ +ref="network_gross_cost_ecpm"/><COLUMN \ +ref="network_gross_profit_ecpm"/></COLUMNS><FILTERS><FILTER ref="time" \ +macro="yesterday"/></FILTERS></REQUEST></RWRequest>' http://ses0316:8080/rpt +\end{verbatim} +Here is assumed that \Inter{} listen TCP port 8095 on \verb|localhost|, URL of ReportWare Server assumed as \verb|http://ses0316:8080/rpt|. + +Check files \verb|/tmp/test.xxx| and \verb|/tmp/test.xxx.head|. It have to had non-zero +sizes. Content of this files should be like mentioned in section~\ref{DataView}. +If no such files, but present files like \verb|/tmp/test.xxx.DpPXyR| +and \verb|/tmp/test.xxx.head.Ua6Gw3|, then no ReportWare Server on requested URL. + +Stop intercessor: +\begin{verbatim} +pkill -TERM intercessor +\end{verbatim} + +\section{Implementation View\label{ImplView}} + +% [This section describes the overall structure of the +% implementation model, the decomposition of the software into layers and +% subsystems in the implementation model, and any architecturally significant +% components.] + +\subsection{Overview} + +\Inter{} contains two functional blocks: +\begin{itemize} + \item HTTP server; it accepts HTTP requests from Web Server scripts; + \item HTTP client; it makes request to ReportWare Server and process response from it. +\end{itemize} + +% [This subsection names and defines the various layers and +% their contents, the rules that govern the inclusion to a given layer, and the +% boundaries between layers. Include a component diagram that shows the relations +% between layers. ] + +Implementation of \Inter{} based on following abstraction layers: +\begin{itemize} + \item http---basic HTTP protocol implementation, suitable for use with C{+}{+} iostreams; + \item StEM---C{+}{+} implementation of EDA; + \item sockios---client and server working on top of tcp sockets; + \item xmt---multi-thread and few core IPC techniques; + \item BSD sockets; + \item POSIX threads. +\end{itemize} + +\subsection{Functional blocks} + +\begin{figure} +\begin{center} +\scalebox{0.8}{\includegraphics{intercessor-events.pdf}} +\end{center} +\caption{Logical blocks of \Inter{}, events diagram.\label{IntercessorEventsDiagram}} +\end{figure} + +\subsubsection{HTTP server\label{HTTPsrv}} + +Base name of file where content of ReportWare response will be stored +passed by script in the HTTP header \verb|X-API-ReportFileName|. +This header is also used for request validation. If this header absents, +or value in this header contains symbols except alphanumeric, dot and +underscore, the request will be rejected and not translated to ReportWare. +In this case return code will be 412, ``Precondition Failed''. + +\Inter{} accepts only \verb|POST| or \verb|GET| requests, otherwise return +code will be 405, ``Method Not Allowed''. + +If HTTP request looks good, \Inter{} return code 202 ``Accepted'' with zero-length +content. + +\begin{table}[h] + \centering + \begin{tabular}{c|l|p{3in}} + \hline + {\fontseries{b}\selectfont Code} & {\fontseries{b}\selectfont\hfil HTTP meaning} & {\fontseries{b}\selectfont\hfil Description} \\ + \hline + 202 & Accepted & request accepted and retransmitted to ReportWare Server; ReportWare Server give positive HTTP response \\ + \hline + 405 & Method Not Allowed & HTTP command was not \verb|GET| or \verb|POST| \\ + \hline + 412 & Precondition Failed & in the HTTP request + was missed HTTP header \verb|X-API-ReportFileName|, or value of + HTTP header \verb|X-API-ReportFileName| contain symbol that not alphanumeric, + dot or underscore or file(s) mentioned in \verb|X-API-ReportFileName| already exists \\ + \hline + 503 & Service Unavailable & response from ReportWare Server was negative \\ + \hline + 504 & Gateway Timeout & response from ReportWare Server + not received within expected timeout interval (3 seconds by default) \\ + \hline + \end{tabular} + \caption{Summary of codes, that may be returned to script.\label{HTTPcodes}} +\end{table} + +After validation of incoming request, it forwarded (as asynchronous event) +to HTTP client logical block of \Inter{} and waiting positive or negative response from it. +If response was positive (ReportWare Server give positive HTTP response within 3 seconds), +the positive response will be returned to origin of initial request. If the response was +negative, \Inter{} will return to origin of initial request the negative response of ReportWare Server as is. +If \Inter{} don't take response within 3 seconds interval, \Inter{} will return +to origin of initial request the negative response 504 ``Gateway Timeout'' (see fig.~\ref{IntercessorEventsDiagram}). + +Summary of HTTP codes, that \Inter{} may return, shown in table~\ref{HTTPcodes}. + +Motivation to return 202 code on success instead of ``200 Ok'', follow from +\href{http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.2.3}{item 10.2.3 of RFC~2616} \cite{RFC2616}: + +\begin{quotation} + \noindent{\bfseries 10.2.3 202 Accepted} + + The request has been accepted for processing, but the processing + has not been completed. The request might or might not eventually + be acted upon, as it might be disallowed when processing actually + takes place. There is no facility for re-sending a status code + from an asynchronous operation such as this. + + The 202 response is intentionally non-committal. Its purpose is + to allow a server to accept a request for some other process + (perhaps a batch-oriented process that is only run once per day) + without requiring that the user agent's connection to the server + persist until the process is completed. The entity returned with + this response SHOULD include an indication of the request's current + status and either a pointer to a status monitor or some estimate + of when the user can expect the request to be fulfilled. +\end{quotation} + + +\subsubsection{HTTP client\label{HTTPcli}} + +HTTP client logical block check, that there is no files in specified catalog (option \verb|-s|) +with names like specified in \verb|X-API-ReportFileName| header (neither file with name as value from \verb|X-API-ReportFileName| +header, nor file with name as value from \verb|X-API-ReportFileName| header plus ``\verb|.head|''). +If such files was found, the request discarded. + +HTTP client logical block create two files (in specified catalog, with names mentioned above) and +open its for writing. If this procedure was failed, the request discarded. + +HTTP client logical block use HTTP header \verb|Host| to detect URL of ReportWare Server. +This is like all HTTP proxy do. + +\Inter{} connect to ReportWare Server (using URL from \verb|Host|, as mentioned above) +and send to it the same request, as was received from Web Server script, except +\verb|X-API-ReportFileName| header and \verb|Proxy-Connection| header. + +During processing response from ReportWare Server \Inter{} split HTTP headers from content, +and process content in accordance with HTTP protocol. + +When \Inter{} see the code of HTTP response from ReportWare, it detect that response was +positive or negative and inform HTTP server logical block of \Inter{} via asynchronous event (see fig.~\ref{IntercessorEventsDiagram}). + +\subsection{Vertical Layers} + +Figure~\ref{IntercessorLayersDiagram} demonstrates decomposition of \Inter{}'s implementation into vertical layers. Layers 'complement', C++ and 'system' are external to this project. + +% [For each layer, include a subsection with its name, an +% enumeration of the subsystems located in the layer, and a component diagram.] +\begin{figure} +\begin{center} +% \input intercessor-depl.pstex_t +\scalebox{0.8}{\includegraphics{intercessor-layers.pdf}} +\end{center} +\caption{\Inter{} design, implementation layers.\label{IntercessorLayersDiagram}} +\end{figure} + +\subsubsection{Intercessor} + +Application is based on BSD sockets server and client, implemented in \verb|sockios| +(\ref{sockios}) and HTTP protocol implementation (\ref{httpproto}). + +\subsubsection{HTTP protocol\label{httpproto}} + +Due to HTTP protocol is text-based, it may be effectively implemented +on top of C++ \verb|istream|/\verb|ostream|. + +\subsubsection{EDA implementation\label{StEM}} + +EDA implemented in \verb|StEM| library (part of \cite{ComplementProject}). + +\subsubsection{BSD TCP sockets, client and server\label{sockios}} + +BSD sockets server and client implemented in \verb|sockios| library, part of +\cite{ComplementProject}. It is based on +multi-threading server concept and use \verb|xmt| (\ref{xmt}) library. + +\subsubsection{Threads and IPC\label{xmt}} + +Deal with threads, synchronization primitives and IPC methods +is encapsulated in \verb|xmt| library, part of \cite{ComplementProject}. + +\subsubsection{System} + +Underling level is ordinary POSIX-like OE with POSIX threads and BSD +sockets. Any modern Linux acceptable. + +\section{Data View\label{DataView}} + +Raw HTTP request from Web Server script (every line is ended with CR/LF pair). +\begin{verbatim} +POST http://localhost:8090/test.php HTTP/1.1 +Host: localhost:8090 +X-API-ReportFileName: test.xxx +Content-Length: 890 + +xmlrequest=<?xml version="1.0"?> +<RWRequest><REQUEST domain="network" service="ComplexReport" nocache="n" +contact_id="1267" entity="1" filter_entity_id="1" +clientName="ui.ent"><ROWS><ROW type="group" priority="1" ref="entity_id" +includeascolumn="n"/><ROW type="group" priority="2" +ref="advertiser_line_item_id" includeascolumn="n"/><ROW type="total"/></ROWS> +<COLUMNS><COLUMN +ref="advertiser_line_item_name"/><COLUMN ref="seller_imps"/><COLUMN +ref="seller_clicks"/><COLUMN ref="seller_convs"/><COLUMN +ref="click_rate"/><COLUMN ref="conversion_rate"/><COLUMN ref="roi"/><COLUMN +ref="network_revenue"/><COLUMN ref="network_gross_cost"/><COLUMN +ref="network_gross_profit"/><COLUMN ref="network_revenue_ecpm"/><COLUMN +ref="network_gross_cost_ecpm"/><COLUMN +ref="network_gross_profit_ecpm"/></COLUMNS><FILTERS><FILTER ref="time" +macro="yesterday"/></FILTERS></REQUEST></RWRequest> +\end{verbatim} + +Content of file with headers from ReportWare Server response (\verb|test.xxx.head|, for +request above): +\begin{verbatim} +HTTP/1.1 200 Ok +Server: Apache-Coyote/1.1 +Content-Type: text/html;charset=ISO-8859-1 +Content-Length: 8132 +Date: Sun, 18 Feb 2007 16:22:04 GMT + +\end{verbatim} + +Content of file with data from ReportWare Server response (\verb|test.xxx|, for +request above): +\begin{verbatim} +<?xml version="1.0" encoding="ISO-8859-1"?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> + +<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> + <head> + <title>Apache Tomcat/5.5.20</title> + <style type="text/css"> + /*<![CDATA[*/ + body { + color: #000000; +... + + </tr> +</table> + +</body> +</html> +\end{verbatim} + + +% [A description of the persistent data storage perspective of +% the system. This section is optional if there is little or no persistent data, +% or the translation between the Design Model and the Data Model is trivial.] + +\section{Size and Performance\label{SizePerf}} + +% [A description of the major dimensioning characteristics of +% the software that impact the architecture, as well as the target performance +% constraints.] + +At present time no sure information about size of indicative requests and +responses. + +The perforamance aspects unknown too: intensity of requests unfortunately +not evident too. + +\section{Quality\label{Quality}} + +% [A description of how the software architecture contributes +% to all capabilities (other than functionality) of the system: extensibility, +% reliability, portability, and so on. If these characteristics have special +% significance, for example safety, security or privacy implications, they should +% be clearly delineated.] + +The unit tests for all components involved ('check' procedure, section~\ref{DeplCheck}) +allow to detect problem on early stage. But this tests don't make massive testing, +testing with real scripts and real ReportWare Server\footnote{Test with real +ReportWare Server available, but there are difficulties with rest of test infrastructure.}. + +\Inter{} may be used for requests logging, signaling and other notifications, including +notifications about some events. This functionality +may be added relatively easy, because of asynchronous nature of \Inter{} architecture. + +% reliability + +% No requirements for reliability?! + +% portability + +No special requirements for portability. Expected, that code of \Inter{} and related +components will be compiled and run under any POSIX-compliant architecture. + +% safety + +The aspects of authentication, validation of data, safety of stored files should be taken into +account during administration of the OE, and not considered within scope of \Inter{} server. + +\subsection{Known restrictions and bugs} + +At present time known following potential problems: +\begin{itemize} + \item HTTP header \verb|Keep-Alive| is not taken into account; + \item persistent connection is not supported; this is normal for connection with + WebServer script, but may be treated as drawback in connection with + ReportWare server (extra load on ReportWare server); + \item HTTP protocol is announced as HTTP 1.1, but not all protocol issues were implemented, + and switching to HTTP 1.0 was not considered; + \item \Inter{} when become daemon, don't save own pid in any file; this may be not very convenient + for administration and monitoring. +\end{itemize} + +\end{document} Added: trunk/complement/explore/app/intercessor/doc/UseCaseSpec.tex =================================================================== --- trunk/complement/explore/app/intercessor/doc/UseCaseSpec.tex (rev 0) +++ trunk/complement/explore/app/intercessor/doc/UseCaseSpec.tex 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,76 @@ +% -*- LaTeX -*- +% $Id: UseCaseSpec.tex,v 1.1 2002/11/04 10:54:23 ptr Exp $ + +\documentclass[a4paper,twoside]{article} + +\usepackage{rup} + +\title{Use-Case-Realization Specification: ``Use-Case Name''} + +\project{Virtual Manual} +% \RevHistory{dd/mmmm/yyyy & x.x & & \cr \hline} + +\begin{document} + +\maketitle + +\section{Introduction} + +[The introduction of the Use-Case Realization Specification +should provide an overview of the entire document. It should include the +purpose, scope, definitions, acronyms, abbreviations, references, and overview +of this Use-Case Realization Specification.] + +[Note: This document template assumes that the use-case +realization is partly described within a Rational Rose model; this means that +the use case's name and brief description is within the Rose model, and that +this document should be linked as an external file to the use case. This +document should contain additional properties of the use-case realization that +are not in the Rose model.] + +\subsection{Purpose} + +[Specify the purpose of this Use-Case Realization Specification] + +\subsection{Scope} + +[A brief description of the scope of this Use-Case +Realization Specification; what Use Case model(s) it is associated with, +and anything else that is affected or influenced by this document.] + +\subsection{Definitions, Acronyms and Abbreviations} + +[This subsection should provide the definitions of all terms, +acronyms, and abbreviations required to properly interpret the Use-Case +Realization Specification. This information may be provided by +reference to the project Glossary.] + +\subsection{References} + +[This subsection should provide a complete list of all +documents referenced elsewhere in the Use-Case Realization Specification. +Each document should be identified by title, +report number (if applicable), date, and publishing organization. Specify the sources from which the +references can be obtained. This information may be provided by reference to an +appendix or to another document.] + +\subsection{Overview} + +[This subsection should describe what the rest of the Use-Case +Realization Specification contains and explain how the document is +organized.] + +\section{Flow of Events Design} + +[A textual description of how the use case is realized in +terms of collaborating objects. Its main purpose is to summarize the diagrams +connected to the use case and to explain how they are related.] + +\section{Derived Requirements} + +[A textual description that collects all requirements, such +as non-functional requirements, on the use-case realizations that are not +considered in the design model, but that need to be taken care of during +implementation.] + +\end{document} Added: trunk/complement/explore/app/intercessor/doc/intercessor-depl.fig =================================================================== --- trunk/complement/explore/app/intercessor/doc/intercessor-depl.fig (rev 0) +++ trunk/complement/explore/app/intercessor/doc/intercessor-depl.fig 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,106 @@ +#FIG 3.2 Produced by xfig version 3.2.5-alpha5 +Landscape +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +0 32 #868286 +0 33 #c7c3c7 +0 34 #e7e3e7 +0 35 #808080 +0 36 #c0c0c0 +0 37 #e0e0e0 +0 38 #8e8e8e +0 39 #8e8f8e +0 40 #444444 +0 41 #868686 +0 42 #c7c7c7 +0 43 #e7e7e7 +0 44 #f7f7f7 +0 45 #9e9e9e +0 46 #717571 +0 47 #414541 +0 48 #757575 +0 49 #414141 +0 50 #effbff +0 51 #404040 +0 52 #f3f3f3 +0 53 #aaaaaa +0 54 #555555 +0 55 #d7d3d7 +0 56 #aeaaae +0 57 #c2c2c2 +0 58 #303030 +0 59 #515551 +0 60 #f7f3f7 +0 61 #666666 +0 62 #717171 +0 63 #c6b797 +0 64 #eff8ff +0 65 #dccba6 +0 66 #d7d7d7 +0 67 #aeaeae +0 68 #bebebe +0 69 #515151 +0 70 #000049 +0 71 #797979 +0 72 #303430 +0 73 #c7b696 +6 1650 2250 2925 2775 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 1650 2250 2925 2250 2925 2775 1650 2775 1650 2250 +4 1 0 50 -1 4 10 0.0000 0 120 780 2325 2550 Intercessor\001 +-6 +6 4950 2250 6075 2775 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 4950 2250 6075 2250 6075 2775 4950 2775 4950 2250 +4 1 0 50 -1 4 10 0.0000 0 120 810 5550 2550 Web Server\001 +-6 +6 3720 3825 4200 4725 +5 1 0 1 -1 7 80 0 20 0.000 0 1 0 0 3960.000 4185.000 3720 4635 3960 4695 4200 4635 +5 1 0 1 -1 7 80 0 20 0.000 0 1 0 0 3960.000 3465.000 3720 3915 3960 3975 4200 3915 +5 1 0 1 -1 7 80 0 20 0.000 0 1 0 0 3960.000 3585.000 3720 4035 3960 4095 4200 4035 +5 1 0 1 -1 7 80 0 20 0.000 0 1 0 0 3960.000 3705.000 3720 4155 3960 4215 4200 4155 +5 1 0 1 -1 7 81 0 20 0.000 0 1 0 0 3960.000 4365.000 4200 3915 3960 3855 3720 3915 +2 1 0 1 -1 7 80 0 20 0.000 0 0 7 0 0 2 + 4200 4635 4200 3915 +2 1 0 1 -1 7 80 0 20 0.000 0 0 7 0 0 2 + 3720 3915 3720 4635 +2 2 0 0 -1 7 81 -1 20 0.000 0 0 -1 0 0 5 + 3720 3915 4200 3915 4200 4635 3720 4635 3720 3915 +-6 +6 1650 600 2850 1050 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 1650 600 2850 600 2850 1050 1650 1050 1650 600 +4 1 0 50 -1 4 10 0.0000 0 150 825 2250 900 ReportWare\001 +-6 +6 5025 675 6000 1050 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 5025 675 6000 675 6000 1050 5025 1050 5025 675 +4 1 0 50 -1 4 10 0.0000 0 120 585 5550 900 Browser\001 +-6 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 2400 2775 3675 3900 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4200 3900 5550 2775 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 1 4 + 0 0 1.00 60.00 120.00 + 0 0 1.00 60.00 120.00 + 5400 1050 5400 1650 5625 1350 5625 2250 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 1 4 + 0 0 1.00 60.00 120.00 + 0 0 1.00 60.00 120.00 + 2175 1050 2175 1725 2400 1425 2400 2250 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 1 4 + 0 0 1.00 60.00 120.00 + 0 0 1.00 60.00 120.00 + 2925 2400 3975 2400 3600 2550 4950 2550 +4 0 0 50 -1 4 10 0.0000 0 120 1275 5850 1725 HTTP over TCP/IP\001 +4 1 0 50 -1 4 10 0.0000 0 120 240 4425 4275 HD\001 +4 0 0 50 -1 4 10 0.0000 0 120 1275 2625 1725 HTTP over TCP/IP\001 +4 0 0 50 -1 4 10 0.0000 0 120 1275 3375 2250 HTTP over TCP/IP\001 Added: trunk/complement/explore/app/intercessor/doc/intercessor-events.fig =================================================================== --- trunk/complement/explore/app/intercessor/doc/intercessor-events.fig (rev 0) +++ trunk/complement/explore/app/intercessor/doc/intercessor-events.fig 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,53 @@ +#FIG 3.2 Produced by xfig version 3.2.5-alpha5 +Portrait +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +1 1 0 1 0 11 48 -1 20 0.000 1 0.0000 2100 2700 825 450 2100 2700 2925 2700 +1 1 0 1 0 11 48 -1 20 0.000 1 0.0000 4950 2700 825 450 4950 2700 5775 2700 +2 2 0 1 0 30 50 -1 20 0.000 0 0 -1 0 0 5 + 1050 1800 6150 1800 6150 3600 1050 3600 1050 1800 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 1875 1125 1650 1650 1950 2250 + 0.000 -1.000 0.000 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 2925 2625 3600 2325 4200 2550 + 0.000 -1.000 0.000 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 4200 2925 3675 3150 2850 2850 + 0.000 -1.000 0.000 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 2400 2250 2775 1650 2550 1125 + 0.000 -1.000 0.000 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 4725 2250 4350 1500 4650 1050 + 0.000 -1.000 0.000 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 5400 1050 5550 1575 5250 2325 + 0.000 -1.000 0.000 +3 2 0 1 0 7 47 -1 -1 0.000 0 1 0 3 + 0 0 1.00 60.00 120.00 + 4950 3150 4500 3750 5025 4425 + 0.000 -1.000 0.000 +4 1 0 47 -1 4 10 0.0000 0 120 780 5025 2775 HTTP client\001 +4 1 0 47 -1 4 10 0.0000 0 120 855 2175 2775 HTTP server\001 +4 0 0 47 -1 4 10 0.0000 0 150 510 3225 2250 request\001 +4 0 0 47 -1 4 10 0.0000 0 150 1095 3225 3300 response status\001 +4 2 0 47 -1 4 10 0.0000 0 150 510 1575 1500 request\001 +4 0 0 47 -1 4 10 0.0000 0 120 630 2850 1500 response\001 +4 0 0 47 -1 4 10 0.0000 0 120 630 5700 1500 response\001 +4 2 0 47 -1 4 10 0.0000 0 150 510 4275 1425 request\001 +4 2 0 47 -1 4 10 0.0000 0 120 195 4350 3825 file\001 +4 1 0 47 -1 4 10 0.0000 0 150 705 5025 4575 Filesystem\001 +4 1 0 47 -1 4 10 0.0000 0 150 420 2175 900 Script\001 +4 1 0 47 -1 4 10 0.0000 0 150 1335 4950 900 ReportWare Server\001 Added: trunk/complement/explore/app/intercessor/doc/intercessor-layers.fig =================================================================== --- trunk/complement/explore/app/intercessor/doc/intercessor-layers.fig (rev 0) +++ trunk/complement/explore/app/intercessor/doc/intercessor-layers.fig 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,98 @@ +#FIG 3.2 Produced by xfig version 3.2.5-alpha5 +Landscape +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +0 32 #868286 +0 33 #c7c3c7 +0 34 #e7e3e7 +0 35 #808080 +0 36 #c0c0c0 +0 37 #e0e0e0 +0 38 #8e8e8e +0 39 #8e8f8e +0 40 #444444 +0 41 #868686 +0 42 #c7c7c7 +0 43 #e7e7e7 +0 44 #f7f7f7 +0 45 #9e9e9e +0 46 #717571 +0 47 #414541 +0 48 #757575 +0 49 #414141 +0 50 #effbff +0 51 #404040 +0 52 #f3f3f3 +0 53 #aaaaaa +0 54 #555555 +0 55 #d7d3d7 +0 56 #aeaaae +0 57 #c2c2c2 +0 58 #303030 +0 59 #515551 +0 60 #f7f3f7 +0 61 #666666 +0 62 #717171 +0 63 #c6b797 +0 64 #eff8ff +0 65 #dccba6 +0 66 #d7d7d7 +0 67 #aeaeae +0 68 #bebebe +0 69 #515151 +0 70 #000049 +0 71 #797979 +0 72 #303430 +0 73 #c7b696 +6 2550 4050 4650 4500 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 2550 4050 4650 4050 4650 4500 2550 4500 2550 4050 +4 1 0 50 -1 4 10 0.0000 0 120 1005 3675 4350 C++ iostreams\001 +-6 +6 4650 4500 7875 4950 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 4650 4500 6375 4500 6375 4950 4650 4950 4650 4500 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 6375 4500 7875 4500 7875 4950 6375 4950 6375 4500 +4 1 0 50 -1 4 10 0.0000 0 120 1050 5550 4800 POSIX threads\001 +4 1 0 50 -1 4 10 0.0000 0 120 900 7275 4800 BSD sockets\001 +-6 +6 1050 1800 7875 2700 +6 2550 2250 3450 2700 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 3450 2700 2550 2700 2550 2250 3450 2250 3450 2700 +4 1 0 50 -1 4 10 0.0000 0 150 300 3000 2550 http\001 +-6 +2 2 0 0 0 45 60 -1 20 0.000 0 0 -1 0 0 5 + 7875 2700 1050 2700 1050 2250 7875 2250 7875 2700 +2 2 0 0 0 44 60 -1 20 0.000 0 0 -1 0 0 5 + 7875 2250 1050 2250 1050 1800 7875 1800 7875 2250 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 2550 1800 7875 1800 7875 2250 2550 2250 2550 1800 +4 0 0 50 -1 4 10 0.0000 0 150 825 1200 2475 App. librairy\001 +4 1 0 50 -1 4 10 0.0000 0 120 780 5100 2100 Intercessor\001 +4 0 0 50 -1 4 10 0.0000 0 150 765 1200 2100 Application\001 +-6 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 4650 3600 6375 3600 6375 4050 4650 4050 4650 3600 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 3450 3150 7875 3150 7875 3600 3450 3600 3450 3150 +2 2 0 0 0 30 60 -1 20 0.000 0 0 -1 0 0 5 + 7875 4500 1050 4500 1050 4050 7875 4050 7875 4500 +2 2 0 0 0 11 60 -1 20 0.000 0 0 -1 0 0 5 + 7875 4950 1050 4950 1050 4500 7875 4500 7875 4950 +2 2 0 0 0 33 60 -1 20 0.000 0 0 -1 0 0 5 + 7875 4050 1050 4050 1050 2700 7875 2700 7875 4050 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 3450 2700 7875 2700 7875 3150 3450 3150 3450 2700 +4 1 0 50 -1 4 10 0.0000 0 150 1500 5550 3900 xmt, threads and IPC\001 +4 1 0 50 -1 4 10 0.0000 0 120 510 5550 3450 sockios\001 +4 0 0 50 -1 4 10 0.0000 0 150 510 1200 4800 System\001 +4 0 0 50 -1 4 10 0.0000 0 120 300 1200 4350 C++\001 +4 1 0 50 -1 4 10 0.0000 0 120 405 5550 3000 StEM\001 +4 0 0 50 -1 4 10 0.0000 0 150 870 1200 3450 Complement\001 Added: trunk/complement/explore/app/intercessor/doc/intercessor-obj.fig =================================================================== --- trunk/complement/explore/app/intercessor/doc/intercessor-obj.fig (rev 0) +++ trunk/complement/explore/app/intercessor/doc/intercessor-obj.fig 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,80 @@ +#FIG 3.2 Produced by xfig version 3.2.5-alpha5 +Portrait +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +6 2700 2475 3750 2925 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 2700 2475 3750 2475 3750 2925 2700 2925 2700 2475 +4 1 0 50 -1 4 10 0.0000 0 150 420 3225 2775 Script\001 +-6 +6 4350 2475 5400 2925 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 4350 2475 5400 2475 5400 2925 4350 2925 4350 2475 +4 1 0 50 -1 4 10 0.0000 0 150 420 4875 2775 Script\001 +-6 +6 4500 3900 5325 4350 +2 2 0 1 0 7 50 -1 -1 4.000 0 0 -1 0 0 5 + 4500 3900 5325 3900 5325 4350 4500 4350 4500 3900 +4 1 0 50 -1 4 10 0.0000 0 120 225 4950 4200 File\001 +-6 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3900 750 3900 1425 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4350 1425 4350 750 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3750 1950 3150 2475 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3450 2475 4050 1950 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4200 1950 4725 2475 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 5025 2475 4500 1950 +2 2 0 1 0 7 50 -1 -1 4.000 0 0 -1 0 0 5 + 3675 300 4725 300 4725 750 3675 750 3675 300 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 2925 1200 3900 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1650 3900 3375 2925 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 3600 1425 4725 1425 4725 1950 3600 1950 3600 1425 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 825 3900 2175 3900 2175 4425 825 4425 825 3900 +2 2 0 1 0 7 50 -1 -1 0.000 0 0 -1 0 0 5 + 825 5100 2250 5100 2250 5625 825 5625 825 5100 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1200 4425 1200 5100 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 5100 1800 4425 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 2175 4125 4500 4125 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4875 3900 4875 2925 +4 1 0 50 -1 4 10 0.0000 0 120 585 4200 600 Browser\001 +4 0 0 50 -1 20 12 0.0000 4 120 720 4500 1125 responce\001 +4 2 0 50 -1 20 12 0.0000 4 150 630 3825 1125 request\001 +4 1 0 50 -1 4 10 0.0000 0 120 810 4200 1725 Web Server\001 +4 1 0 50 -1 4 10 0.0000 0 120 780 1500 4200 Intercessor\001 +4 1 0 50 -1 4 10 0.0000 0 150 825 1575 5400 ReportWare\001 +4 0 0 50 -1 4 10 0.0000 0 120 630 2625 3600 responce\001 +4 2 0 50 -1 4 10 0.0000 0 150 510 2025 3300 request\001 +4 0 0 50 -1 4 10 0.0000 0 120 630 1950 4800 responce\001 +4 2 0 50 -1 4 10 0.0000 0 150 510 1050 4800 request\001 +4 0 0 50 -1 4 10 0.0000 0 120 345 3075 3975 write\001 +4 0 0 50 -1 4 10 0.0000 0 120 300 5025 3450 read\001 Added: trunk/complement/explore/app/intercessor/doc/intercessor-time-neg.fig =================================================================== --- trunk/complement/explore/app/intercessor/doc/intercessor-time-neg.fig (rev 0) +++ trunk/complement/explore/app/intercessor/doc/intercessor-time-neg.fig 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,53 @@ +#FIG 3.2 Produced by xfig version 3.2.5-alpha5 +Portrait +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 975 3000 1200 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 1200 5400 1650 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 750 1800 3600 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 750 3000 3600 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4200 750 4200 3600 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 5400 750 5400 3600 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 600 750 600 3600 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 600 900 1800 975 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 2475 1800 2700 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 2700 600 2925 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 5400 2577 3000 3102 +4 1 0 50 -1 4 10 0.0000 0 120 330 600 600 User\001 +4 1 0 50 -1 4 10 0.0000 0 120 780 3000 600 Intercessor\001 +4 1 0 50 -1 4 10 0.0000 0 150 705 4200 600 Filesystem\001 +4 1 0 50 -1 4 10 0.0000 0 150 825 5400 600 ReportWare\001 +4 0 0 50 -1 4 10 0.0000 0 150 645 825 825 request 1\001 +4 1 0 50 -1 4 10 0.0000 0 150 1365 1725 600 Web Server (script)\001 +4 0 0 50 -1 4 10 0.0000 0 120 675 825 2550 content 1\001 +4 0 0 50 -1 4 10 0.0000 0 150 645 3375 1200 request 1\001 +4 0 0 50 -1 4 10 0.0000 0 120 630 4425 2550 response\001 +4 0 0 50 -1 4 10 0.0000 0 120 60 5550 3525 t\001 +4 0 0 50 -1 4 10 0.0000 0 150 1260 2100 2400 negative response\001 Added: trunk/complement/explore/app/intercessor/doc/intercessor-time.fig =================================================================== --- trunk/complement/explore/app/intercessor/doc/intercessor-time.fig (rev 0) +++ trunk/complement/explore/app/intercessor/doc/intercessor-time.fig 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,77 @@ +#FIG 3.2 Produced by xfig version 3.2.5-alpha5 +Portrait +Center +Inches +Letter +100.00 +Single +-2 +1200 2 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 975 3000 1200 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 1200 5400 1650 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 5400 2325 3000 2925 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 3525 4200 3825 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 4650 4200 4950 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4200 5175 1800 5400 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 750 1800 6000 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 750 3000 6000 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 4200 750 4200 6000 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 5400 750 5400 6000 +2 1 1 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 600 750 600 6000 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 600 900 1800 975 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 600 4500 1800 4650 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 5400 600 5550 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 3000 2475 1800 2700 +2 1 0 1 0 7 50 -1 -1 4.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 1800 2700 600 2925 +2 1 0 1 0 7 50 -1 -1 0.000 0 0 -1 1 0 2 + 0 0 1.00 60.00 120.00 + 5400 1800 3000 2325 +4 1 0 50 -1 4 10 0.0000 0 120 330 600 600 User\001 +4 1 0 50 -1 4 10 0.0000 0 120 780 3000 600 Intercessor\001 +4 1 0 50 -1 4 10 0.0000 0 150 705 4200 600 Filesystem\001 +4 1 0 50 -1 4 10 0.0000 0 150 825 5400 600 ReportWare\001 +4 0 0 50 -1 4 10 0.0000 0 150 645 825 825 request 1\001 +4 0 0 50 -1 4 10 0.0000 0 120 675 825 5325 content 2\001 +4 0 0 50 -1 4 10 0.0000 0 150 645 825 4425 request 2\001 +4 0 0 50 -1 4 10 0.0000 0 120 60 5550 5850 t\001 +4 0 0 50 -1 4 10 0.0000 0 120 675 3300 3525 content 2\001 +4 0 0 50 -1 4 10 0.0000 0 120 675 3075 5175 content 2\001 +4 0 0 50 -1 4 10 0.0000 0 150 540 2025 4575 try read\001 +4 1 0 50 -1 4 10 0.0000 0 150 1365 1725 600 Web Server (script)\001 +4 0 0 50 -1 4 10 0.0000 0 120 675 825 2550 content 1\001 +4 0 0 50 -1 4 10 0.0000 0 120 675 4500 2775 content 2\001 +4 0 0 50 -1 4 10 0.0000 0 120 630 2100 2475 response\001 +4 0 0 50 -1 4 10 0.0000 0 150 645 3375 1200 request 1\001 +4 0 0 50 -1 4 10 0.0000 0 120 630 3375 2025 response\001 Added: trunk/complement/explore/app/intercessor/doc/rup.sty =================================================================== --- trunk/complement/explore/app/intercessor/doc/rup.sty (rev 0) +++ trunk/complement/explore/app/intercessor/doc/rup.sty 2007-10-26 09:39:51 UTC (rev 1778) @@ -0,0 +1,150 @@ +% -*- LaTeX -*- +% $Id: rup.sty,v 1.1 2002/11/04 10:53:08 ptr Exp $ + +\makeatletter + +\NeedsTeXFormat{LaTeX2e}[1995/12/01] +\ProvidesClass{rup}[2002/10/24 v0.1 RUP document class] + +\newcommand\version[1]{\gdef\@version{#1}} +\gdef\@version{1{.}0} +\newcommand\project[1]{\gdef\@project{#1}} +\gdef\@project{Project Name} +\newcommand\RevHistory[1]{\gdef\@revhistory{#1}} +\gdef\@revhistory{dd/mmmm/yyyy & x.x & & \cr \hline} + +% \setlength\parsep{5\p@ \@plus \p@} +% \setlength\parsep{5em} +% \parindent 0em +\setlength\parskip{5pt plus 1pt minus 1pt} +\setlength\parindent{0pt} +% \setlength\parsep{1em} + +\if@titlepage + \renewcommand\maketitle{\begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let \footnote \thanks + \null\vfil + \vskip 60\p@ + \begin{flushright}% + {\LARGE \@title \par}% + \vskip 3em% + {\large + \lineskip .75em% + \begin{tabular}[t]{c}% + \@author + \end{tab... [truncated message content] |