Skip to Content.
Sympa Menu

perfsonar-dev - perfsonar: r4526 - in trunk/rnp_java-cl-mp: . ant conf conf/axis-1.4 conf/axis-1.4/WEB-INF conf/axis-1.4/graphics conf/cron conf/cron/local conf/scripts doc doc/schema lib/misc packaging packaging/deb packaging/rpm samples/requests samples/responses src/main/java/org/perfsonar/service/measurementPoint/commandLine src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils src/main/java/perfSONARWebAdmin/admin/wizard/services

Subject: perfsonar development work

List archive

perfsonar: r4526 - in trunk/rnp_java-cl-mp: . ant conf conf/axis-1.4 conf/axis-1.4/WEB-INF conf/axis-1.4/graphics conf/cron conf/cron/local conf/scripts doc doc/schema lib/misc packaging packaging/deb packaging/rpm samples/requests samples/responses src/main/java/org/perfsonar/service/measurementPoint/commandLine src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils src/main/java/perfSONARWebAdmin/admin/wizard/services


Chronological Thread 
  • From:
  • To:
  • Subject: perfsonar: r4526 - in trunk/rnp_java-cl-mp: . ant conf conf/axis-1.4 conf/axis-1.4/WEB-INF conf/axis-1.4/graphics conf/cron conf/cron/local conf/scripts doc doc/schema lib/misc packaging packaging/deb packaging/rpm samples/requests samples/responses src/main/java/org/perfsonar/service/measurementPoint/commandLine src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils src/main/java/perfSONARWebAdmin/admin/wizard/services
  • Date: Mon, 22 Sep 2008 09:59:51 -0400

Author: fernandes
Date: 2008-09-22 09:59:50 -0400 (Mon, 22 Sep 2008)
New Revision: 4526

Added:
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_fail.gif
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_main.gif
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_return.gif
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_startbn.gif
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_succ.gif
trunk/rnp_java-cl-mp/conf/axis-1.4/testdepl.jsp
trunk/rnp_java-cl-mp/conf/components.properties
trunk/rnp_java-cl-mp/conf/cron/
trunk/rnp_java-cl-mp/conf/cron/clmpcron
trunk/rnp_java-cl-mp/conf/cron/local/
trunk/rnp_java-cl-mp/conf/cron/local/.tmp
trunk/rnp_java-cl-mp/conf/log4j.properties
trunk/rnp_java-cl-mp/conf/log4j.syslog.properties
trunk/rnp_java-cl-mp/conf/scripts/
trunk/rnp_java-cl-mp/conf/scripts/bwctl.sh
trunk/rnp_java-cl-mp/conf/scripts/connectivity.sh
trunk/rnp_java-cl-mp/conf/scripts/daemonbwctl.sh
trunk/rnp_java-cl-mp/conf/scripts/daemonntp.sh
trunk/rnp_java-cl-mp/conf/scripts/daemonowamp.sh
trunk/rnp_java-cl-mp/conf/scripts/dnslookup.sh
trunk/rnp_java-cl-mp/conf/scripts/iperf.sh
trunk/rnp_java-cl-mp/conf/scripts/ntpsynchronized.sh
trunk/rnp_java-cl-mp/conf/scripts/owping.sh
trunk/rnp_java-cl-mp/conf/selfTest-map.xml
trunk/rnp_java-cl-mp/conf/service.properties
trunk/rnp_java-cl-mp/doc/schema/nmtime.rnc
trunk/rnp_java-cl-mp/doc/schema/owampSummaryRequest.rnc
trunk/rnp_java-cl-mp/doc/schema/owampSummaryResponse.rnc
trunk/rnp_java-cl-mp/lib/misc/perfsonar-base-ant-1.0.20080416.jar
trunk/rnp_java-cl-mp/packaging/
trunk/rnp_java-cl-mp/packaging/deb/
trunk/rnp_java-cl-mp/packaging/deb/changelog
trunk/rnp_java-cl-mp/packaging/deb/compat
trunk/rnp_java-cl-mp/packaging/deb/conffiles
trunk/rnp_java-cl-mp/packaging/deb/control
trunk/rnp_java-cl-mp/packaging/deb/copyright
trunk/rnp_java-cl-mp/packaging/deb/dirs
trunk/rnp_java-cl-mp/packaging/deb/docs
trunk/rnp_java-cl-mp/packaging/deb/install
trunk/rnp_java-cl-mp/packaging/deb/postinst
trunk/rnp_java-cl-mp/packaging/deb/postrm
trunk/rnp_java-cl-mp/packaging/deb/preinst
trunk/rnp_java-cl-mp/packaging/deb/prerm
trunk/rnp_java-cl-mp/packaging/deb/rules
trunk/rnp_java-cl-mp/packaging/rpm/
trunk/rnp_java-cl-mp/packaging/rpm/perfsonar-clmp.specs
trunk/rnp_java-cl-mp/pom.xml
trunk/rnp_java-cl-mp/samples/requests/BWCTLTCPRequest.xml
trunk/rnp_java-cl-mp/samples/requests/BWCTLUDPRequest.xml
trunk/rnp_java-cl-mp/samples/requests/OWAMPRequest.xml
trunk/rnp_java-cl-mp/samples/requests/OWAMPSummaryRequest.xml
trunk/rnp_java-cl-mp/samples/requests/PingRequest.xml
trunk/rnp_java-cl-mp/samples/requests/TracerouteRequest.xml
trunk/rnp_java-cl-mp/samples/responses/BWCTLTCPResponse.xml
trunk/rnp_java-cl-mp/samples/responses/BWCTLUDPResponse.xml
trunk/rnp_java-cl-mp/samples/responses/ErrorResponse.xml
trunk/rnp_java-cl-mp/samples/responses/OWAMPResponse.xml
trunk/rnp_java-cl-mp/samples/responses/OWAMPSummaryResponse.xml
trunk/rnp_java-cl-mp/samples/responses/PingResponse.xml
trunk/rnp_java-cl-mp/samples/responses/TracerouteResponse.xml

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineSelfTest.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/OwampSummary.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils/Constants.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils/SelfTestUnit.java
Removed:
trunk/rnp_java-cl-mp/conf/axis-1.4/index.html
trunk/rnp_java-cl-mp/lib/misc/perfsonar-base-ant-1.0.20080331.jar
Modified:
trunk/rnp_java-cl-mp/ant/axis-deploy-targets.xml
trunk/rnp_java-cl-mp/ant/build.xml
trunk/rnp_java-cl-mp/ant/compile-targets.xml
trunk/rnp_java-cl-mp/ant/configure-targets.xml
trunk/rnp_java-cl-mp/ant/const.properties.template
trunk/rnp_java-cl-mp/ant/libs-download-targets.xml
trunk/rnp_java-cl-mp/ant/pre-install-targets.xml
trunk/rnp_java-cl-mp/ant/release-targets.xml
trunk/rnp_java-cl-mp/ant/test-targets.xml
trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/server-config.wsdd
trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/web.xml
trunk/rnp_java-cl-mp/conf/eventType-map.xml
trunk/rnp_java-cl-mp/conf/service.properties.template-2
trunk/rnp_java-cl-mp/conf/wizard.properties
trunk/rnp_java-cl-mp/conf/wizardproperties.dtd
trunk/rnp_java-cl-mp/doc/CLMP Functional Specification.doc
trunk/rnp_java-cl-mp/doc/CLMP Interface Specification.doc
trunk/rnp_java-cl-mp/doc/Changelog.txt
trunk/rnp_java-cl-mp/doc/schema/errorResponse.rnc
trunk/rnp_java-cl-mp/samples/requests/CronAddOwamp.xml
trunk/rnp_java-cl-mp/samples/requests/CronAddPing.xml
trunk/rnp_java-cl-mp/samples/requests/EchoRequest.xml
trunk/rnp_java-cl-mp/samples/requests/LookupInfoRequest.xml
trunk/rnp_java-cl-mp/samples/responses/CronAddPingResponse.xml
trunk/rnp_java-cl-mp/samples/responses/CronListResponse.xml
trunk/rnp_java-cl-mp/samples/responses/CronListSpecificResponse.xml
trunk/rnp_java-cl-mp/samples/responses/CronModifyResponse.xml
trunk/rnp_java-cl-mp/samples/responses/CronRemoveResponse.xml

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineCronComponent.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineMPServiceEngine.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineResourceProtector.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineToolBundleFactory.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Bwctl.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Owamp.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Ping.java

trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Traceroute.java

trunk/rnp_java-cl-mp/src/main/java/perfSONARWebAdmin/admin/wizard/services/CLMPHandler.java
Log:
CL-MP 2.1 RC1

NEW: Added a new eventType for summarized owamp measurements (-M switch),
http://ggf.org/ns/nmwg/tools/owamp/summary/2.0
NEW: SelfTest functionality added. Works modularly - calls external scripts
defined in conf/selfTest-map.xml and expects "success" or "error" on the
first line and the reasons next.
NEW: Log4j properties file for logging to a Syslog server added
Change: Some classes were changed for internal self-testing
(componentsInitialization).
Change: Using nmwg-1.0.20080916, perfsonar-base-1.0.20080902 and
perfsonar-web-admin-0.9.2b

Modified: trunk/rnp_java-cl-mp/ant/axis-deploy-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/axis-deploy-targets.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/axis-deploy-targets.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,306 +1,315 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: axis-deploy-targets.xml 2968 2007-10-16 11:50:42Z roman $
- project: perfSONAR
- date: 2007/06/28
- author: romradz
-
- </description>
-
--->
-
-<project name="axis-deploy-targets"
- basedir="..">
-
-
- <target name="create-deploy-root"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:create-deploy-root deploy-path="${service.home}/${deploy.root}"/>
- <mkdir
dir="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron"/>
- <mkdir
dir="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron/local"/>
- <touch
file="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron/clmpcron"/>
-
- </target>
-
-
- <target name="copy-axis-config"
- depends="create-deploy-root"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:copy-axis-config
dest-conf-path="${service.home}/${deploy.root}"/>
-
- </target>
-
-
- <target name="copy-dep-base-service-jars"
- depends="copy-axis-config"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:copy-dep-base-service-jars
dest-jars-path="${service.home}/${deploy.root}"/>
- </target>
-
-
- <target name="copy-dep-service-jars"
- depends="copy-dep-base-service-jars">
-
- <copy
file="${basedir}/lib/repository/nmwg/nmwg/1.0.20080124/nmwg-1.0.20080124.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
- <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-base/1.0.20080422/perfsonar-base-1.0.20080422.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
- <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-web-admin/0.8.5b/perfsonar-web-admin-0.8.5b.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
-
- <copy file="${basedir}/conf/eventType-map.xml"
todir="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf"/>
-
- <copy file="${basedir}/conf/wsdd/${wsdd.file.deploy}"
todir="${service.home}/${deploy.root}/wsdd"/>
- <copy file="${basedir}/conf/wsdd/${wsdd.file.undeploy}"
todir="${service.home}/${deploy.root}/wsdd"/>
-
- </target>
-
-
- <target name="copy-service-jar" depends="copy-dep-service-jars">
- <copy file="${basedir}/${build}/${jarfilename}-${version}.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
- </target>
-
-
- <target name="delete-deploy-root">
- <delete dir="${service.home}/${deploy.root}"/>
- </target>
-
-
- <target name="tomcat-start"
- xmlns:antcontrib="antlib:net.sf.antcontrib"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:input2 message="Do you want me to start the application server
Tomcat for you?"
- addproperty="tomcat.start"
- validargs="y,n"
- defaultvalue="y" />
-
- <echo>Please, insert now the following xml tag 'Context'</echo>
- <echo>into Tomcat configuration file server.xml</echo>
- <echo>(${tomcat.home}/conf/server.xml)</echo>
- <echo>inside existing xml tag 'Host':</echo>
- <echo></echo>
- <echo message=" &lt;Context path='/${deploy.root}'"/>
- <echo message=" docBase='${service.home}/${deploy.root}'&gt;"/>
- <echo message=" &lt;/Context&gt;"/>
- <echo></echo>
- <input message="Please do it now and press Enter when finished"/>
-
- <antcontrib:if>
- <equals arg1="${tomcat.start}" arg2="y" />
- <antcontrib:then>
-
- <exec dir="${tomcat.home}/bin"
- executable="sh">
- <arg line="startup.sh"/>
- <env key="PATH"
path="${env.PATH}:/bin:/usr/bin:/sbin:/usr/sbin:${tomcat.home}/bin:."/>
- <env key="CATALINA_HOME" path=""/>
- <env key="CATALINA_BASE" path=""/>
- </exec>
-
- <echo>Please, make sure that Tomcat is running.</echo>
- <echo>You can do it using your web browser and connect the address
http://${target.server}:${target.port}</echo>
- <echo>or looking at Tomcat's log file
(${tomcat.home}/logs/catalina.out).</echo>
- <echo></echo>
- <input message="Please do it now and press Enter when finished"/>
-
- </antcontrib:then>
- </antcontrib:if>
-
- </target>
-
-
- <target name="tomcat-shutdown"
- xmlns:antcontrib="antlib:net.sf.antcontrib"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:input2 message="Do you want me to shutdown the application
server Tomcat for you?"
- addproperty="tomcat.shutdown"
- validargs="y,n"
- defaultvalue="y" />
-
- <antcontrib:if>
- <equals arg1="${tomcat.shutdown}" arg2="y" />
- <antcontrib:then>
- <psbase:tomcat-shutdown tomcat-path="${tomcat.home}"/>
- </antcontrib:then>
- </antcontrib:if>
-
- </target>
-
-
- <target name="deploy-adminclient-introinfo">
-
- <echo></echo>
- <echo>perfSONAR service located in the directory</echo>
- <echo>${service.home}/${deploy.root}</echo>
- <echo>will be now installed in Tomcat.</echo>
- <echo></echo>
- <input message="Press Enter"/>
-
- </target>
-
-
- <path id="axis.classpath">
- <fileset dir="${basedir}/lib/repository">
- <include name="**/*.jar"/>
- </fileset>
- </path>
-
- <property name="adminService"
value="http://${target.server}:${target.port}/${deploy.root}/services/AdminService";
/>
- <property name="deployFile"
value="${service.home}/${deploy.root}/wsdd/${wsdd.file.deploy}" />
- <property name="undeployFile"
value="${service.home}/${deploy.root}/wsdd/${wsdd.file.undeploy}" />
-
- <target name="deploy-adminclient"
- depends="deploy-adminclient-introinfo"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:deploy-adminclient admin-service="${adminService}"
- deploy-file="${deployFile}"/>
-
- </target>
-
-
- <target name="undeploy-adminclient-introinfo">
-
- <echo></echo>
- <echo>perfSONAR service located in the directory</echo>
- <echo>${service.home}/${deploy.root}</echo>
- <echo>will be now uninstalled in Tomcat.</echo>
- <echo></echo>
- <input message="Press Enter"/>
-
- </target>
-
-
- <target name="undeploy-adminclient"
- depends="undeploy-adminclient-introinfo"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:undeploy-adminclient admin-service="${adminService}"
- undeploy-file="${undeployFile}"/>
-
- </target>
-
-
- <target name="start">
- <property file="${basedir}/ant/const.properties"/>
- <antcall target="deploy-adminclient" />
- </target>
-
-
- <target name="stop">
- <property file="${basedir}/ant/const.properties"/>
- <antcall target="undeploy-adminclient" />
- </target>
-
- <!--
===================================================================================
-->
- <!-- targets for web admin installation stuff -->
-
- <!-- it is assumed that the installation location is
/home/perfsonar directory (user) -->
-
-
- <property name="tmpdir" value="tmp" />
-
- <target name="webapp-directory-prepare"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <delete dir="${tmpdir}"/>
- <delete dir="${tmpdir}-webapps"/>
- <mkdir dir="${tmpdir}"/>
-
-
- <copy file="${basedir}/conf/service.properties.template-2"
tofile="${basedir}/conf/service.properties"/>
- <copy file="${basedir}/conf/components.properties.template"
tofile="${basedir}/conf/components.properties"/>
- <copy file="${basedir}/conf/log4j.properties.template"
tofile="${basedir}/conf/log4j.properties"/>
-
- <copy file="${basedir}/${build}/${jarfilename}-${version}.jar"
todir="${tmpdir}/WEB-INF/lib"/>
-
- <copy
file="${basedir}/lib/repository/nmwg/nmwg/1.0.20080124/nmwg-1.0.20080124.jar"
todir="${tmpdir}/WEB-INF/lib"/>
- <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-base/1.0.20080422/perfsonar-base-1.0.20080422.jar"
todir="${tmpdir}/WEB-INF/lib"/>
- <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-web-admin/0.8.5b/perfsonar-web-admin-0.8.5b.jar"
todir="${tmpdir}/WEB-INF/lib"/>
-
- <copy file="${basedir}/conf/eventType-map.xml"
todir="${tmpdir}/WEB-INF/classes/perfsonar/conf"/>
-
- <copy file="${basedir}/conf/wsdd/${wsdd.file.deploy}"
todir="${tmpdir}/wsdd"/>
- <copy file="${basedir}/conf/wsdd/${wsdd.file.undeploy}"
todir="${tmpdir}/wsdd"/>
-
- <psbase:copy-dep-base-service-jars dest-jars-path="${tmpdir}"/>
- <psbase:copy-axis-config dest-conf-path="${tmpdir}"/>
-
- <copy file="${basedir}/conf/axis-1.4/WEB-INF/server-config.wsdd"
todir="${tmpdir}/WEB-INF"/>
-
- <replace
file="${tmpdir}/WEB-INF/classes/perfsonar/conf/wizard.properties"
- token="__BASEPATH__"
- value="/opt/perfsonar/services/perfsonar-clmp/WEB-INF" />
-
- <replace
file="${tmpdir}/WEB-INF/classes/perfsonar/conf/log4j.properties"
- token="_LOGPATH_"
-
value="/opt/perfsonar/services/perfsonar-clmp/WEB-INF/logs"/>
-
-
- <mkdir dir="${tmpdir}/WEB-INF/logs"/>
-
- <mkdir dir="${tmpdir}/WEB-INF/classes/perfsonar/cron"/>
- <mkdir dir="${tmpdir}/WEB-INF/classes/perfsonar/cron/local"/>
- <touch
file="${tmpdir}/WEB-INF/classes/perfsonar/cron/clmpcron"/>
-
- </target>
-
-
-
- <target name="war-create"
- depends="webapp-directory-prepare">
-
- <zip destfile="${service.name}-${version}.war"
- basedir="${tmpdir}/"
- excludes=".svn/**" />
-
- <delete dir="${tmpdir}"/>
-
- </target>
-
-
- <target name="webapp-create"
- xmlns:psbase="psbase:/base.perfsonar.org"
- depends="webapp-directory-prepare">
-
- <move
todir="${tmpdir}-webapps/webapps/${service.name}-${version}">
- <fileset dir="${tmpdir}"/>
- </move>
-
- </target>
-
-
- <!--
===================================================================================
-->
- <!-- main targets -->
-
-
- <target name="deploy"
- xmlns:antcontrib="antlib:net.sf.antcontrib">
-
- <property file="${basedir}/ant/const.properties"/>
-
- <antcall target="copy-service-jar"/>
- <antcall target="tomcat-start"/>
- <antcall target="deploy-adminclient" />
-
- </target>
-
-
- <target name="undeploy">
-
- <property file="${basedir}/ant/const.properties"/>
-
- <antcall target="undeploy-adminclient" />
- <antcall target="delete-deploy-root"/>
- <antcall target="tomcat-shutdown"/>
-
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: axis-deploy-targets.xml 2968 2007-10-16 11:50:42Z roman $
+ project: perfSONAR
+ date: 2007/06/28
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="axis-deploy-targets"
+ basedir="..">
+
+
+ <target name="create-deploy-root"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:create-deploy-root deploy-path="${service.home}/${deploy.root}"/>
+
+ </target>
+
+
+ <target name="copy-axis-config"
+ depends="create-deploy-root"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:copy-axis-config
dest-conf-path="${service.home}/${deploy.root}"/>
+
+ </target>
+
+
+ <target name="copy-dep-base-service-jars"
+ depends="copy-axis-config"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:copy-dep-base-service-jars
dest-jars-path="${service.home}/${deploy.root}"/>
+ </target>
+
+
+ <target name="copy-dep-service-jars"
+ depends="copy-dep-base-service-jars">
+
+ <copy
file="${basedir}/lib/repository/nmwg/nmwg/1.0.20080916/nmwg-1.0.20080916.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
+ <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-base/1.0.20080902/perfsonar-base-1.0.20080902.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
+ <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-web-admin/0.9.2b/perfsonar-web-admin-0.9.2b.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
+
+ <copy file="${basedir}/conf/eventType-map.xml"
todir="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf"/>
+ <copy file="${basedir}/conf/selfTest-map.xml"
todir="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf"/>
+
+ <copy todir="${tmpdir}/WEB-INF/classes/perfsonar/scripts">
+ <fileset dir="${basedir}/conf/scripts"/>
+ </copy>
+
+ <copy todir="${tmpdir}/WEB-INF/classes/perfsonar/cron">
+ <fileset dir="${basedir}/conf/cron"/>
+ </copy>
+
+ <copy file="${basedir}/conf/wsdd/${wsdd.file.deploy}"
todir="${service.home}/${deploy.root}/wsdd"/>
+ <copy file="${basedir}/conf/wsdd/${wsdd.file.undeploy}"
todir="${service.home}/${deploy.root}/wsdd"/>
+
+ </target>
+
+
+ <target name="copy-service-jar" depends="copy-dep-service-jars">
+ <copy file="${basedir}/${build}/${jarfilename}-${version}.jar"
todir="${service.home}/${deploy.root}/WEB-INF/lib"/>
+ </target>
+
+
+ <target name="delete-deploy-root">
+ <delete dir="${service.home}/${deploy.root}"/>
+ </target>
+
+
+ <target name="tomcat-start"
+ xmlns:antcontrib="antlib:net.sf.antcontrib"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:input2 message="Do you want me to start the application server
Tomcat for you?"
+ addproperty="tomcat.start"
+ validargs="y,n"
+ defaultvalue="y" />
+
+ <echo>Please, insert now the following xml tag 'Context'</echo>
+ <echo>into Tomcat configuration file server.xml</echo>
+ <echo>(${tomcat.home}/conf/server.xml)</echo>
+ <echo>inside existing xml tag 'Host':</echo>
+ <echo></echo>
+ <echo message=" &lt;Context path='/${deploy.root}'"/>
+ <echo message=" docBase='${service.home}/${deploy.root}'&gt;"/>
+ <echo message=" &lt;/Context&gt;"/>
+ <echo></echo>
+ <input message="Please do it now and press Enter when finished"/>
+
+ <antcontrib:if>
+ <equals arg1="${tomcat.start}" arg2="y" />
+ <antcontrib:then>
+
+ <exec dir="${tomcat.home}/bin"
+ executable="sh">
+ <arg line="startup.sh"/>
+ <env key="PATH"
path="${env.PATH}:/bin:/usr/bin:/sbin:/usr/sbin:${tomcat.home}/bin:."/>
+ <env key="CATALINA_HOME" path=""/>
+ <env key="CATALINA_BASE" path=""/>
+ </exec>
+
+ <echo>Please, make sure that Tomcat is running.</echo>
+ <echo>You can do it using your web browser and connect the address
http://${target.server}:${target.port}</echo>
+ <echo>or looking at Tomcat's log file
(${tomcat.home}/logs/catalina.out).</echo>
+ <echo></echo>
+ <input message="Please do it now and press Enter when finished"/>
+
+ </antcontrib:then>
+ </antcontrib:if>
+
+ </target>
+
+
+ <target name="tomcat-shutdown"
+ xmlns:antcontrib="antlib:net.sf.antcontrib"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:input2 message="Do you want me to shutdown the application
server Tomcat for you?"
+ addproperty="tomcat.shutdown"
+ validargs="y,n"
+ defaultvalue="y" />
+
+ <antcontrib:if>
+ <equals arg1="${tomcat.shutdown}" arg2="y" />
+ <antcontrib:then>
+ <psbase:tomcat-shutdown tomcat-path="${tomcat.home}"/>
+ </antcontrib:then>
+ </antcontrib:if>
+
+ </target>
+
+
+ <target name="deploy-adminclient-introinfo">
+
+ <echo></echo>
+ <echo>perfSONAR service located in the directory</echo>
+ <echo>${service.home}/${deploy.root}</echo>
+ <echo>will be now installed in Tomcat.</echo>
+ <echo></echo>
+ <input message="Press Enter"/>
+
+ </target>
+
+
+ <path id="axis.classpath">
+ <fileset dir="${basedir}/lib/repository">
+ <include name="**/*.jar"/>
+ </fileset>
+ </path>
+
+ <property name="adminService"
value="http://${target.server}:${target.port}/${deploy.root}/services/AdminService";
/>
+ <property name="deployFile"
value="${service.home}/${deploy.root}/wsdd/${wsdd.file.deploy}" />
+ <property name="undeployFile"
value="${service.home}/${deploy.root}/wsdd/${wsdd.file.undeploy}" />
+
+ <target name="deploy-adminclient"
+ depends="deploy-adminclient-introinfo"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:deploy-adminclient admin-service="${adminService}"
+ deploy-file="${deployFile}"/>
+
+ </target>
+
+
+ <target name="undeploy-adminclient-introinfo">
+
+ <echo></echo>
+ <echo>perfSONAR service located in the directory</echo>
+ <echo>${service.home}/${deploy.root}</echo>
+ <echo>will be now uninstalled in Tomcat.</echo>
+ <echo></echo>
+ <input message="Press Enter"/>
+
+ </target>
+
+
+ <target name="undeploy-adminclient"
+ depends="undeploy-adminclient-introinfo"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:undeploy-adminclient admin-service="${adminService}"
+ undeploy-file="${undeployFile}"/>
+
+ </target>
+
+
+ <target name="start">
+ <property file="${basedir}/ant/const.properties"/>
+ <antcall target="deploy-adminclient" />
+ </target>
+
+
+ <target name="stop">
+ <property file="${basedir}/ant/const.properties"/>
+ <antcall target="undeploy-adminclient" />
+ </target>
+
+ <!--
===================================================================================
-->
+ <!-- targets for web admin installation stuff -->
+
+ <!-- it is assumed that the installation location is
/home/perfsonar directory (user) -->
+
+
+ <property name="tmpdir" value="tmp" />
+
+ <target name="webapp-directory-prepare"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <delete dir="${tmpdir}"/>
+ <delete dir="${tmpdir}-webapps"/>
+ <mkdir dir="${tmpdir}"/>
+
+
+ <copy file="${basedir}/conf/service.properties.template-2"
tofile="${basedir}/conf/service.properties"/>
+ <copy file="${basedir}/conf/components.properties.template"
tofile="${basedir}/conf/components.properties"/>
+ <copy file="${basedir}/conf/log4j.properties.template"
tofile="${basedir}/conf/log4j.properties"/>
+
+ <copy file="${basedir}/${build}/${jarfilename}-${version}.jar"
todir="${tmpdir}/WEB-INF/lib"/>
+
+ <copy
file="${basedir}/lib/repository/nmwg/nmwg/1.0.20080916/nmwg-1.0.20080916.jar"
todir="${tmpdir}/WEB-INF/lib"/>
+ <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-base/1.0.20080902/perfsonar-base-1.0.20080902.jar"
todir="${tmpdir}/WEB-INF/lib"/>
+ <copy
file="${basedir}/lib/repository/perfsonar/perfsonar-web-admin/0.9.2b/perfsonar-web-admin-0.9.2b.jar"
todir="${tmpdir}/WEB-INF/lib"/>
+
+ <copy file="${basedir}/conf/eventType-map.xml"
todir="${tmpdir}/WEB-INF/classes/perfsonar/conf"/>
+ <copy file="${basedir}/conf/selfTest-map.xml"
todir="${tmpdir}/WEB-INF/classes/perfsonar/conf"/>
+
+ <copy todir="${tmpdir}/WEB-INF/classes/perfsonar/scripts">
+ <fileset dir="${basedir}/conf/scripts"/>
+ </copy>
+
+ <copy todir="${tmpdir}/WEB-INF/classes/perfsonar/cron">
+ <fileset dir="${basedir}/conf/cron"/>
+ </copy>
+
+ <copy file="${basedir}/conf/wsdd/${wsdd.file.deploy}"
todir="${tmpdir}/wsdd"/>
+ <copy file="${basedir}/conf/wsdd/${wsdd.file.undeploy}"
todir="${tmpdir}/wsdd"/>
+
+ <psbase:copy-dep-base-service-jars dest-jars-path="${tmpdir}"/>
+ <psbase:copy-axis-config dest-conf-path="${tmpdir}"/>
+
+ <copy file="${basedir}/conf/axis-1.4/WEB-INF/server-config.wsdd"
todir="${tmpdir}/WEB-INF"/>
+
+ <replace
file="${tmpdir}/WEB-INF/classes/perfsonar/conf/wizard.properties"
+ token="__BASEPATH__"
+
value="/opt/perfsonar/tomcat/webapps/perfsonar-clmp/WEB-INF" />
+
+ <replace
file="${tmpdir}/WEB-INF/classes/perfsonar/conf/log4j.properties"
+ token="_LOGPATH_"
+
value="/opt/perfsonar/tomcat/webapps/perfsonar-clmp/WEB-INF/logs"/>
+
+ <mkdir dir="${tmpdir}/WEB-INF/logs"/>
+ </target>
+
+
+
+ <target name="war-create"
+ depends="webapp-directory-prepare">
+
+ <zip destfile="${service.name}-${version}.war"
+ basedir="${tmpdir}/"
+ excludes=".svn/**" />
+
+ <delete dir="${tmpdir}"/>
+
+ </target>
+
+
+ <target name="webapp-create"
+ xmlns:psbase="psbase:/base.perfsonar.org"
+ depends="webapp-directory-prepare">
+
+ <move
todir="${tmpdir}-webapps/webapps/${service.name}-${version}">
+ <fileset dir="${tmpdir}"/>
+ </move>
+
+ </target>
+
+
+ <!--
===================================================================================
-->
+ <!-- main targets -->
+
+
+ <target name="deploy"
+ xmlns:antcontrib="antlib:net.sf.antcontrib">
+
+ <property file="${basedir}/ant/const.properties"/>
+
+ <antcall target="copy-service-jar"/>
+ <antcall target="tomcat-start"/>
+ <antcall target="deploy-adminclient" />
+
+ </target>
+
+
+ <target name="undeploy">
+
+ <property file="${basedir}/ant/const.properties"/>
+
+ <antcall target="undeploy-adminclient" />
+ <antcall target="delete-deploy-root"/>
+ <antcall target="tomcat-shutdown"/>
+
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/ant/build.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/build.xml 2008-09-22 12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/build.xml 2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,45 +1,45 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: build.xml 2647 2007-08-14 11:05:30Z roman $
- project: perfSONAR
- date: 2007/06/15
- author: romradz
-
- </description>
-
--->
-
-<project name="geant2_java-rrd-ma"
- basedir="..">
-
-
- <property file="${basedir}/ant/const.properties.template"/>
-
-
- <taskdef resource="net/sf/antcontrib/antlib.xml"
- uri="antlib:net.sf.antcontrib">
- <classpath>
- <pathelement location="${antcontrib.jar}"/>
- </classpath>
- </taskdef>
-
- <taskdef resource="org/perfsonar/base/ant/antlib.xml"
- classpath="${antpsbase.jar}"
- uri="psbase:/base.perfsonar.org"/>
-
-
-
- <import file="libs-download-targets.xml"/>
- <import file="compile-targets.xml"/>
- <import file="pre-install-targets.xml"/>
- <import file="configure-targets.xml"/>
- <import file="axis-deploy-targets.xml"/>
- <import file="test-targets.xml"/>
- <import file="release-targets.xml"/>
-
-
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: build.xml 2647 2007-08-14 11:05:30Z roman $
+ project: perfSONAR
+ date: 2007/06/15
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="geant2_java-rrd-ma"
+ basedir="..">
+
+
+ <property file="${basedir}/ant/const.properties.template"/>
+
+
+ <taskdef resource="net/sf/antcontrib/antlib.xml"
+ uri="antlib:net.sf.antcontrib">
+ <classpath>
+ <pathelement location="${antcontrib.jar}"/>
+ </classpath>
+ </taskdef>
+
+ <taskdef resource="org/perfsonar/base/ant/antlib.xml"
+ classpath="${antpsbase.jar}"
+ uri="psbase:/base.perfsonar.org"/>
+
+
+
+ <import file="libs-download-targets.xml"/>
+ <import file="compile-targets.xml"/>
+ <import file="pre-install-targets.xml"/>
+ <import file="configure-targets.xml"/>
+ <import file="axis-deploy-targets.xml"/>
+ <import file="test-targets.xml"/>
+ <import file="release-targets.xml"/>
+
+
</project>
\ No newline at end of file

Modified: trunk/rnp_java-cl-mp/ant/compile-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/compile-targets.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/compile-targets.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,53 +1,53 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: compile-targets.xml 2695 2007-08-22 09:18:20Z roman $
- project: perfSONAR
- date: 2007/06/15
- author: romradz
-
- </description>
-
--->
-
-<project name="compile-targets"
- basedir="..">
-
-
- <target name="compile"
- xmlns:antcontrib="antlib:net.sf.antcontrib"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <property name="conf.file" value="${basedir}/ant/const.properties"/>
- <available file="${conf.file}" property="conf.file.present"/>
- <antcontrib:if>
- <isset property="conf.file.present"/>
- <antcontrib:then>
- <psbase:compile srcdir="src" dstdir="${build}"
libdir="lib/repository"/>
- </antcontrib:then>
- <antcontrib:else>
- <psbase:template-use template-file="ant/const.properties.template"
- dest-file="ant/const.properties"/>
- <property file="${basedir}/ant/const.properties"/>
- <psbase:compile srcdir="src" dstdir="${build}"
libdir="lib/repository"/>
- </antcontrib:else>
- </antcontrib:if>
-
- </target>
-
-
- <target name="jar"
- depends="compile"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:jar jarfile="${jarfilename}-${version}.jar"
- dstdir="${build}"
- classdir="${build}"/>
-
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: compile-targets.xml 2695 2007-08-22 09:18:20Z roman $
+ project: perfSONAR
+ date: 2007/06/15
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="compile-targets"
+ basedir="..">
+
+
+ <target name="compile"
+ xmlns:antcontrib="antlib:net.sf.antcontrib"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <property name="conf.file" value="${basedir}/ant/const.properties"/>
+ <available file="${conf.file}" property="conf.file.present"/>
+ <antcontrib:if>
+ <isset property="conf.file.present"/>
+ <antcontrib:then>
+ <psbase:compile srcdir="src" dstdir="${build}"
libdir="lib/repository"/>
+ </antcontrib:then>
+ <antcontrib:else>
+ <psbase:template-use template-file="ant/const.properties.template"
+ dest-file="ant/const.properties"/>
+ <property file="${basedir}/ant/const.properties"/>
+ <psbase:compile srcdir="src" dstdir="${build}"
libdir="lib/repository"/>
+ </antcontrib:else>
+ </antcontrib:if>
+
+ </target>
+
+
+ <target name="jar"
+ depends="compile"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:jar jarfile="${jarfilename}-${version}.jar"
+ dstdir="${build}"
+ classdir="${build}"/>
+
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/ant/configure-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/configure-targets.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/configure-targets.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,159 +1,160 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: configure-targets.xml 2693 2007-08-22 09:09:39Z roman $
- project: perfSONAR
- date: 2007/06/22
- author: romradz
-
- </description>
-
--->
-
-<project name="configure-targets"
- basedir="..">
-
-
- <!--
===================================================================================
-->
- <!-- getting metadata configuration -->
-
-
-
- <target name="register-fuctionality"
- xmlns:psbase="psbase:/base.perfsonar.org">
- <psbase:register-fuctionality
dest-config-file="conf/service.properties"/>
- </target>
-
-
- <target name="mp-register-fuctionality"
- depends="register-fuctionality"
- xmlns:antcontrib="antlib:net.sf.antcontrib">
-
- <antcontrib:if>
- <equals arg1="${functionality.register}" arg2="y" />
- <antcontrib:then>
-
- <propertyfile file="${basedir}/conf/service.properties">
- <entry key="service.r.service_type"
value="mp"/>
- <entry key="component.registrator.scheduler_component"
value="scheduler"/>
- </propertyfile>
-
- <replace file="${basedir}/conf/components.properties"
-
token="#registrator=org.perfsonar.service.base.registration.LSRegistrationComponent"
-
value="registrator=org.perfsonar.service.base.registration.LSRegistrationComponent"/>
-
- </antcontrib:then>
- </antcontrib:if>
-
- </target>
-
-
- <target name="set-service-properties">
- <propertyfile file="${basedir}/conf/service.properties">
-
- <entry key="service.sax_parser.config"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/objects.config"/>
- <entry key="service.log.log4j.config"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/log4j.properties"/>
-
- <!-- for LookupInfoRequest message -->
- <entry key="service.r.service_type" value="mp"/>
- <entry key="service.r.service_name" value="${service.name}"/>
- <entry key="service.r.service_version" value="${version}"/>
-
- <!-- CL-MP specific -->
- <entry key="service.clmp.tools_map"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/eventType-map.xml"/>
- <entry key="service.clmp.cron_dir"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron"/>
- <entry key="service.clmp.cron.local_storage_dir"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron"/>
-
- </propertyfile>
- </target>
-
- <target name="resource-protection-for-clmp"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <echo>CL-MP implements simple resource protection by limiting</echo>
- <echo>the number of concurrent processes of a specific tool.</echo>
- <echo>This only applies to a particular tool, being the tools</echo>
- <echo>independent of each other. If you don't want any limits,</echo>
- <echo>hit enter to accept the default.</echo>
- <echo></echo>
- <echo></echo>
- <psbase:input2 message="How many concurrent ping measurements do you
want?"
- addproperty="ping"
- defaultvalue="99999"/>
- <psbase:input2 message="How many concurrent traceroute measurements
do you want?"
- addproperty="traceroute"
- defaultvalue="99999"/>
- <psbase:input2 message="How many concurrent OWAMP measurements do
you want?"
- addproperty="owamp"
- defaultvalue="99999"/>
- <psbase:input2 message="How many concurrent BWCTL measurements do
you want?"
- addproperty="bwctl"
- defaultvalue="99999"/>
-
- <propertyfile file="conf/service.properties"
- comment="This file was created by the Ant configuration script.">
-
- <entry key="service.clmp.rp.maxthreads.ping" value="${ping}"/>
- <entry key="service.clmp.rp.maxthreads.traceroute"
value="${traceroute}"/>
- <entry key="service.clmp.rp.maxthreads.owping"
value="${owamp}"/>
- <entry key="service.clmp.rp.maxthreads.bwctl" value="${bwctl}"/>
-
- </propertyfile>
-
- </target>
-
- <target name="measurement-scheduling-for-clmp"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <echo>CL-MP permits the scheduling of measurements. When a</echo>
- <echo>scheduled test is made, CL-MP can send the results to</echo>
- <echo>be stored in a SQL-MA or store them locally as an xml</echo>
- <echo>file. If no "ma" parameter is given when a measurement</echo>
- <echo>is scheduled, CL-MP uses the default MA configured.</echo>
- <echo></echo>
- <echo></echo>
- <psbase:input2 message="What would you like to be the default MA?"
- addproperty="ma"
- defaultvalue="local"/>
-
- <propertyfile file="conf/service.properties"
- comment="This file was created by the Ant configuration script.">
-
- <entry key="service.clmp.default_ma" value="${ma}"/>
-
- </propertyfile>
-
- </target>
- <!--
===================================================================================
-->
- <!-- main target -->
-
-
- <target name="configure"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <property file="${basedir}/ant/const.properties"/>
-
- <psbase:template-use template-file="conf/components.properties.template"
- dest-file="conf/components.properties"/>
-
- <property file="const.properties"/>
- <psbase:set-log4j-config template-file="conf/log4j.properties.template"
- dest-file="conf/log4j.properties"
- service-home="${service.home}"
- deploy-root="${deploy.root}"/>
-
- <antcall target="mp-register-fuctionality"/>
-
- <antcall target="set-service-properties"/>
- <antcall target="resource-protection-for-clmp"/>
- <antcall target="measurement-scheduling-for-clmp"/>
-
- <psbase:set-service-descr-email-organization
dest-config-file="conf/service.properties"/>
-
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: configure-targets.xml 2693 2007-08-22 09:09:39Z roman $
+ project: perfSONAR
+ date: 2007/06/22
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="configure-targets"
+ basedir="..">
+
+
+ <!--
===================================================================================
-->
+ <!-- getting metadata configuration -->
+
+
+
+ <target name="register-fuctionality"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+ <psbase:register-fuctionality
dest-config-file="conf/service.properties"/>
+ </target>
+
+
+ <target name="mp-register-fuctionality"
+ depends="register-fuctionality"
+ xmlns:antcontrib="antlib:net.sf.antcontrib">
+
+ <antcontrib:if>
+ <equals arg1="${functionality.register}" arg2="y" />
+ <antcontrib:then>
+
+ <propertyfile file="${basedir}/conf/service.properties">
+ <entry key="service.r.service_type"
value="mp"/>
+ <entry key="component.registrator.scheduler_component"
value="scheduler"/>
+ </propertyfile>
+
+ <replace file="${basedir}/conf/components.properties"
+
token="#registrator=org.perfsonar.service.base.registration.LSRegistrationComponent"
+
value="registrator=org.perfsonar.service.base.registration.LSRegistrationComponent"/>
+
+ </antcontrib:then>
+ </antcontrib:if>
+
+ </target>
+
+
+ <target name="set-service-properties">
+ <propertyfile file="${basedir}/conf/service.properties">
+
+ <entry key="service.sax_parser.config"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/objects.config"/>
+ <entry key="service.log.log4j.config"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/log4j.properties"/>
+
+ <!-- for LookupInfoRequest message -->
+ <entry key="service.r.service_type" value="mp"/>
+ <entry key="service.r.service_name" value="${service.name}"/>
+ <entry key="service.r.service_version" value="${version}"/>
+
+ <!-- CL-MP specific -->
+ <entry key="service.clmp.tools_map"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/eventType-map.xml"/>
+ <entry key="service.clmp.selftest_map"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/conf/selfTest-map.xml"/>
+ <entry key="service.clmp.cron_dir"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron"/>
+ <entry key="service.clmp.cron.local_storage_dir"
value="${service.home}/${deploy.root}/WEB-INF/classes/perfsonar/cron"/>
+
+ </propertyfile>
+ </target>
+
+ <target name="resource-protection-for-clmp"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <echo>CL-MP implements simple resource protection by limiting</echo>
+ <echo>the number of concurrent processes of a specific tool.</echo>
+ <echo>This only applies to a particular tool, being the tools</echo>
+ <echo>independent of each other. If you don't want any limits,</echo>
+ <echo>hit enter to accept the default.</echo>
+ <echo></echo>
+ <echo></echo>
+ <psbase:input2 message="How many concurrent ping measurements do you
want?"
+ addproperty="ping"
+ defaultvalue="99999"/>
+ <psbase:input2 message="How many concurrent traceroute measurements
do you want?"
+ addproperty="traceroute"
+ defaultvalue="99999"/>
+ <psbase:input2 message="How many concurrent OWAMP measurements do
you want?"
+ addproperty="owamp"
+ defaultvalue="99999"/>
+ <psbase:input2 message="How many concurrent BWCTL measurements do
you want?"
+ addproperty="bwctl"
+ defaultvalue="99999"/>
+
+ <propertyfile file="conf/service.properties"
+ comment="This file was created by the Ant configuration script.">
+
+ <entry key="service.clmp.rp.maxthreads.ping" value="${ping}"/>
+ <entry key="service.clmp.rp.maxthreads.traceroute"
value="${traceroute}"/>
+ <entry key="service.clmp.rp.maxthreads.owping"
value="${owamp}"/>
+ <entry key="service.clmp.rp.maxthreads.bwctl" value="${bwctl}"/>
+
+ </propertyfile>
+
+ </target>
+
+ <target name="measurement-scheduling-for-clmp"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <echo>CL-MP permits the scheduling of measurements. When a</echo>
+ <echo>scheduled test is made, CL-MP can send the results to</echo>
+ <echo>be stored in a SQL-MA or store them locally as an xml</echo>
+ <echo>file. If no "ma" parameter is given when a measurement</echo>
+ <echo>is scheduled, CL-MP uses the default MA configured.</echo>
+ <echo></echo>
+ <echo></echo>
+ <psbase:input2 message="What would you like to be the default MA?"
+ addproperty="ma"
+ defaultvalue="local"/>
+
+ <propertyfile file="conf/service.properties"
+ comment="This file was created by the Ant configuration script.">
+
+ <entry key="service.clmp.default_ma" value="${ma}"/>
+
+ </propertyfile>
+
+ </target>
+ <!--
===================================================================================
-->
+ <!-- main target -->
+
+
+ <target name="configure"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <property file="${basedir}/ant/const.properties"/>
+
+ <psbase:template-use template-file="conf/components.properties.template"
+ dest-file="conf/components.properties"/>
+
+ <property file="const.properties"/>
+ <psbase:set-log4j-config template-file="conf/log4j.properties.template"
+ dest-file="conf/log4j.properties"
+ service-home="${service.home}"
+ deploy-root="${deploy.root}"/>
+
+ <antcall target="mp-register-fuctionality"/>
+
+ <antcall target="set-service-properties"/>
+ <antcall target="resource-protection-for-clmp"/>
+ <antcall target="measurement-scheduling-for-clmp"/>
+
+ <psbase:set-service-descr-email-organization
dest-config-file="conf/service.properties"/>
+
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/ant/const.properties.template
===================================================================
--- trunk/rnp_java-cl-mp/ant/const.properties.template 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/const.properties.template 2008-09-22 13:59:50
UTC (rev 4526)
@@ -8,17 +8,17 @@

target.server=127.0.0.1

-service.name=perfSONAR-CLMP
+service.name=perfsonar-clmp

jarfilename=perfsonar-clmp
-version=2.0
+version=2.1

wsdd.file.deploy=service-deploy.wsdd
wsdd.file.undeploy=service-undeploy.wsdd
wsdd.webservice.name=CommandLineService

antcontrib.jar=${basedir}/lib/misc/ant-contrib-1.0b3.jar
-antpsbase.jar=${basedir}/lib/misc/perfsonar-base-ant-1.0.20080331.jar
+antpsbase.jar=${basedir}/lib/misc/perfsonar-base-ant-1.0.20080416.jar

api.location=doc/api
api.title=perfSONAR

Modified: trunk/rnp_java-cl-mp/ant/libs-download-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/libs-download-targets.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/libs-download-targets.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,77 +1,77 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: libs-download-targets.xml 2964 2007-10-16 11:22:18Z roman $
- project: perfSONAR
- date: 2007/06/15
- author: romradz
-
- </description>
-
--->
-
-<project name="libs-download-targets"
- basedir="..">
-
-
- <property name="maven.jar"
value="${basedir}/lib/misc/maven-artifact-ant-2.0.4-dep.jar"/>
-
-
- <target name="init-urnmaven">
-
- <path id="maven.classpath">
- <pathelement location="${maven.jar}" />
- </path>
- <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
- uri="urn:maven-artifact-ant">
- <classpath refid="maven.classpath"/>
- </typedef>
-
- </target>
-
-
- <target name="init-lib-dependencies"
- depends="init-urnmaven"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:init-lib-dependencies
- localRepositoryPath="lib/repository"
-
remoteRepositoryUri1="http://anonsvn.internet2.edu/svn/perfsonar/trunk/jar-repository/";
- remoteRepositoryUri2="http://www.ibiblio.org/maven2"/>
-
- </target>
-
-
- <target name="service-lib-dependencies"
- depends="init-lib-dependencies"
- xmlns:artifact="urn:maven-artifact-ant"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:lib-dependencies/>
-
- <artifact:dependencies>
-
- <dependency groupId="perfsonar" artifactId="perfsonar-base"
version="1.0.20080422"/>
- <dependency groupId="nmwg" artifactId="nmwg"
version="1.0.20080124"/>
- <dependency groupId="perfsonar" artifactId="perfsonar-web-admin"
version="0.8.5b"/>
-
- <localRepository refid="local.repository"/>
- <remoteRepository refid="remote.repository"/>
-
- </artifact:dependencies>
- </target>
-
-
- <!--
===================================================================================
-->
- <!-- main target -->
-
-
- <target name="lib"
- depends="service-lib-dependencies">
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: libs-download-targets.xml 2964 2007-10-16 11:22:18Z roman $
+ project: perfSONAR
+ date: 2007/06/15
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="libs-download-targets"
+ basedir="..">
+
+
+ <property name="maven.jar"
value="${basedir}/lib/misc/maven-artifact-ant-2.0.4-dep.jar"/>
+
+
+ <target name="init-urnmaven">
+
+ <path id="maven.classpath">
+ <pathelement location="${maven.jar}" />
+ </path>
+ <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
+ uri="urn:maven-artifact-ant">
+ <classpath refid="maven.classpath"/>
+ </typedef>
+
+ </target>
+
+
+ <target name="init-lib-dependencies"
+ depends="init-urnmaven"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:init-lib-dependencies
+ localRepositoryPath="lib/repository"
+
remoteRepositoryUri1="http://anonsvn.internet2.edu/svn/perfsonar/trunk/jar-repository/";
+ remoteRepositoryUri2="http://www.ibiblio.org/maven2"/>
+
+ </target>
+
+
+ <target name="service-lib-dependencies"
+ depends="init-lib-dependencies"
+ xmlns:artifact="urn:maven-artifact-ant"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:lib-dependencies/>
+
+ <artifact:dependencies>
+
+ <dependency groupId="perfsonar" artifactId="perfsonar-base"
version="1.0.20080902"/>
+ <dependency groupId="nmwg" artifactId="nmwg"
version="1.0.20080916"/>
+ <dependency groupId="perfsonar" artifactId="perfsonar-web-admin"
version="0.9.2b"/>
+
+ <localRepository refid="local.repository"/>
+ <remoteRepository refid="remote.repository"/>
+
+ </artifact:dependencies>
+ </target>
+
+
+ <!--
===================================================================================
-->
+ <!-- main target -->
+
+
+ <target name="lib"
+ depends="service-lib-dependencies">
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/ant/pre-install-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/pre-install-targets.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/pre-install-targets.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,46 +1,46 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: pre-install-targets.xml 2995 2007-10-26 12:16:07Z roman $
- project: perfSONAR
- date: 2007/06/19
- author: roman
- author: fernandes (adaptation)
-
- </description>
-
--->
-
-<project name="pre-install-targets"
- basedir="..">
-
-
- <!--
===================================================================================
-->
- <!-- main target -->
-
-
- <target name="pre-install"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:template-use template-file="ant/const.properties.template"
- dest-file="ant/const.properties"/>
- <psbase:template-use template-file="conf/service.properties.template"
- dest-file="conf/service.properties"/>
-
- <property file="${basedir}/ant/const.properties"/> <!-- loading
service.name property -->
-
- <psbase:get-service-name
default-service-name="${service.name}-${version}"
- dest-config-file="ant/const.properties"/>
- <psbase:get-service-home dest-config-file="ant/const.properties"/>
- <psbase:get-tomcat dest-config-file="ant/const.properties"
-
tomcat-download-url="http://www.perfsonar.net/download/dependencies/preinstall_download.php?product=tomcat&amp;version=6.0.7";
- tomcat-name="apache-tomcat-6.0.7"/>
- <psbase:get-server-port dest-config-file="ant/const.properties"/>
-
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: pre-install-targets.xml 2995 2007-10-26 12:16:07Z roman $
+ project: perfSONAR
+ date: 2007/06/19
+ author: roman
+ author: fernandes (adaptation)
+
+ </description>
+
+-->
+
+<project name="pre-install-targets"
+ basedir="..">
+
+
+ <!--
===================================================================================
-->
+ <!-- main target -->
+
+
+ <target name="pre-install"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:template-use template-file="ant/const.properties.template"
+ dest-file="ant/const.properties"/>
+ <psbase:template-use template-file="conf/service.properties.template"
+ dest-file="conf/service.properties"/>
+
+ <property file="${basedir}/ant/const.properties"/> <!-- loading
service.name property -->
+
+ <psbase:get-service-name
default-service-name="${service.name}-${version}"
+ dest-config-file="ant/const.properties"/>
+ <psbase:get-service-home dest-config-file="ant/const.properties"/>
+ <psbase:get-tomcat dest-config-file="ant/const.properties"
+
tomcat-download-url="http://www.perfsonar.net/download/dependencies/preinstall_download.php?product=tomcat&amp;version=6.0.7";
+ tomcat-name="apache-tomcat-6.0.7"/>
+ <psbase:get-server-port dest-config-file="ant/const.properties"/>
+
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/ant/release-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/release-targets.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/ant/release-targets.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,71 +1,71 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: release-targets.xml 2498 2007-07-03 12:36:49Z roman $
- project: perfSONAR
- date: 2007/07/03
- author: romradz
-
- </description>
-
--->
-
-<project name="release-targets"
- basedir="..">
-
-
- <target name="release-init"
- xmlns:psbase="psbase:/base.perfsonar.org">
-
- <psbase:template-use template-file="ant/const.properties.template"
- dest-file="ant/const.properties"/>
- <property file="${basedir}/ant/const.properties"/>
-
- </target>
-
-
- <target name="release"
- depends="release-init,jar">
-
- <delete dir="tmp"/>
- <mkdir dir="tmp/${service.name}-${version}"/>
- <copy todir="tmp/${service.name}-${version}">
- <fileset dir="${basedir}"/>
- </copy>
-
- <delete dir="tmp/${service.name}-${version}/tmp"/>
- <delete dir="tmp/${service.name}-${version}/build/org"/>
- <delete dir="tmp/${service.name}-${version}/bin"/>
-
- <delete
file="tmp/${service.name}-${version}/conf/components.properties"/>
- <delete file="tmp/${service.name}-${version}/conf/service.properties"/>
- <delete file="tmp/${service.name}-${version}/conf/log4j.properties"/>
- <delete file="tmp/${service.name}-${version}/ant/const.properties"/>
-
- <delete>
- <fileset dir="tmp/${service.name}-${version}/conf"
includes="**/*.old"/>
- <fileset dir="tmp/${service.name}-${version}/samples/requests"
includes="**/response*.xml"/>
- </delete>
-
-
- <delete dir="tmp/${service.name}-${version}/lib/rrd"/>
-
- <tar destfile="${service.name}-${version}.tar"
- basedir="tmp/"
- longfile="gnu"
- excludes=".svn/**"/>
-
- <delete dir="tmp"/>
-
- <gzip zipfile="${service.name}-${version}.tar.gz"
- src="${service.name}-${version}.tar"/>
-
- <delete file="${service.name}-${version}.tar"/>
-
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: release-targets.xml 2498 2007-07-03 12:36:49Z roman $
+ project: perfSONAR
+ date: 2007/07/03
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="release-targets"
+ basedir="..">
+
+
+ <target name="release-init"
+ xmlns:psbase="psbase:/base.perfsonar.org">
+
+ <psbase:template-use template-file="ant/const.properties.template"
+ dest-file="ant/const.properties"/>
+ <property file="${basedir}/ant/const.properties"/>
+
+ </target>
+
+
+ <target name="release"
+ depends="release-init,jar">
+
+ <delete dir="tmp"/>
+ <mkdir dir="tmp/${service.name}-${version}"/>
+ <copy todir="tmp/${service.name}-${version}">
+ <fileset dir="${basedir}"/>
+ </copy>
+
+ <delete dir="tmp/${service.name}-${version}/tmp"/>
+ <delete dir="tmp/${service.name}-${version}/build/org"/>
+ <delete dir="tmp/${service.name}-${version}/bin"/>
+
+ <delete
file="tmp/${service.name}-${version}/conf/components.properties"/>
+ <delete file="tmp/${service.name}-${version}/conf/service.properties"/>
+ <delete file="tmp/${service.name}-${version}/conf/log4j.properties"/>
+ <delete file="tmp/${service.name}-${version}/ant/const.properties"/>
+
+ <delete>
+ <fileset dir="tmp/${service.name}-${version}/conf"
includes="**/*.old"/>
+ <fileset dir="tmp/${service.name}-${version}/samples/requests"
includes="**/response*.xml"/>
+ </delete>
+
+
+ <delete dir="tmp/${service.name}-${version}/lib/rrd"/>
+
+ <tar destfile="${service.name}-${version}.tar"
+ basedir="tmp/"
+ longfile="gnu"
+ excludes=".svn/**"/>
+
+ <delete dir="tmp"/>
+
+ <gzip zipfile="${service.name}-${version}.tar.gz"
+ src="${service.name}-${version}.tar"/>
+
+ <delete file="${service.name}-${version}.tar"/>
+
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/ant/test-targets.xml
===================================================================
--- trunk/rnp_java-cl-mp/ant/test-targets.xml 2008-09-22 12:46:40 UTC (rev
4525)
+++ trunk/rnp_java-cl-mp/ant/test-targets.xml 2008-09-22 13:59:50 UTC (rev
4526)
@@ -1,120 +1,120 @@
-<?xml version="1.0"?>
-
-<!--
-
- <description>
-
- $Id: test-targets.xml 2961 2007-10-16 11:00:08Z roman $
- project: perfSONAR
- date: 2007/06/29
- author: romradz
-
- </description>
-
--->
-
-<project name="test-targets"
- basedir="..">
-
-
- <path id="classpath">
- <fileset dir="${basedir}/lib/repository">
- <include name="**/*.jar"/>
- </fileset>
- </path>
-
-
- <target name="init-test">
- <property file="${basedir}/ant/const.properties"/>
- <property name="mp.local"
-
value="http://${target.server}:${target.port}/${deploy.root}/services/${wsdd.webservice.name}";
/>
- </target>
-
-
- <target name="echo-test"
- depends="init-test">
- <java classname="org.perfsonar.client.testHarness.SOAPClient"
- classpathref="classpath"
- fork="true">
- <arg value="${mp.local}"/>
- <arg value="${basedir}/samples/requests/EchoRequest.xml"/>
- <arg value="${basedir}/samples/requests/response-1.xml"/>
- </java>
- </target>
-
-
- <target name="lookup-info-test"
- depends="init-test">
- <java classname="org.perfsonar.client.testHarness.SOAPClient"
- classpathref="classpath"
- fork="true">
- <arg value="${mp.local}"/>
- <arg value="${basedir}/samples/requests/LookupInfoRequest.xml"/>
- <arg value="${basedir}/samples/requests/response-2.xml"/>
- </java>
- </target>
-
-
- <!--
===================================================================================

-
-
- <target name="ping-test"
- depends="init-test">
- <java classname="org.perfsonar.client.testHarness.SOAPClient"
- classpathref="classpath"
- fork="true">
- <arg value="${mp.local}"/>
- <arg value="${basedir}/samples/requests/MeasurementRequest-Ping.xml"/>
- <arg value="${basedir}/samples/requests/response-3.xml"/>
- </java>
- </target>
-
-
- <target name="traceroute-test"
- depends="init-test">
- <java classname="org.perfsonar.client.testHarness.SOAPClient"
- classpathref="classpath"
- fork="true">
- <arg value="${mp.local}"/>
- <arg
value="${basedir}/samples/requests/MeasurementRequest-Traceroute.xml"/>
- <arg value="${basedir}/samples/requests/response-4.xml"/>
- </java>
- </target>
-
-
- <target name="owamp-test"
- depends="init-test">
- <java classname="org.perfsonar.client.testHarness.SOAPClient"
- classpathref="classpath"
- fork="true">
- <arg value="${mp.local}"/>
- <arg
value="${basedir}/samples/requests/MeasurementRequest-OWAMP.xml"/>
- <arg value="${basedir}/samples/requests/response-5.xml"/>
- </java>
- </target>
-
-
- <target name="bwctl-test"
- depends="init-test">
- <java classname="org.perfsonar.client.testHarness.SOAPClient"
- classpathref="classpath"
- fork="true">
- <arg value="${mp.local}"/>
- <arg
value="${basedir}/samples/requests/MeasurementRequest-BWCTL.xml"/>
- <arg value="${basedir}/samples/requests/response-6.xml"/>
- </java>
- </target>
- -->
- <!--
===================================================================================
-->
- <!-- main target -->
-
-
- <target name="test">
-
- <antcall target="echo-test"/>
- <antcall target="lookup-info-test"/>
-
- </target>
-
-
-</project>
+<?xml version="1.0"?>
+
+<!--
+
+ <description>
+
+ $Id: test-targets.xml 2961 2007-10-16 11:00:08Z roman $
+ project: perfSONAR
+ date: 2007/06/29
+ author: romradz
+
+ </description>
+
+-->
+
+<project name="test-targets"
+ basedir="..">
+
+
+ <path id="classpath">
+ <fileset dir="${basedir}/lib/repository">
+ <include name="**/*.jar"/>
+ </fileset>
+ </path>
+
+
+ <target name="init-test">
+ <property file="${basedir}/ant/const.properties"/>
+ <property name="mp.local"
+
value="http://${target.server}:${target.port}/${deploy.root}/services/${wsdd.webservice.name}";
/>
+ </target>
+
+
+ <target name="echo-test"
+ depends="init-test">
+ <java classname="org.perfsonar.client.testHarness.SOAPClient"
+ classpathref="classpath"
+ fork="true">
+ <arg value="${mp.local}"/>
+ <arg value="${basedir}/samples/requests/EchoRequest.xml"/>
+ <arg value="${basedir}/samples/requests/response-1.xml"/>
+ </java>
+ </target>
+
+
+ <target name="lookup-info-test"
+ depends="init-test">
+ <java classname="org.perfsonar.client.testHarness.SOAPClient"
+ classpathref="classpath"
+ fork="true">
+ <arg value="${mp.local}"/>
+ <arg value="${basedir}/samples/requests/LookupInfoRequest.xml"/>
+ <arg value="${basedir}/samples/requests/response-2.xml"/>
+ </java>
+ </target>
+
+
+ <!--
===================================================================================

+
+
+ <target name="ping-test"
+ depends="init-test">
+ <java classname="org.perfsonar.client.testHarness.SOAPClient"
+ classpathref="classpath"
+ fork="true">
+ <arg value="${mp.local}"/>
+ <arg value="${basedir}/samples/requests/MeasurementRequest-Ping.xml"/>
+ <arg value="${basedir}/samples/requests/response-3.xml"/>
+ </java>
+ </target>
+
+
+ <target name="traceroute-test"
+ depends="init-test">
+ <java classname="org.perfsonar.client.testHarness.SOAPClient"
+ classpathref="classpath"
+ fork="true">
+ <arg value="${mp.local}"/>
+ <arg
value="${basedir}/samples/requests/MeasurementRequest-Traceroute.xml"/>
+ <arg value="${basedir}/samples/requests/response-4.xml"/>
+ </java>
+ </target>
+
+
+ <target name="owamp-test"
+ depends="init-test">
+ <java classname="org.perfsonar.client.testHarness.SOAPClient"
+ classpathref="classpath"
+ fork="true">
+ <arg value="${mp.local}"/>
+ <arg
value="${basedir}/samples/requests/MeasurementRequest-OWAMP.xml"/>
+ <arg value="${basedir}/samples/requests/response-5.xml"/>
+ </java>
+ </target>
+
+
+ <target name="bwctl-test"
+ depends="init-test">
+ <java classname="org.perfsonar.client.testHarness.SOAPClient"
+ classpathref="classpath"
+ fork="true">
+ <arg value="${mp.local}"/>
+ <arg
value="${basedir}/samples/requests/MeasurementRequest-BWCTL.xml"/>
+ <arg value="${basedir}/samples/requests/response-6.xml"/>
+ </java>
+ </target>
+ -->
+ <!--
===================================================================================
-->
+ <!-- main target -->
+
+
+ <target name="test">
+
+ <antcall target="echo-test"/>
+ <antcall target="lookup-info-test"/>
+
+ </target>
+
+
+</project>

Modified: trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/server-config.wsdd
===================================================================
--- trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/server-config.wsdd
2008-09-22 12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/server-config.wsdd
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,57 +1,57 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<deployment xmlns="http://xml.apache.org/axis/wsdd/";
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";>
- <globalConfiguration>
- <parameter name="sendMultiRefs" value="true"/>
- <parameter name="disablePrettyXML" value="true"/>
- <parameter name="adminPassword" value="admin"/>
- <parameter name="dotNetSoapEncFix" value="true"/>
- <parameter name="enableNamespacePrefixOptimization" value="false"/>
- <parameter name="sendXMLDeclaration" value="true"/>
- <parameter name="sendXsiTypes" value="true"/>
- <parameter name="attachments.implementation"
value="org.apache.axis.attachments.AttachmentsImpl"/>
- <requestFlow>
- <handler type="java:org.apache.axis.handlers.JWSHandler">
- <parameter name="scope" value="session"/>
- </handler>
- <handler type="java:org.apache.axis.handlers.JWSHandler">
- <parameter name="scope" value="request"/>
- <parameter name="extension" value=".jwr"/>
- </handler>
- </requestFlow>
- </globalConfiguration>
- <handler name="LocalResponder"
type="java:org.apache.axis.transport.local.LocalResponder"/>
- <handler name="URLMapper"
type="java:org.apache.axis.handlers.http.URLMapper"/>
- <handler name="Authenticate"
type="java:org.apache.axis.handlers.SimpleAuthenticationHandler"/>
- <service name="AdminService" provider="java:MSG">
- <parameter name="allowedMethods" value="AdminService"/>
- <parameter name="enableRemoteAdmin" value="false"/>
- <parameter name="className" value="org.apache.axis.utils.Admin"/>
- <namespace>http://xml.apache.org/axis/wsdd/</namespace>
- </service>
- <service name="Version" provider="java:RPC">
- <parameter name="allowedMethods" value="getVersion"/>
- <parameter name="className" value="org.apache.axis.Version"/>
- </service>
- <service name="CommandLineService" provider="java:MSG" style="message"
use="literal">
- <parameter name="allowedMethods" value="acceptCall"/>
- <parameter name="className"
value="org.perfsonar.service.base.web.RequestHandler"/>
- <namespace>http://perfsonar.org/services/measurementPoint</namespace>
- </service>
- <transport name="http">
- <requestFlow>
- <handler type="URLMapper"/>
- <handler type="java:org.apache.axis.handlers.http.HTTPAuthHandler"/>
- </requestFlow>
- <parameter name="qs:list"
value="org.apache.axis.transport.http.QSListHandler"/>
- <parameter name="qs:wsdl"
value="org.apache.axis.transport.http.QSWSDLHandler"/>
- <parameter name="qs.list"
value="org.apache.axis.transport.http.QSListHandler"/>
- <parameter name="qs.method"
value="org.apache.axis.transport.http.QSMethodHandler"/>
- <parameter name="qs:method"
value="org.apache.axis.transport.http.QSMethodHandler"/>
- <parameter name="qs.wsdl"
value="org.apache.axis.transport.http.QSWSDLHandler"/>
- </transport>
- <transport name="local">
- <responseFlow>
- <handler type="LocalResponder"/>
- </responseFlow>
- </transport>
+<?xml version="1.0" encoding="UTF-8"?>
+<deployment xmlns="http://xml.apache.org/axis/wsdd/";
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";>
+ <globalConfiguration>
+ <parameter name="sendMultiRefs" value="true"/>
+ <parameter name="disablePrettyXML" value="true"/>
+ <parameter name="adminPassword" value="admin"/>
+ <parameter name="dotNetSoapEncFix" value="true"/>
+ <parameter name="enableNamespacePrefixOptimization" value="false"/>
+ <parameter name="sendXMLDeclaration" value="true"/>
+ <parameter name="sendXsiTypes" value="true"/>
+ <parameter name="attachments.implementation"
value="org.apache.axis.attachments.AttachmentsImpl"/>
+ <requestFlow>
+ <handler type="java:org.apache.axis.handlers.JWSHandler">
+ <parameter name="scope" value="session"/>
+ </handler>
+ <handler type="java:org.apache.axis.handlers.JWSHandler">
+ <parameter name="scope" value="request"/>
+ <parameter name="extension" value=".jwr"/>
+ </handler>
+ </requestFlow>
+ </globalConfiguration>
+ <handler name="LocalResponder"
type="java:org.apache.axis.transport.local.LocalResponder"/>
+ <handler name="URLMapper"
type="java:org.apache.axis.handlers.http.URLMapper"/>
+ <handler name="Authenticate"
type="java:org.apache.axis.handlers.SimpleAuthenticationHandler"/>
+ <service name="AdminService" provider="java:MSG">
+ <parameter name="allowedMethods" value="AdminService"/>
+ <parameter name="enableRemoteAdmin" value="false"/>
+ <parameter name="className" value="org.apache.axis.utils.Admin"/>
+ <namespace>http://xml.apache.org/axis/wsdd/</namespace>
+ </service>
+ <service name="Version" provider="java:RPC">
+ <parameter name="allowedMethods" value="getVersion"/>
+ <parameter name="className" value="org.apache.axis.Version"/>
+ </service>
+ <service name="CommandLineService" provider="java:MSG" style="message"
use="literal">
+ <parameter name="allowedMethods" value="acceptCall"/>
+ <parameter name="className"
value="org.perfsonar.service.base.web.RequestHandler"/>
+ <namespace>http://perfsonar.org/services/measurementPoint</namespace>
+ </service>
+ <transport name="http">
+ <requestFlow>
+ <handler type="URLMapper"/>
+ <handler type="java:org.apache.axis.handlers.http.HTTPAuthHandler"/>
+ </requestFlow>
+ <parameter name="qs:list"
value="org.apache.axis.transport.http.QSListHandler"/>
+ <parameter name="qs:wsdl"
value="org.apache.axis.transport.http.QSWSDLHandler"/>
+ <parameter name="qs.list"
value="org.apache.axis.transport.http.QSListHandler"/>
+ <parameter name="qs.method"
value="org.apache.axis.transport.http.QSMethodHandler"/>
+ <parameter name="qs:method"
value="org.apache.axis.transport.http.QSMethodHandler"/>
+ <parameter name="qs.wsdl"
value="org.apache.axis.transport.http.QSWSDLHandler"/>
+ </transport>
+ <transport name="local">
+ <responseFlow>
+ <handler type="LocalResponder"/>
+ </responseFlow>
+ </transport>
</deployment>
\ No newline at end of file

Modified: trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/web.xml
===================================================================
--- trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/web.xml 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/conf/axis-1.4/WEB-INF/web.xml 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,144 +1,144 @@
-<?xml version="1.0" encoding="ISO-8859-1"?>
-
-<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
-Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd";>
-
-<web-app>
- <display-name>Apache-Axis</display-name>
-
- <listener>
-
<listener-class>org.apache.axis.transport.http.AxisHTTPSessionListener</listener-class>
- </listener>
-
- <listener>
-
<listener-class>org.perfsonar.service.base.container.listeners.StartupInitializer</listener-class>
- </listener>
-
- <servlet>
- <servlet-name>AxisServlet</servlet-name>
- <display-name>Apache-Axis Servlet</display-name>
- <servlet-class>
- org.apache.axis.transport.http.AxisServlet
- </servlet-class>
- </servlet>
-
- <servlet>
- <servlet-name>AdminServlet</servlet-name>
- <display-name>Axis Admin Servlet</display-name>
- <servlet-class>
- org.apache.axis.transport.http.AdminServlet
- </servlet-class>
- <load-on-startup>100</load-on-startup>
- </servlet>
-
- <servlet>
- <servlet-name>SOAPMonitorService</servlet-name>
- <display-name>SOAPMonitorService</display-name>
- <servlet-class>
- org.apache.axis.monitor.SOAPMonitorService
- </servlet-class>
- <init-param>
- <param-name>SOAPMonitorPort</param-name>
- <param-value>5001</param-value>
- </init-param>
- <load-on-startup>100</load-on-startup>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>AxisServlet</servlet-name>
- <url-pattern>/servlet/AxisServlet</url-pattern>
- </servlet-mapping>
-
- <servlet-mapping>
- <servlet-name>AxisServlet</servlet-name>
- <url-pattern>*.jws</url-pattern>
- </servlet-mapping>
-
- <servlet-mapping>
- <servlet-name>AxisServlet</servlet-name>
- <url-pattern>/services/*</url-pattern>
- </servlet-mapping>
-
- <servlet-mapping>
- <servlet-name>SOAPMonitorService</servlet-name>
- <url-pattern>/SOAPMonitor</url-pattern>
- </servlet-mapping>
-
- <!-- uncomment this if you want the admin servlet -->
- <!--
- <servlet-mapping>
- <servlet-name>AdminServlet</servlet-name>
- <url-pattern>/servlet/AdminServlet</url-pattern>
- </servlet-mapping>
- -->
-
- <session-config>
- <!-- Default to 5 minute session timeouts -->
- <session-timeout>5</session-timeout>
- </session-config>
-
- <!-- currently the W3C havent settled on a media type for WSDL;
- http://www.w3.org/TR/2003/WD-wsdl12-20030303/#ietf-draft
- for now we go with the basic 'it's XML' response -->
- <mime-mapping>
- <extension>wsdl</extension>
- <mime-type>text/xml</mime-type>
- </mime-mapping>
-
-
- <mime-mapping>
- <extension>xsd</extension>
- <mime-type>text/xml</mime-type>
- </mime-mapping>
-
-
-
- <!-- pS Config Servlet Admin -->
-
- <servlet>
- <servlet-name>
- ServiceAdmin
- </servlet-name>
- <servlet-class>
- perfSONARWebAdmin.admin.service.Admin
- </servlet-class>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>
- ServiceAdmin
- </servlet-name>
- <url-pattern>
- /ServiceAdmin
- </url-pattern>
- </servlet-mapping>
-
- <!-- pS Config Wizard Admin -->
-
- <servlet>
- <servlet-name>
- Wizard
- </servlet-name>
- <servlet-class>
- perfSONARWebAdmin.admin.wizard.Wizard
- </servlet-class>
- </servlet>
-
- <servlet-mapping>
- <servlet-name>
- Wizard
- </servlet-name>
- <url-pattern>
- /Wizard
- </url-pattern>
- </servlet-mapping>
-
-
-
- <welcome-file-list id="WelcomeFileList">
- <welcome-file>index.html</welcome-file>
- <welcome-file>index.jsp</welcome-file>
- <welcome-file>index.jws</welcome-file>
- </welcome-file-list>
-
-</web-app>
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
+<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
+Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd";>
+
+<web-app>
+ <display-name>Apache-Axis</display-name>
+
+ <listener>
+
<listener-class>org.apache.axis.transport.http.AxisHTTPSessionListener</listener-class>
+ </listener>
+
+ <listener>
+
<listener-class>org.perfsonar.service.base.container.listeners.StartupInitializer</listener-class>
+ </listener>
+
+ <servlet>
+ <servlet-name>AxisServlet</servlet-name>
+ <display-name>Apache-Axis Servlet</display-name>
+ <servlet-class>
+ org.apache.axis.transport.http.AxisServlet
+ </servlet-class>
+ </servlet>
+
+ <servlet>
+ <servlet-name>AdminServlet</servlet-name>
+ <display-name>Axis Admin Servlet</display-name>
+ <servlet-class>
+ org.apache.axis.transport.http.AdminServlet
+ </servlet-class>
+ <load-on-startup>100</load-on-startup>
+ </servlet>
+
+ <servlet>
+ <servlet-name>SOAPMonitorService</servlet-name>
+ <display-name>SOAPMonitorService</display-name>
+ <servlet-class>
+ org.apache.axis.monitor.SOAPMonitorService
+ </servlet-class>
+ <init-param>
+ <param-name>SOAPMonitorPort</param-name>
+ <param-value>5001</param-value>
+ </init-param>
+ <load-on-startup>100</load-on-startup>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>AxisServlet</servlet-name>
+ <url-pattern>/servlet/AxisServlet</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>AxisServlet</servlet-name>
+ <url-pattern>*.jws</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>AxisServlet</servlet-name>
+ <url-pattern>/services/*</url-pattern>
+ </servlet-mapping>
+
+ <servlet-mapping>
+ <servlet-name>SOAPMonitorService</servlet-name>
+ <url-pattern>/SOAPMonitor</url-pattern>
+ </servlet-mapping>
+
+ <!-- uncomment this if you want the admin servlet -->
+ <!--
+ <servlet-mapping>
+ <servlet-name>AdminServlet</servlet-name>
+ <url-pattern>/servlet/AdminServlet</url-pattern>
+ </servlet-mapping>
+ -->
+
+ <session-config>
+ <!-- Default to 5 minute session timeouts -->
+ <session-timeout>5</session-timeout>
+ </session-config>
+
+ <!-- currently the W3C havent settled on a media type for WSDL;
+ http://www.w3.org/TR/2003/WD-wsdl12-20030303/#ietf-draft
+ for now we go with the basic 'it's XML' response -->
+ <mime-mapping>
+ <extension>wsdl</extension>
+ <mime-type>text/xml</mime-type>
+ </mime-mapping>
+
+
+ <mime-mapping>
+ <extension>xsd</extension>
+ <mime-type>text/xml</mime-type>
+ </mime-mapping>
+
+
+
+ <!-- pS Config Servlet Admin -->
+
+ <servlet>
+ <servlet-name>
+ ServiceAdmin
+ </servlet-name>
+ <servlet-class>
+ perfSONARWebAdmin.admin.service.Admin
+ </servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>
+ ServiceAdmin
+ </servlet-name>
+ <url-pattern>
+ /ServiceAdmin
+ </url-pattern>
+ </servlet-mapping>
+
+ <!-- pS Config Wizard Admin -->
+
+ <servlet>
+ <servlet-name>
+ Wizard
+ </servlet-name>
+ <servlet-class>
+ perfSONARWebAdmin.admin.wizard.Wizard
+ </servlet-class>
+ </servlet>
+
+ <servlet-mapping>
+ <servlet-name>
+ Wizard
+ </servlet-name>
+ <url-pattern>
+ /Wizard
+ </url-pattern>
+ </servlet-mapping>
+
+
+
+ <welcome-file-list id="WelcomeFileList">
+ <welcome-file>index.html</welcome-file>
+ <welcome-file>index.jsp</welcome-file>
+ <welcome-file>index.jws</welcome-file>
+ </welcome-file-list>
+
+</web-app>

Added: trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_fail.gif


Property changes on:
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_fail.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream

Added: trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_main.gif


Property changes on:
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_main.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream

Added: trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_return.gif


Property changes on:
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_return.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream

Added: trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_startbn.gif


Property changes on:
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_startbn.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream

Added: trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_succ.gif


Property changes on:
trunk/rnp_java-cl-mp/conf/axis-1.4/graphics/testdepl_succ.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream

Deleted: trunk/rnp_java-cl-mp/conf/axis-1.4/index.html

Added: trunk/rnp_java-cl-mp/conf/axis-1.4/testdepl.jsp

Added: trunk/rnp_java-cl-mp/conf/components.properties

Added: trunk/rnp_java-cl-mp/conf/cron/clmpcron

Added: trunk/rnp_java-cl-mp/conf/cron/local/.tmp

Modified: trunk/rnp_java-cl-mp/conf/eventType-map.xml
===================================================================
--- trunk/rnp_java-cl-mp/conf/eventType-map.xml 2008-09-22 12:46:40 UTC (rev
4525)
+++ trunk/rnp_java-cl-mp/conf/eventType-map.xml 2008-09-22 13:59:50 UTC (rev
4526)
@@ -1,35 +1,41 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<eventType-config>
-
- <eventType>
- <name>http://ggf.org/ns/nmwg/tools/ping/2.0</name>
-
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Ping</class>
- <authentication>no</authentication>
- </eventType>
-
- <eventType>
- <name>http://ggf.org/ns/nmwg/tools/traceroute/2.0</name>
-
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Traceroute</class>
- <authentication>no</authentication>
- </eventType>
-
- <eventType>
- <name>http://ggf.org/ns/nmwg/tools/owamp/2.0</name>
-
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Owamp</class>
- <authentication>no</authentication>
- </eventType>
-
- <eventType>
- <name>http://ggf.org/ns/nmwg/tools/bwctl/2.0</name>
-
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Bwctl</class>
- <authentication>no</authentication>
- </eventType>
-
- <eventType>
- <name>http://ggf.org/ns/nmwg/tools/cron/2.0</name>
-
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Cron</class>
- <authentication>no</authentication>
- </eventType>
-
-</eventType-config>
+<?xml version="1.0" encoding="UTF-8"?>
+
+<eventType-config>
+
+ <eventType>
+ <name>http://ggf.org/ns/nmwg/tools/ping/2.0</name>
+
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Ping</class>
+ <authentication>no</authentication>
+ </eventType>
+
+ <eventType>
+ <name>http://ggf.org/ns/nmwg/tools/traceroute/2.0</name>
+
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Traceroute</class>
+ <authentication>no</authentication>
+ </eventType>
+
+ <eventType>
+ <name>http://ggf.org/ns/nmwg/tools/owamp/2.0</name>
+
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Owamp</class>
+ <authentication>no</authentication>
+ </eventType>
+
+ <eventType>
+ <name>http://ggf.org/ns/nmwg/tools/owamp/summary/2.0</name>
+
<class>org.perfsonar.service.measurementPoint.commandLine.tools.OwampSummary</class>
+ <authentication>no</authentication>
+ </eventType>
+
+ <eventType>
+ <name>http://ggf.org/ns/nmwg/tools/bwctl/2.0</name>
+
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Bwctl</class>
+ <authentication>no</authentication>
+ </eventType>
+
+ <eventType>
+ <name>http://ggf.org/ns/nmwg/tools/cron/2.0</name>
+
<class>org.perfsonar.service.measurementPoint.commandLine.tools.Cron</class>
+ <authentication>no</authentication>
+ </eventType>
+
+</eventType-config>

Added: trunk/rnp_java-cl-mp/conf/log4j.properties

Added: trunk/rnp_java-cl-mp/conf/log4j.syslog.properties

Added: trunk/rnp_java-cl-mp/conf/scripts/bwctl.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/connectivity.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/daemonbwctl.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/daemonntp.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/daemonowamp.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/dnslookup.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/iperf.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/ntpsynchronized.sh

Added: trunk/rnp_java-cl-mp/conf/scripts/owping.sh

Added: trunk/rnp_java-cl-mp/conf/selfTest-map.xml

Added: trunk/rnp_java-cl-mp/conf/service.properties

Modified: trunk/rnp_java-cl-mp/conf/service.properties.template-2
===================================================================
--- trunk/rnp_java-cl-mp/conf/service.properties.template-2 2008-09-22
12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/conf/service.properties.template-2 2008-09-22
13:59:50 UTC (rev 4526)
@@ -16,16 +16,19 @@

# Group=Internal
# Description=File which contains the mapping information for parsing the
messages.
-service.sax_parser.config=/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/objects.config
+service.sax_parser.config=/opt/perfsonar/services/perfsonar-clmp/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/objects.config

# Group=Internal
# Description=File with configuration for the logger component.
-service.log.log4j.config=/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/log4j.properties
+service.log.log4j.config=/opt/perfsonar/services/perfsonar-clmp/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/log4j.properties

# Group=Internal
# Description=File with tools mapping and authentication information.
-service.clmp.tools_map=/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/eventType-map.xml
+service.clmp.tools_map=/opt/perfsonar/services/perfsonar-clmp/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/eventType-map.xml

+# Group=Internal
+# Description=File with selftest mapping.
+service.clmp.selftest_map=/opt/perfsonar/services/perfsonar-clmp/perfsonar-clmp/WEB-INF/classes/perfsonar/conf/selfTest-map.xml

#
-----------------------------------------------------------------------------------------------
# Configuration of the scheduling functionality
@@ -37,11 +40,11 @@

# Group=Cron-Like Scheduler
# Description=Determines where to place locally stored results from the
scheduled measurements. Only used if the default_ma option is 'local'.
-service.clmp.cron.local_storage_dir=/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/cron/local
+service.clmp.cron.local_storage_dir=/opt/perfsonar/services/perfsonar-clmp/perfsonar-clmp/WEB-INF/classes/perfsonar/cron/local

# Group=Cron-Like Scheduler
# Description=Determines where the scheduler database and related files will
be stored.
-service.clmp.cron_dir=/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/cron
+service.clmp.cron_dir=/opt/perfsonar/services/perfsonar-clmp/perfsonar-clmp/WEB-INF/classes/perfsonar/cron

# Group=Cron-Like Scheduler
# Description=General purpose scheduler component used by the cron-like
scheduler. Must exist in components.properties.

Modified: trunk/rnp_java-cl-mp/conf/wizard.properties
===================================================================
--- trunk/rnp_java-cl-mp/conf/wizard.properties 2008-09-22 12:46:40 UTC (rev
4525)
+++ trunk/rnp_java-cl-mp/conf/wizard.properties 2008-09-22 13:59:50 UTC (rev
4526)
@@ -1,187 +1,218 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE properties [
- <!ELEMENT properties ( comment?, property* )>
-<!ATTLIST properties version CDATA #FIXED "0.1">
-<!ELEMENT comment (#PCDATA) >
-<!ELEMENT property (entry,Comment,ProposedValue,Group+,AcceptedValue*) >
-<!ELEMENT entry (#PCDATA) >
-<!ATTLIST entry
-key CDATA #REQUIRED
- password (true|false) #IMPLIED
- required (true|false) #IMPLIED >
-<!ELEMENT Comment (#PCDATA) >
-<!ELEMENT ProposedValue (#PCDATA) >
-<!ELEMENT Group (#PCDATA) >
-<!ATTLIST Group
- order CDATA #REQUIRED
- check (true|false) #IMPLIED
->
-<!ELEMENT AcceptedValue (#PCDATA) >
-]>
-
-
-<properties>
-
-
- <comment>$Id$</comment>
-
-
-
- <property>
- <entry key="service.clmp.rp.maxthreads.ping"
required="true">99999</entry>
- <Comment>Enter the quantity of threads for tool ping</Comment>
- <ProposedValue>99999</ProposedValue>
- <Group order="1">Resource Protector</Group>
- </property>
- <property>
- <entry key="service.clmp.rp.maxthreads.traceroute"
required="true">99999</entry>
- <Comment>Enter the quantity of threads for tool traceroute</Comment>
- <ProposedValue>99999</ProposedValue>
- <Group order="2">Resource Protector</Group>
- </property>
- <property>
- <entry key="service.clmp.rp.maxthreads.owping"
required="true">99999</entry>
- <Comment>Enter the quantity of threads for tool OWAMP</Comment>
- <ProposedValue>99999</ProposedValue>
- <Group order="3">Resource Protector</Group>
- </property>
- <property>
- <entry key="service.clmp.rp.maxthreads.bwctl"
required="true">99999</entry>
- <Comment>Enter the quantity of threads for tool BWCTL</Comment>
- <ProposedValue>99999</ProposedValue>
- <Group order="4">Resource Protector</Group>
- </property>
-
- <property>
- <entry key="service.clmp.default_ma" required="true">local</entry>
- <Comment>Specify default MA (e.g. http://address:8080/SQL-MA/services/MA
or local)</Comment>
- <ProposedValue>local</ProposedValue>
- <Group order="1">Cron-Like Scheduler</Group>
- </property>
- <property>
- <entry key="service.clmp.cron.local_storage_dir"
required="true">/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/cron/local</entry>
- <Comment>Enter directory for local storage</Comment>
-
<ProposedValue>/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/cron/local</ProposedValue>
- <Group order="2">Cron-Like Scheduler</Group>
- </property>
-
- <property>
- <entry key="authentication.enable" required="true">no</entry>
- <Comment>Do you wish to enable authentication?</Comment>
- <ProposedValue>yes</ProposedValue>
- <Group order="1" check="true">Authentication</Group>
- <AcceptedValue>yes</AcceptedValue>
- <AcceptedValue>no</AcceptedValue>
- </property>
-
- <property>
- <entry key="service.as.point"
required="true">http://homer.rediris.es:8081</entry>
- <Comment>Enter the URL address of the Authentication Service:</Comment>
-
<ProposedValue>http://homer.rediris.es:8080/perfSONAR-AS/services/AuthService</ProposedValue>
- <Group order="2">Authentication</Group>
- </property>
-
- <property>
- <entry key="authentication.ping" required="true">no</entry>
- <Comment>Enable authentication for tool ping?:</Comment>
- <ProposedValue>yes</ProposedValue>
- <Group order="3" check="true">Authentication</Group>
- <AcceptedValue>yes</AcceptedValue>
- <AcceptedValue>no</AcceptedValue>
- </property>
-
- <property>
- <entry key="authentication.traceroute" required="true">no</entry>
- <Comment>Enable authentication for tool traceroute?:</Comment>
- <ProposedValue>yes</ProposedValue>
- <Group order="4" check="true">Authentication</Group>
- <AcceptedValue>yes</AcceptedValue>
- <AcceptedValue>no</AcceptedValue>
- </property>
-
- <property>
- <entry key="authentication.owamp" required="true">no</entry>
- <Comment>Enable authentication for tool OWAMP?:</Comment>
- <ProposedValue>yes</ProposedValue>
- <Group order="5" check="true">Authentication</Group>
- <AcceptedValue>yes</AcceptedValue>
- <AcceptedValue>no</AcceptedValue>
- </property>
-
- <property>
- <entry key="authentication.bwctl" required="true">no</entry>
- <Comment>Enable authentication for tool BWCTL?:</Comment>
- <ProposedValue>yes</ProposedValue>
- <Group order="6" check="true">Authentication</Group>
- <AcceptedValue>yes</AcceptedValue>
- <AcceptedValue>no</AcceptedValue>
- </property>
-
- <property>
- <entry key="authentication.cron" required="true">no</entry>
- <Comment>Enable authentication for scheduling functionality?:</Comment>
- <ProposedValue>yes</ProposedValue>
- <Group order="7" check="true">Authentication</Group>
- <AcceptedValue>yes</AcceptedValue>
- <AcceptedValue>no</AcceptedValue>
- </property>
-
- <property>
- <entry key="servlet.username" required="true">perfsonaruser</entry>
- <Comment>Give the username to use for logging in to the admin
pages</Comment>
- <ProposedValue>perfsonaruser</ProposedValue>
- <Group order="1" check="false">Administration</Group>
- </property>
- <property>
- <entry key="servlet.password" required="true"
password="true">perfsonarpass</entry>
- <Comment>Give the password to use for logging in to the admin
pages</Comment>
- <ProposedValue>perfsonarpass</ProposedValue>
- <Group order="2">Administration</Group>
- </property>
-
- <property>
- <entry key="service.r.service_name" required="true">CL-MP</entry>
- <Comment>Enter the service name</Comment>
- <ProposedValue>CL-MP</ProposedValue>
- <Group order="1">LS</Group>
- </property>
- <property>
- <entry key="service.r.service_description">Command Line MP</entry>
- <Comment>Give a description of the service</Comment>
- <ProposedValue>Command Line MP</ProposedValue>
- <Group order="2">LS</Group>
- </property>
- <property>
- <entry
key="service.r.contact_email">email@address</entry>
- <Comment>Enter the email address of the person administrating the
service</Comment>
-
<ProposedValue>email@address</ProposedValue>
- <Group order="3">LS</Group>
- </property>
- <property>
- <entry key="service.r.organization_name">organization_name</entry>
- <Comment>Enter the name of the organization running this
service.</Comment>
- <ProposedValue>organization_name</ProposedValue>
- <Group order="4">LS</Group>
- </property>
- <property>
- <entry key="service.r.ls_url"
required="true">http://address:port/service.name/services/LookupService</entry>
- <Comment>Give the LS url</Comment>
-
<ProposedValue>http://address:port/service.name/services/LookupService</ProposedValue>
- <Group order="5">LS</Group>
- </property>
- <property>
- <entry key="component.registrator.interval">30000</entry>
- <Comment>Give the registration interval</Comment>
- <ProposedValue>30000</ProposedValue>
- <Group order="6">LS</Group>
- </property>
- <property>
- <entry key="service.r.access_point"
required="true">http://mpaddress:8080/perfsonar-clmp/services/CommandLineService</entry>
- <Comment>Give the service access point</Comment>
-
<ProposedValue>http://mpaddress:8080/perfsonar-clmp/services/CommandLineService</ProposedValue>
- <Group order="7">LS</Group>
- </property>
-
-
-
-</properties>
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE properties [
+ <!ELEMENT properties ( comment?, property* )>
+<!ATTLIST properties version CDATA #FIXED "0.1">
+<!ELEMENT comment (#PCDATA) >
+<!ELEMENT property (entry,Comment,ProposedValue,Group+,AcceptedValue*) >
+<!ELEMENT entry (#PCDATA) >
+<!ATTLIST entry
+key CDATA #REQUIRED
+ password (true|false) #IMPLIED
+ required (true|false) #IMPLIED >
+<!ELEMENT Comment (#PCDATA) >
+<!ELEMENT ProposedValue (#PCDATA) >
+<!ELEMENT Group (#PCDATA) >
+<!ATTLIST Group
+ order CDATA #REQUIRED
+ check (true|false) #IMPLIED
+>
+<!ELEMENT AcceptedValue (#PCDATA) >
+]>
+
+
+<properties>
+
+
+ <comment>$Id$</comment>
+
+
+
+ <property>
+ <entry key="service.clmp.rp.maxthreads.ping"
required="true">99999</entry>
+ <Comment>Enter the quantity of threads for tool ping</Comment>
+ <ProposedValue>99999</ProposedValue>
+ <Group order="1">Resource Protector</Group>
+ </property>
+
+ <property>
+ <entry key="service.clmp.rp.maxthreads.traceroute"
required="true">99999</entry>
+ <Comment>Enter the quantity of threads for tool traceroute</Comment>
+ <ProposedValue>99999</ProposedValue>
+ <Group order="2">Resource Protector</Group>
+ </property>
+
+ <property>
+ <entry key="service.clmp.rp.maxthreads.owping"
required="true">99999</entry>
+ <Comment>Enter the quantity of threads for tool OWAMP</Comment>
+ <ProposedValue>99999</ProposedValue>
+ <Group order="3">Resource Protector</Group>
+ </property>
+
+ <property>
+ <entry key="service.clmp.rp.maxthreads.bwctl"
required="true">99999</entry>
+ <Comment>Enter the quantity of threads for tool BWCTL</Comment>
+ <ProposedValue>99999</ProposedValue>
+ <Group order="4">Resource Protector</Group>
+ </property>
+
+
+
+
+
+
+ <property>
+ <entry key="service.clmp.default_ma" required="true">local</entry>
+ <Comment>Specify default MA (e.g. http://address:8080/SQL-MA/services/MA
or local)</Comment>
+ <ProposedValue>local</ProposedValue>
+ <Group order="1">Cron-Like Scheduler</Group>
+ </property>
+
+ <property>
+ <entry key="service.clmp.cron.local_storage_dir"
required="true">/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/cron/local</entry>
+ <Comment>Enter directory for local storage</Comment>
+
<ProposedValue>/opt/perfsonar/services/perfsonar-clmp/WEB-INF/classes/perfsonar/cron/local</ProposedValue>
+ <Group order="2">Cron-Like Scheduler</Group>
+ </property>
+
+
+
+
+
+
+ <property>
+ <entry key="authentication.enable" required="true">no</entry>
+ <Comment>Do you wish to enable authentication?</Comment>
+ <ProposedValue>yes</ProposedValue>
+ <Group order="1" check="true">Authentication</Group>
+ <AcceptedValue>yes</AcceptedValue>
+ <AcceptedValue>no</AcceptedValue>
+ </property>
+
+ <property>
+ <entry key="service.as.point"
required="true">http://homer.rediris.es:8081</entry>
+ <Comment>Enter the URL address of the Authentication Service:</Comment>
+
<ProposedValue>http://homer.rediris.es:8080/perfSONAR-AS/services/AuthService</ProposedValue>
+ <Group order="2">Authentication</Group>
+ </property>
+
+ <property>
+ <entry key="authentication.ping" required="true">no</entry>
+ <Comment>Enable authentication for tool ping?:</Comment>
+ <ProposedValue>yes</ProposedValue>
+ <Group order="3">Authentication</Group>
+ <AcceptedValue>yes</AcceptedValue>
+ <AcceptedValue>no</AcceptedValue>
+ </property>
+
+ <property>
+ <entry key="authentication.traceroute" required="true">no</entry>
+ <Comment>Enable authentication for tool traceroute?:</Comment>
+ <ProposedValue>yes</ProposedValue>
+ <Group order="4">Authentication</Group>
+ <AcceptedValue>yes</AcceptedValue>
+ <AcceptedValue>no</AcceptedValue>
+ </property>
+
+ <property>
+ <entry key="authentication.owamp" required="true">no</entry>
+ <Comment>Enable authentication for tool OWAMP?:</Comment>
+ <ProposedValue>yes</ProposedValue>
+ <Group order="5">Authentication</Group>
+ <AcceptedValue>yes</AcceptedValue>
+ <AcceptedValue>no</AcceptedValue>
+ </property>
+
+ <property>
+ <entry key="authentication.bwctl" required="true">no</entry>
+ <Comment>Enable authentication for tool BWCTL?:</Comment>
+ <ProposedValue>yes</ProposedValue>
+ <Group order="6">Authentication</Group>
+ <AcceptedValue>yes</AcceptedValue>
+ <AcceptedValue>no</AcceptedValue>
+ </property>
+
+ <property>
+ <entry key="authentication.cron" required="true">no</entry>
+ <Comment>Enable authentication for scheduling functionality?:</Comment>
+ <ProposedValue>yes</ProposedValue>
+ <Group order="7">Authentication</Group>
+ <AcceptedValue>yes</AcceptedValue>
+ <AcceptedValue>no</AcceptedValue>
+ </property>
+
+
+
+
+
+
+ <property>
+ <entry key="servlet.username" required="true">perfsonaruser</entry>
+ <Comment>Give the username to use for logging in to the admin
pages</Comment>
+ <ProposedValue>perfsonaruser</ProposedValue>
+ <Group order="1" check="false">Administration</Group>
+ </property>
+
+ <property>
+ <entry key="servlet.password" required="true"
password="true">perfsonarpass</entry>
+ <Comment>Give the password to use for logging in to the admin
pages</Comment>
+ <ProposedValue>perfsonarpass</ProposedValue>
+ <Group order="2">Administration</Group>
+ </property>
+
+
+
+
+
+
+ <property>
+ <entry key="service.r.service_name" required="true">CL-MP</entry>
+ <Comment>Enter the service name</Comment>
+ <ProposedValue>CL-MP</ProposedValue>
+ <Group order="1">LS</Group>
+ </property>
+
+ <property>
+ <entry key="service.r.service_description">Command Line MP</entry>
+ <Comment>Give a description of the service</Comment>
+ <ProposedValue>Command Line MP</ProposedValue>
+ <Group order="2">LS</Group>
+ </property>
+
+ <property>
+ <entry
key="service.r.contact_email">email@address</entry>
+ <Comment>Enter the email address of the person administrating the
service</Comment>
+
<ProposedValue>email@address</ProposedValue>
+ <Group order="3">LS</Group>
+ </property>
+
+ <property>
+ <entry key="service.r.organization_name">organization_name</entry>
+ <Comment>Enter the name of the organization running this
service.</Comment>
+ <ProposedValue>organization_name</ProposedValue>
+ <Group order="4">LS</Group>
+ </property>
+
+ <property>
+ <entry key="service.r.ls_url"
required="true">http://address:port/service.name/services/LookupService</entry>
+ <Comment>Give the LS url</Comment>
+
<ProposedValue>http://address:port/service.name/services/LookupService</ProposedValue>
+ <Group order="5">LS</Group>
+ </property>
+
+ <property>
+ <entry key="component.registrator.interval">30000</entry>
+ <Comment>Give the registration interval</Comment>
+ <ProposedValue>30000</ProposedValue>
+ <Group order="6">LS</Group>
+ </property>
+
+ <property>
+ <entry key="service.r.access_point"
required="true">http://mpaddress:8180/perfsonar-clmp/services/CommandLineService</entry>
+ <Comment>Give the service access point</Comment>
+
<ProposedValue>http://mpaddress:8080/perfsonar-clmp/services/CommandLineService</ProposedValue>
+ <Group order="7">LS</Group>
+ </property>
+
+
+
+</properties>

Modified: trunk/rnp_java-cl-mp/conf/wizardproperties.dtd
===================================================================
--- trunk/rnp_java-cl-mp/conf/wizardproperties.dtd 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/conf/wizardproperties.dtd 2008-09-22 13:59:50
UTC (rev 4526)
@@ -1,22 +1,22 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
- <!-- DTD for wizard properties -->
- <!ELEMENT properties ( comment?, property* )>
- <!ATTLIST properties version CDATA #FIXED "0.1">
- <!ELEMENT comment (#PCDATA) >
- <!ELEMENT property
(entry,Comment,ProposedValue,Group+,AcceptedValue*) >
- <!ELEMENT entry (#PCDATA) >
- <!ATTLIST entry
- key CDATA #REQUIRED
- password (true|false) #IMPLIED
- required (true|false) #IMPLIED >
- <!ELEMENT Comment (#CDATA) >
- <!ELEMENT ProposedValue (#PCDATA) >
- <!ELEMENT Group (#PCDATA) >
- <!ATTLIST Group
- order CDATA #REQUIRED
- check (true|false) #IMPLIED
- >
- <!ELEMENT AcceptedValue (#PCDATA) >
-
+<?xml version="1.0" encoding="UTF-8"?>
+
+ <!-- DTD for wizard properties -->
+ <!ELEMENT properties ( comment?, property* )>
+ <!ATTLIST properties version CDATA #FIXED "0.1">
+ <!ELEMENT comment (#PCDATA) >
+ <!ELEMENT property
(entry,Comment,ProposedValue,Group+,AcceptedValue*) >
+ <!ELEMENT entry (#PCDATA) >
+ <!ATTLIST entry
+ key CDATA #REQUIRED
+ password (true|false) #IMPLIED
+ required (true|false) #IMPLIED >
+ <!ELEMENT Comment (#CDATA) >
+ <!ELEMENT ProposedValue (#PCDATA) >
+ <!ELEMENT Group (#PCDATA) >
+ <!ATTLIST Group
+ order CDATA #REQUIRED
+ check (true|false) #IMPLIED
+ >
+ <!ELEMENT AcceptedValue (#PCDATA) >
+

\ No newline at end of file

Modified: trunk/rnp_java-cl-mp/doc/CLMP Functional Specification.doc
===================================================================
(Binary files differ)

Modified: trunk/rnp_java-cl-mp/doc/CLMP Interface Specification.doc
===================================================================
(Binary files differ)

Modified: trunk/rnp_java-cl-mp/doc/Changelog.txt
===================================================================
--- trunk/rnp_java-cl-mp/doc/Changelog.txt 2008-09-22 12:46:40 UTC (rev
4525)
+++ trunk/rnp_java-cl-mp/doc/Changelog.txt 2008-09-22 13:59:50 UTC (rev
4526)
@@ -1,14 +1,22 @@
-v2.0:
-
-- New: Authentication Functionality added.
-- New: Configuration via a Servlet (WebAdmin).
-- New: Scheduling of measurements through a Cron-Like Scheduler Component
(new eventType: cron/2.0).
-- New: Inter-Service communication with SQL-MA to store scheduled
measurement results.
-- Change: Improved Internal Resource Protector, better implementation using
Java Semaphores.
-- Change: EventType to Tools Classes mapping via structured xml file
instead of hardcoded.
-- Change: Smarter definition for tools exec timeouts, specially BWCTL.
-- Change: Old simple eventTypes no longer supported (i.e. bwctl), fully
qualified eventTypes must now be used (i.e.
http://ggf.org/ns/nmwg/tools/bwctl/2.0)
-- Bug fix: When a ping request is made with packets of size smaller than 8
bytes, the ping command-line tool doesn't gives the RTT value. CL-MP will now
have datums without the value and valueUnits attributes for this case.
-- Bug Fix: Traceroute's parameter displayTtl is now being ignored due to
differences in implementations of some linux distributions.
-
+v2.1:
+
+NEW: Added a new eventType for summarized owamp measurements (-M switch),
http://ggf.org/ns/nmwg/tools/owamp/summary/2.0
+NEW: SelfTest functionality added. Works modularly - calls external scripts
defined in conf/selfTest-map.xml and expects "success" or "error" on the
first line and the reasons next.
+NEW: Log4j properties file for logging to a Syslog server added
+Change: Some classes were changed for internal self-testing
(componentsInitialization).
+Change: Using nmwg-1.0.20080916, perfsonar-base-1.0.20080902 and
perfsonar-web-admin-0.9.2b
+
+v2.0:
+
+- New: Authentication Functionality added.
+- New: Configuration via a Servlet (WebAdmin).
+- New: Scheduling of measurements through a Cron-Like Scheduler Component
(new eventType: cron/2.0).
+- New: Inter-Service communication with SQL-MA to store scheduled
measurement results.
+- Change: Improved Internal Resource Protector, better implementation using
Java Semaphores.
+- Change: EventType to Tools Classes mapping via structured xml file
instead of hardcoded.
+- Change: Smarter definition for tools exec timeouts, specially BWCTL.
+- Change: Old simple eventTypes no longer supported (i.e. bwctl), fully
qualified eventTypes must now be used (i.e.
http://ggf.org/ns/nmwg/tools/bwctl/2.0)
+- Bug fix: When a ping request is made with packets of size smaller than 8
bytes, the ping command-line tool doesn't gives the RTT value. CL-MP will now
have datums without the value and valueUnits attributes for this case.
+- Bug Fix: Traceroute's parameter displayTtl is now being ignored due to
differences in implementations of some linux distributions.
+
Using perfsonar-base-1.0.20080422, nmwg-1.0.20080124,
perfsonar-web-admin-0.8.5b.jar.
\ No newline at end of file

Modified: trunk/rnp_java-cl-mp/doc/schema/errorResponse.rnc
===================================================================
--- trunk/rnp_java-cl-mp/doc/schema/errorResponse.rnc 2008-09-22 12:46:40
UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/doc/schema/errorResponse.rnc 2008-09-22 13:59:50
UTC (rev 4526)
@@ -17,7 +17,7 @@
attribute messageIdRef { xsd:string }

Type =
- attribute type { "ErrorResponse" }
+ attribute type { "MeasurementResponse" | "ErrorResponse" }

Metadata =
element nmwg:metadata {

Added: trunk/rnp_java-cl-mp/doc/schema/nmtime.rnc

Added: trunk/rnp_java-cl-mp/doc/schema/owampSummaryRequest.rnc

Added: trunk/rnp_java-cl-mp/doc/schema/owampSummaryResponse.rnc

Deleted: trunk/rnp_java-cl-mp/lib/misc/perfsonar-base-ant-1.0.20080331.jar

Added: trunk/rnp_java-cl-mp/lib/misc/perfsonar-base-ant-1.0.20080416.jar


Property changes on:
trunk/rnp_java-cl-mp/lib/misc/perfsonar-base-ant-1.0.20080416.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream

Added: trunk/rnp_java-cl-mp/packaging/deb/changelog

Added: trunk/rnp_java-cl-mp/packaging/deb/compat

Added: trunk/rnp_java-cl-mp/packaging/deb/conffiles

Added: trunk/rnp_java-cl-mp/packaging/deb/control

Added: trunk/rnp_java-cl-mp/packaging/deb/copyright

Added: trunk/rnp_java-cl-mp/packaging/deb/dirs

Added: trunk/rnp_java-cl-mp/packaging/deb/docs

Added: trunk/rnp_java-cl-mp/packaging/deb/install

Added: trunk/rnp_java-cl-mp/packaging/deb/postinst

Added: trunk/rnp_java-cl-mp/packaging/deb/postrm

Added: trunk/rnp_java-cl-mp/packaging/deb/preinst

Added: trunk/rnp_java-cl-mp/packaging/deb/prerm

Added: trunk/rnp_java-cl-mp/packaging/deb/rules

Added: trunk/rnp_java-cl-mp/packaging/rpm/perfsonar-clmp.specs

Added: trunk/rnp_java-cl-mp/pom.xml

Added: trunk/rnp_java-cl-mp/samples/requests/BWCTLTCPRequest.xml

Added: trunk/rnp_java-cl-mp/samples/requests/BWCTLUDPRequest.xml

Modified: trunk/rnp_java-cl-mp/samples/requests/CronAddOwamp.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/requests/CronAddOwamp.xml 2008-09-22
12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/requests/CronAddOwamp.xml 2008-09-22
13:59:50 UTC (rev 4526)
@@ -15,7 +15,7 @@
<nmwg:eventType>http://ggf.org/ns/nmwg/tools/owamp/2.0</nmwg:eventType>
<owamp:parameters id="param2">
<nmwg:parameter name="count">5</nmwg:parameter>
- <nmwg:parameter name="portRange">2500-2999</nmwg:parameter>
+ <nmwg:parameter name="portRange">2500-2999</nmwg:parameter>
<nmwg:parameter name="direction">to</nmwg:parameter>
</owamp:parameters>
</nmwg:metadata>

Modified: trunk/rnp_java-cl-mp/samples/requests/CronAddPing.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/requests/CronAddPing.xml 2008-09-22
12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/requests/CronAddPing.xml 2008-09-22
13:59:50 UTC (rev 4526)
@@ -29,7 +29,7 @@
<nmwg:parameter name="hours">*</nmwg:parameter>
<nmwg:parameter name="dom">*</nmwg:parameter>
<nmwg:parameter name="months">*</nmwg:parameter>
- <nmwg:parameter name="dow">*</nmwg:parameter>
+ <nmwg:parameter name="dow">*</nmwg:parameter>
<nmwg:parameter name="ma">local</nmwg:parameter>
</cron:parameters>
</nmwg:metadata>

Modified: trunk/rnp_java-cl-mp/samples/requests/EchoRequest.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/requests/EchoRequest.xml 2008-09-22
12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/requests/EchoRequest.xml 2008-09-22
13:59:50 UTC (rev 4526)
@@ -1,16 +1,16 @@
-<!-- $Id: EchoRequest.xml 2614 2007-08-09 11:34:54Z roman $ -->
-
-
-<nmwg:message type="EchoRequest"
- id="id1"
- xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
-
-
- <nmwg:metadata id="meta">
-
<nmwg:eventType>http://schemas.perfsonar.net/tools/admin/echo/2.0</nmwg:eventType>
- </nmwg:metadata>
-
- <nmwg:data id="data" metadataIdRef="meta"/>
-
-
+<!-- $Id: EchoRequest.xml 2614 2007-08-09 11:34:54Z roman $ -->
+
+
+<nmwg:message type="EchoRequest"
+ id="id1"
+ xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
+
+
+ <nmwg:metadata id="meta">
+
<nmwg:eventType>http://schemas.perfsonar.net/tools/admin/echo/2.0</nmwg:eventType>
+ </nmwg:metadata>
+
+ <nmwg:data id="data" metadataIdRef="meta"/>
+
+
</nmwg:message>
\ No newline at end of file

Modified: trunk/rnp_java-cl-mp/samples/requests/LookupInfoRequest.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/requests/LookupInfoRequest.xml 2008-09-22
12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/requests/LookupInfoRequest.xml 2008-09-22
13:59:50 UTC (rev 4526)
@@ -1,14 +1,14 @@
-<!-- $Id: LookupInfoRequest.xml 2612 2007-08-09 10:54:43Z roman $ -->
-
-
-<nmwg:message type="LookupInfoRequest"
- id="id1"
- xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
-
- <nmwg:metadata id="meta">
-
<nmwg:eventType>http://schemas.perfsonar.net/tools/admin/lookupinfo/2.0</nmwg:eventType>
- </nmwg:metadata>
-
- <nmwg:data id="data" metadataIdRef="meta"/>
-
+<!-- $Id: LookupInfoRequest.xml 2612 2007-08-09 10:54:43Z roman $ -->
+
+
+<nmwg:message type="LookupInfoRequest"
+ id="id1"
+ xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
+
+ <nmwg:metadata id="meta">
+
<nmwg:eventType>http://schemas.perfsonar.net/tools/admin/lookupinfo/2.0</nmwg:eventType>
+ </nmwg:metadata>
+
+ <nmwg:data id="data" metadataIdRef="meta"/>
+
</nmwg:message>
\ No newline at end of file

Added: trunk/rnp_java-cl-mp/samples/requests/OWAMPRequest.xml

Added: trunk/rnp_java-cl-mp/samples/requests/OWAMPSummaryRequest.xml

Added: trunk/rnp_java-cl-mp/samples/requests/PingRequest.xml

Added: trunk/rnp_java-cl-mp/samples/requests/TracerouteRequest.xml

Added: trunk/rnp_java-cl-mp/samples/responses/BWCTLTCPResponse.xml

Added: trunk/rnp_java-cl-mp/samples/responses/BWCTLUDPResponse.xml

Modified: trunk/rnp_java-cl-mp/samples/responses/CronAddPingResponse.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/responses/CronAddPingResponse.xml
2008-09-22 12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/responses/CronAddPingResponse.xml
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,12 +1,12 @@
-<nmwg:message id="msg1_resp" messageIdRef="msg1"
- type="MeasurementResponse"
+<nmwg:message id="msg1_resp" messageIdRef="msg1"
+ type="MeasurementResponse"
xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
<nmwg:metadata id="resultCodeMetadata">
<nmwg:eventType>
success.mp.clmp.cron.entryInsert
</nmwg:eventType>
</nmwg:metadata>
- <nmwg:data id="resultDescriptionData_for_resultCodeMetadata"
+ <nmwg:data id="resultDescriptionData_for_resultCodeMetadata"
metadataIdRef="resultCodeMetadata">
<nmwgr:datum xmlns:nmwgr="http://ggf.org/ns/nmwg/result/2.0/";>
CommandLineCronComponent: entry successfully added.
Your key

Modified: trunk/rnp_java-cl-mp/samples/responses/CronListResponse.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/responses/CronListResponse.xml 2008-09-22
12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/responses/CronListResponse.xml 2008-09-22
13:59:50 UTC (rev 4526)
@@ -1,14 +1,14 @@
-<nmwg:message id="msg1_resp" messageIdRef="msg1"
- type="MeasurementResponse"
+<nmwg:message id="msg1_resp" messageIdRef="msg1"
+ type="MeasurementResponse"
xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
<nmwg:metadata id="cron-owampRequest-1190178768741">
- <cron:subject id="subj"
- metadataIdRef="owampRequest-1190178768741"
+ <cron:subject id="subj"
+ metadataIdRef="owampRequest-1190178768741"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c77"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c77"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -16,24 +16,24 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c78">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c79">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"
value="owampRequest-1190178768741" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="mp2-popsc-mp2-poprj-1190176595167">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-rj.rnp.br" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -42,14 +42,14 @@
<nmwg:eventType>ping</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="1o-agendamento-1191898972467">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="www.perfsonar.net" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -58,13 +58,13 @@
<nmwg:eventType>ping</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="cron-mp2-popsc-mp2-poprj-1190180099516">
- <cron:subject id="subj"
- metadataIdRef="mp2-popsc-mp2-poprj-1190180099516"
+ <cron:subject id="subj"
+ metadataIdRef="mp2-popsc-mp2-poprj-1190180099516"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7a"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7a"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -72,24 +72,24 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/3" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7b">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7c">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"

value="mp2-popsc-mp2-poprj-1190180099516" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="mp2-popsc-mp2-popsp-1190180089344">
- <owamp:subject id="sub1"
+ <owamp:subject id="sub1"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-sp.rnp.br" />
</nmwgt:endPointPair>
</owamp:subject>
- <owamp:parameters id="param2"
+ <owamp:parameters id="param2"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
<nmwg:parameter
name="portRange">2500-2999</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -97,14 +97,14 @@
<nmwg:eventType>owamp</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="mp2-popsc-mp2-poprj-1190180099516">
- <owamp:subject id="sub1"
+ <owamp:subject id="sub1"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-rj.rnp.br" />
</nmwgt:endPointPair>
</owamp:subject>
- <owamp:parameters id="param2"
+ <owamp:parameters id="param2"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
<nmwg:parameter
name="portRange">2500-2999</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -112,14 +112,14 @@
<nmwg:eventType>owamp</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="owampRequest-1190178768741">
- <owamp:subject id="sub2"
+ <owamp:subject id="sub2"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-sp.rnp.br" />
</nmwgt:endPointPair>
</owamp:subject>
- <owamp:parameters id="param2"
+ <owamp:parameters id="param2"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
<nmwg:parameter
name="portRange">2500-2999</nmwg:parameter>
<nmwg:parameter name="count">5</nmwg:parameter>
@@ -127,12 +127,12 @@
<nmwg:eventType>owamp</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="cron-teste-1190178255618">
- <cron:subject id="subj" metadataIdRef="teste-1190178255618"
+ <cron:subject id="subj" metadataIdRef="teste-1190178255618"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7d"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7d"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -140,23 +140,23 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/5" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7e">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c7f">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"
value="teste-1190178255618" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="cron-mp2-popsc-mp2-popsp-1190176584979">
- <cron:subject id="subj"
- metadataIdRef="mp2-popsc-mp2-popsp-1190176584979"
+ <cron:subject id="subj"
+ metadataIdRef="mp2-popsc-mp2-popsp-1190176584979"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c80"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c80"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -164,23 +164,23 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/5" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c81">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c82">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"

value="mp2-popsc-mp2-popsp-1190176584979" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="cron-mp2-popsc-mp2-popmg-1190180109692">
- <cron:subject id="subj"
- metadataIdRef="mp2-popsc-mp2-popmg-1190180109692"
+ <cron:subject id="subj"
+ metadataIdRef="mp2-popsc-mp2-popmg-1190180109692"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c83"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c83"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -188,22 +188,22 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/3" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c84">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c85">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"

value="mp2-popsc-mp2-popmg-1190180109692" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="cron-teste-1190178288796">
- <cron:subject id="subj" metadataIdRef="teste-1190178288796"
+ <cron:subject id="subj" metadataIdRef="teste-1190178288796"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c86"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c86"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -211,23 +211,23 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c87">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c88">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"
value="teste-1190178288796" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="cron-mp2-popsc-mp2-popsp-1190180089344">
- <cron:subject id="subj"
- metadataIdRef="mp2-popsc-mp2-popsp-1190180089344"
+ <cron:subject id="subj"
+ metadataIdRef="mp2-popsc-mp2-popsp-1190180089344"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c89"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c89"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -235,24 +235,24 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/3" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8a">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8b">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"

value="mp2-popsc-mp2-popsp-1190180089344" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="teste-1190178255618">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="www.perfsonar.net" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -261,14 +261,14 @@
<nmwg:eventType>ping</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="mp2-popsc-mp2-popsp-1190176584979">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-sp.rnp.br" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -277,14 +277,14 @@
<nmwg:eventType>ping</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="mp2-popsc-mp2-popmg-1190176605335">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-mg.rnp.br" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -293,14 +293,14 @@
<nmwg:eventType>ping</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="teste-1190178288796">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="www.perfsonar.net" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -309,13 +309,13 @@
<nmwg:eventType>ping</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="cron-mp2-popsc-mp2-poprj-1190176595167">
- <cron:subject id="subj"
- metadataIdRef="mp2-popsc-mp2-poprj-1190176595167"
+ <cron:subject id="subj"
+ metadataIdRef="mp2-popsc-mp2-poprj-1190176595167"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8c"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8c"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -323,23 +323,23 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/5" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8d">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8e">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"

value="mp2-popsc-mp2-poprj-1190176595167" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="cron-mp2-popsc-mp2-popmg-1190176605335">
- <cron:subject id="subj"
- metadataIdRef="mp2-popsc-mp2-popmg-1190176605335"
+ <cron:subject id="subj"
+ metadataIdRef="mp2-popsc-mp2-popmg-1190176605335"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8f"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c8f"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -347,24 +347,24 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/5" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c90">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c91">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"

value="mp2-popsc-mp2-popmg-1190176605335" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="mp2-popsc-mp2-popmg-1190180109692">
- <owamp:subject id="sub1"
+ <owamp:subject id="sub1"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="mp2.pop-mg.rnp.br" />
</nmwgt:endPointPair>
</owamp:subject>
- <owamp:parameters id="param2"
+ <owamp:parameters id="param2"
xmlns:owamp="http://ggf.org/ns/nmwg/tools/owamp/2.0/";>
<nmwg:parameter
name="portRange">2500-2999</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>
@@ -372,13 +372,13 @@
<nmwg:eventType>owamp</nmwg:eventType>
</nmwg:metadata>
<nmwg:metadata id="cron-1o-agendamento-1191898972467">
- <cron:subject id="subj"
- metadataIdRef="1o-agendamento-1191898972467"
+ <cron:subject id="subj"
+ metadataIdRef="1o-agendamento-1191898972467"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
- id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c92"
+ <cron:parameters
+ id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c92"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
- <nmwg:parameter name="ma"
+ <nmwg:parameter name="ma"

value="http://150.162.248.40:8080/perfSONAR-SQL-MA-1.0/services/MeasurementArchiveService";
/>
<nmwg:parameter name="months" value="*" />
<nmwg:parameter name="dom" value="*" />
@@ -386,15 +386,15 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c93">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.7a40de19:1177a0f08c9:6c94">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"
value="1o-agendamento-1191898972467"
/>
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
- <nmwg:data id="1"
+ <nmwg:data id="1"
metadataIdRef="cron-mp2-popsc-mp2-popsp-1190176584979" />
</nmwg:message>

Modified: trunk/rnp_java-cl-mp/samples/responses/CronListSpecificResponse.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/responses/CronListSpecificResponse.xml
2008-09-22 12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/responses/CronListSpecificResponse.xml
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,12 +1,12 @@
-<nmwg:message id="msg1_resp" messageIdRef="msg1"
- type="MeasurementResponse"
+<nmwg:message id="msg1_resp" messageIdRef="msg1"
+ type="MeasurementResponse"
xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
<nmwg:metadata id="cron-schedule-test-1200432073238">
- <cron:subject id="subj"
- metadataIdRef="schedule-test-1200432073238"
+ <cron:subject id="subj"
+ metadataIdRef="schedule-test-1200432073238"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/"; />
- <cron:parameters
-
id="localhost.pop-sc.rnp.br.2e587350:1177f52aef0:-7f63"
+ <cron:parameters
+
id="localhost.pop-sc.rnp.br.2e587350:1177f52aef0:-7f63"
xmlns:cron="http://ggf.org/ns/nmwg/tools/cron/2.0/";>
<nmwg:parameter name="ma" value="local" />
<nmwg:parameter name="months" value="*" />
@@ -15,24 +15,24 @@
<nmwg:parameter name="hours" value="*" />
<nmwg:parameter name="minutes" value="*/10" />
</cron:parameters>
- <nmwg:key
+ <nmwg:key

id="localhost.pop-sc.rnp.br.2e587350:1177f52aef0:-7f62">
- <nmwg:parameters
+ <nmwg:parameters

id="localhost.pop-sc.rnp.br.2e587350:1177f52aef0:-7f61">
- <nmwg:parameter name="entryId"
+ <nmwg:parameter name="entryId"
value="schedule-test-1200432073238" />
</nmwg:parameters>
</nmwg:key>
</nmwg:metadata>
<nmwg:metadata id="schedule-test-1200432073238">
- <ping:subject id="sub1"
+ <ping:subject id="sub1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
- <nmwgt:endPointPair
+ <nmwgt:endPointPair

xmlns:nmwgt="http://ggf.org/ns/nmwg/topology/2.0/";>
<nmwgt:dst type="ipv4"
value="www.perfsonar.net" />
</nmwgt:endPointPair>
</ping:subject>
- <ping:parameters id="param1"
+ <ping:parameters id="param1"
xmlns:ping="http://ggf.org/ns/nmwg/tools/ping/2.0/";>
<nmwg:parameter name="ttl">255</nmwg:parameter>
<nmwg:parameter name="count">10</nmwg:parameter>

Modified: trunk/rnp_java-cl-mp/samples/responses/CronModifyResponse.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/responses/CronModifyResponse.xml
2008-09-22 12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/responses/CronModifyResponse.xml
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,13 +1,13 @@
-<nmwg:message id="msg1_resp" messageIdRef="msg1"
- type="MeasurementResponse"
- xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
- <nmwg:metadata id="resultCodeMetadata">
- <nmwg:eventType>success.mp.clmp.cron.modify</nmwg:eventType>
- </nmwg:metadata>
- <nmwg:data id="resultDescriptionData_for_resultCodeMetadata"
- metadataIdRef="resultCodeMetadata">
- <nmwgr:datum xmlns:nmwgr="http://ggf.org/ns/nmwg/result/2.0/";>
- CommandLineCronComponent: entry successfully modified.
- </nmwgr:datum>
- </nmwg:data>
+<nmwg:message id="msg1_resp" messageIdRef="msg1"
+ type="MeasurementResponse"
+ xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
+ <nmwg:metadata id="resultCodeMetadata">
+ <nmwg:eventType>success.mp.clmp.cron.modify</nmwg:eventType>
+ </nmwg:metadata>
+ <nmwg:data id="resultDescriptionData_for_resultCodeMetadata"
+ metadataIdRef="resultCodeMetadata">
+ <nmwgr:datum xmlns:nmwgr="http://ggf.org/ns/nmwg/result/2.0/";>
+ CommandLineCronComponent: entry successfully modified.
+ </nmwgr:datum>
+ </nmwg:data>
</nmwg:message>
\ No newline at end of file

Modified: trunk/rnp_java-cl-mp/samples/responses/CronRemoveResponse.xml
===================================================================
--- trunk/rnp_java-cl-mp/samples/responses/CronRemoveResponse.xml
2008-09-22 12:46:40 UTC (rev 4525)
+++ trunk/rnp_java-cl-mp/samples/responses/CronRemoveResponse.xml
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,12 +1,12 @@
-<nmwg:message id="msg1_resp" messageIdRef="msg1"
- type="MeasurementResponse"
+<nmwg:message id="msg1_resp" messageIdRef="msg1"
+ type="MeasurementResponse"
xmlns:nmwg="http://ggf.org/ns/nmwg/base/2.0/";>
<nmwg:metadata id="resultCodeMetadata">
<nmwg:eventType>
success.mp.clmp.cron.entryRemoval
</nmwg:eventType>
</nmwg:metadata>
- <nmwg:data id="resultDescriptionData_for_resultCodeMetadata"
+ <nmwg:data id="resultDescriptionData_for_resultCodeMetadata"
metadataIdRef="resultCodeMetadata">
<nmwgr:datum xmlns:nmwgr="http://ggf.org/ns/nmwg/result/2.0/";>
CommandLineCronComponent: 1 entry(ies) successfully
removed.

Added: trunk/rnp_java-cl-mp/samples/responses/ErrorResponse.xml

Added: trunk/rnp_java-cl-mp/samples/responses/OWAMPResponse.xml

Added: trunk/rnp_java-cl-mp/samples/responses/OWAMPSummaryResponse.xml

Added: trunk/rnp_java-cl-mp/samples/responses/PingResponse.xml

Added: trunk/rnp_java-cl-mp/samples/responses/TracerouteResponse.xml

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineCronComponent.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineCronComponent.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineCronComponent.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -8,6 +8,7 @@
import java.io.UnsupportedEncodingException;
import java.nio.ByteBuffer;
import java.nio.channels.FileChannel;
+import java.util.ArrayList;
import java.util.Calendar;
import java.util.HashMap;
import java.util.Iterator;
@@ -71,6 +72,10 @@

private String defaultMa;

+ private Boolean initializationSuccesful = null;
+
+ private List<String> initializationErrorMessages = new
ArrayList<String>();
+
// ---------------------------------- constructors

public CommandLineCronComponent() throws PerfSONARException {
@@ -81,7 +86,8 @@

.getInstance().getComponent(ComponentNames.LOGGER);

} catch (PerfSONARException e) {
-
+ addInitializationErrorMessage(
+ CNAME+": Couldn't get logger component.");
throw new PerfSONARException("error.common.no_logger",

"CommandLineCronComponent.initComponent: "
+ "Cannot get logger
component");
@@ -94,7 +100,8 @@

.getInstance().getComponent(ComponentNames.CONFIG);

} catch (PerfSONARException e) {
-
+ addInitializationErrorMessage(
+ CNAME+": Couldn't get configuration
component.");
throw new
PerfSONARException("error.common.no_configuration",

"CommandLineCronComponent.initComponent: "
+ "Cannot get config
component");
@@ -102,7 +109,12 @@
}

}
-
+
+ private void addInitializationErrorMessage(String error){
+ initializationSuccesful = false;
+ initializationErrorMessages.add(error);
+ }
+
// ---------------------------------- public methods

public String getComponentName() {
@@ -115,6 +127,14 @@

}

+ public List<String> getInitializationErrorMessages() {
+ return initializationErrorMessages;
+ }
+
+ public Boolean wasInitializationSuccesful() {
+ return initializationSuccesful;
+ }
+
/**
* Scheduler action
*/
@@ -170,31 +190,34 @@
String schedulerVal = configuration

.getProperty("component.mp.scheduler_component");

- logger.debug(CNAME + ".initComponent: "
- + "LSCleanupLoader: parameter
SCHEDULER = " + schedulerVal);
-
scheduler = (Scheduler)
AuxiliaryComponentManager.getInstance()
.getComponent(schedulerVal);

- if (scheduler == null)
+ if (scheduler == null){
+ addInitializationErrorMessage(
+ CNAME+": No scheduler component in
AuxiliaryComponentManager.");
throw new
PerfSONARException("error.common.no_scheduler", CNAME
+ ".initComponent: "
+ "No scheduler component in
AuxiliaryComponentManager");
+ }

} catch (PerfSONARException e) {
-
+ addInitializationErrorMessage(
+ CNAME+": Couldn't get scheduler component.");
throw new
PerfSONARException("error.common.no_scheduler", CNAME
- + ".initComponent:"
- + "LSCleanupLoader: no
[component.ma.scheduler_component] "
- + "parameter. " + e.getMessage());
+ + ".initComponent: Couldn't get
scheduler component. " +
+ "Check 'component.mp.scheduler_component'
parameter. " +
+ "Error: " + e.getMessage());

}

// add cleanup action to scheduler
scheduler.addSchedulerTask(RUN_INTERVAL, this);
-
+
+ if(initializationSuccesful == null)
+ initializationSuccesful = true;
}
-
+
public Message add(String entryString, Message reqMess)
throws PerfSONARException {

@@ -211,8 +234,7 @@
if (metadata.getMetadataIdRef().length() > 0)
{
metadata =
reqMess.getMetadata(metadata.getMetadataIdRef());
} else {
- logger
- .fatal(CNAME
+ logger.debug(CNAME
+ ":
Request must have at least one EventType defined other than schedule.");
throw new PerfSONARException(

"error.mp.clmp.validator.no_metadata_eventType",
@@ -573,8 +595,11 @@

public void loadDatabase() throws PerfSONARException {

- cronPath = configuration.getProperty("service.clmp.cron_dir");
- if (cronPath == null){
+ try {
+ cronPath =
configuration.getProperty("service.clmp.cron_dir");
+ } catch (PerfSONARException e1) {
+ addInitializationErrorMessage(
+ CNAME+": Couldn't get 'service.clmp.cron_dir'
from configuration.");
logger.fatal(

"CommandLineCronComponent.loadDatabase: "
+ "Couldn't get
'service.clmp.cron_dir' from configuration.");
@@ -584,8 +609,11 @@
+ "Couldn't get
'service.clmp.cron_dir' from configuration.");
}

- defaultMa =
configuration.getProperty("service.clmp.default_ma");
- if (defaultMa == null){
+ try {
+ defaultMa =
configuration.getProperty("service.clmp.default_ma");
+ } catch (PerfSONARException e1) {
+ addInitializationErrorMessage(
+ CNAME+": Couldn't get
'service.clmp.default_ma' from configuration.");
logger.fatal(

"CommandLineCronComponent.loadDatabase: "
+ "Couldn't get
'service.clmp.default_ma' from configuration.");
@@ -617,12 +645,12 @@
}

} catch (Exception e) {
-
+ addInitializationErrorMessage(
+ CNAME+": Error trying to access database:
"+e.getMessage());
logger

.debug("CommandLineCronComponent.loadDatabase: "
+ "Exception caught
while trying to access cron database file."
+ e.getMessage());
-
throw new PerfSONARException(
"error.mp.clmp.cron.database_error",

"CommandLineCronComponent.loadDatabase: "
@@ -631,9 +659,8 @@
}

totalEntries = total;
- logger
- .debug("CommandLineCronComponent - Database
loaded, totalEntries: "
- + totalEntries);
+ logger.debug("CommandLineCronComponent: Database loaded, " +
+ "totalEntries: "+ totalEntries);
}

private Metadata stringToMetadata(String str) {

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineMPServiceEngine.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineMPServiceEngine.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineMPServiceEngine.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -22,6 +22,7 @@
import org.perfsonar.base.auxiliary.ComponentNames;
import org.perfsonar.base.auxiliary.components.logger.LoggerComponent;
import org.perfsonar.base.exceptions.PerfSONARException;
+import org.perfsonar.service.base.engine.ActionType;
import org.perfsonar.service.base.engine.ServiceEngine;

/**
@@ -140,7 +141,10 @@
return action.makeMeasurement(reqMess);

}
- else {
+ else if (actionType.equals(ActionType.ECHO)){
+ return CommandLineSelfTest.doSelfTest(reqMess);
+ }
+ else{

logger.fatal(
"CommandLineMPServiceEngine.takeAction: ActionType
specified: "

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineResourceProtector.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineResourceProtector.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineResourceProtector.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,7 +1,9 @@
package org.perfsonar.service.measurementPoint.commandLine;

+import java.util.ArrayList;
import java.util.HashMap;
import java.util.Iterator;
+import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.Semaphore;
@@ -25,15 +27,17 @@

private LoggerComponent logger = null;

- private ConfigurationComponent configuration = null;
-
// -------------------------------------------- class fields

private HashMap<String,Semaphore> semaphores = new
HashMap<String,Semaphore>();
+
+ private Boolean initializationSuccesful = null;
+
+ private List<String> initializationErrorMessages = new
ArrayList<String>();

// ---------------------------------- constructors

- public CommandLineResourceProtector() throws PerfSONARException {
+ public CommandLineResourceProtector() throws PerfSONARException {

try {

@@ -41,26 +45,13 @@
.getInstance().getComponent(ComponentNames.LOGGER);

} catch (PerfSONARException e) {
-
+ initializationSuccesful = false;
+ initializationErrorMessages.add(
+ CNAME+": Couldn't get logger component.");
throw new PerfSONARException("error.common.no_logger",
- "CommandLineCronComponent.initComponent: "
- + "Cannot get logger component");
-
+ CNAME+".initComponent: Cannot get logger component");
}

- try {
-
- this.configuration = (ConfigurationComponent)
AuxiliaryComponentManager
- .getInstance().getComponent(ComponentNames.CONFIG);
-
- } catch (PerfSONARException e) {
-
- throw new PerfSONARException("error.common.no_configuration",
- "CommandLineCronComponent.initComponent: "
- + "Cannot get config component");
-
- }
-
}

// ---------------------------------- public methods
@@ -71,11 +62,18 @@

}

-
public void setComponentName(String name) {

}

+ public List<String> getInitializationErrorMessages() {
+ return initializationErrorMessages;
+ }
+
+ public Boolean wasInitializationSuccesful() {
+ return initializationSuccesful;
+ }
+
// ---------------------- component that loads action to scheduler

public void initComponent() throws PerfSONARException {
@@ -88,7 +86,11 @@
try {
restrictions = psd.getServiceDescription();
}catch(PerfSONARException e){
-
+ initializationSuccesful = false;
+ initializationErrorMessages.add(
+ CNAME+": Couldn't initialize restrictions:
"+e.getMessage());
+ logger.fatal(initializationErrorMessages.get(0));
+ return;
}

Set<String> keys = restrictions.keySet();
@@ -97,14 +99,27 @@
while (iterator.hasNext()){
String key = (String) iterator.next();
try{
- semaphores.put(key, new
Semaphore(Integer.parseInt(restrictions.get(key)), true));
- logger.debug(
- CNAME + " Defining max threads for "+key+" as
"+restrictions.get(key));
+ int nthreads =
Integer.parseInt(restrictions.get(key));
+ if(nthreads > 0){
+ semaphores.put(key, new Semaphore(nthreads,
true));
+ logger.debug(
+ CNAME + ": Defining max
threads for "+key+" as "+restrictions.get(key));
+ }else{
+ logger.debug(
+ CNAME + ": Disabling tool
"+key+".");
+ }
}catch(NumberFormatException e){
-
+ initializationSuccesful = false;
+ initializationErrorMessages.add(
+ CNAME+": NumberFormatException when trying to
define" +
+ " max threads for "+key+" as
"+restrictions.get(key)+".");
+ logger.error(initializationErrorMessages.get(
+
initializationErrorMessages.size()-1));
}
- }
+ }

+ if(initializationSuccesful == null)
+ initializationSuccesful = true;
}


@@ -114,6 +129,12 @@

Semaphore semaphore = semaphores.get(tool);

+ if(semaphore == null){
+ throw new PerfSONARException("error.mp.clmp.tool_disabled",
+ CNAME + ": Tool " + cmdarr[0] + " has been disabled for
this service."
+ );
+ }
+
try {
semaphore.acquire();
} catch (InterruptedException e1) {

Added:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineSelfTest.java

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineToolBundleFactory.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineToolBundleFactory.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/CommandLineToolBundleFactory.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -48,8 +48,8 @@
static private Hashtable<String,String> m2c = null;
static private Hashtable<String,String> m2a = null;

- public static CommandLineToolBundle getCommandLineToolBundle(EventType
eventType)
- throws PerfSONARException{
+ public static CommandLineToolBundle getCommandLineToolBundle(
+ EventType eventType) throws PerfSONARException{

if (logger == null) {
// get a logger
@@ -83,18 +83,31 @@

}

- String toolsMapFile =
configManager.getProperty(toolsMapFileProperty);
+ String toolsMapFile = null;
+ try {
+ toolsMapFile =
configManager.getProperty(toolsMapFileProperty);
+ } catch (PerfSONARException e) {
+ logger.fatal("CommandLineToolBundleFactory: "
+
+ "Could not get
'"+toolsMapFileProperty+"' property.");
+ throw new
PerfSONARException("error.mp.clmp.mis_configuration",
+ "CommandLineToolBundleFactory: " +
+ "Could not get '"+toolsMapFileProperty+"'
property.");
+ }
+
List<Map<String,String>> toolsDef = null;
try{

Document dom = XMLUtils.convertXMLFileToDom(toolsMapFile);
toolsDef = XMLUtils.getNodeElementsFromDom(dom, "eventType",
- Arrays.asList(new String[]{ "name", "class",
"authentication" }));
+ Arrays.asList(new String[]{
+ "name", "class",
"authentication" }));

}catch(PerfSONARException e){
- logger.error("CommandLineToolBundleFactory: Could not create
tools hashtable. "
+ logger.error("CommandLineToolBundleFactory: " +
+ "Could not create tools hashtable. "
+ e.getMessage());
- throw new
PerfSONARException("error.mp.clmp.system.toolFactory.hashtable",
+ throw new PerfSONARException(
+ "error.mp.clmp.system.toolFactory.hashtable",
"CommandLineToolBundleFactory: "
+ "Could not create tools hashtable. "
+ "Cannot continue with the request");
@@ -104,26 +117,11 @@
m2a = new Hashtable<String,String>();

for(Map<String,String> toolDef : toolsDef){
- m2c.put(toolDef.get("name").toUpperCase(),
toolDef.get("class"));
- m2a.put(toolDef.get("name").toUpperCase(),
toolDef.get("authentication"));
+ m2c.put(toolDef.get("name").toUpperCase(),
+ toolDef.get("class"));
+ m2a.put(toolDef.get("name").toUpperCase(),
+ toolDef.get("authentication"));
}
- /*
- * XXX: Probably need a plug-in's directory and config info for
- * this, but for now just hardcode.
- m2c = new Hashtable();
- m2c.put("PING",
-
"org.perfsonar.service.measurementPoint.commandLine.tools.Ping");
- m2c.put("OWAMP",
-
"org.perfsonar.service.measurementPoint.commandLine.tools.Owamp");
- m2c.put("TRACEROUTE",
-
"org.perfsonar.service.measurementPoint.commandLine.tools.Traceroute");
- m2c.put("BWCTL",
-
"org.perfsonar.service.measurementPoint.commandLine.tools.Bwctl");
- m2c.put("HTTP://GGF.ORG/NS/NMWG/TOOLS/CRON",
-
"org.perfsonar.service.measurementPoint.commandLine.tools.Cron");
- m2c.put("HTTP://GGF.ORG/NS/NMWG/TOOLS/OWAMP/SUMMARY",
-
"org.perfsonar.service.measurementPoint.commandLine.tools.OwampSummary");
- */
}

// get the classname for this event type
@@ -141,29 +139,34 @@
logger.debug("CommandLineToolBundleFactory: classname asked for is "
+ className);

- //TODO: Find a better way to know if the measurement is being done
by the Scheduler component.
-
if(!Thread.currentThread().getStackTrace()[4].toString().contains("CronComponent")){
+ //TODO: Find a better way to know if the measurement is being done
by
+ // the Scheduler component.
+ if(!Thread.currentThread().getStackTrace()[4].toString()
+ .contains("CronComponent")){
// Check if tool needs authentication
String authentication = (String)
m2a.get(eventString.toUpperCase());

if(authentication != null &&
authentication.equalsIgnoreCase("yes")){
- SecurityToken st=new
SecurityToken(SecTokenManagerFactory.getDefaultSecTokenManager());
+ SecurityToken st= new SecurityToken(
+
SecTokenManagerFactory.getDefaultSecTokenManager());
if (!st.hasSecTokenInRequest()) {
throw new
PerfSONARException("error.authn.not_sectoken",
- "This tool requires
authentication. Please provide a security " +
- "token in the SOAP envelope of your
request.");
+ "This tool requires
authentication. " +
+ "Please provide a security
token in the SOAP " +
+ "envelope of your request.");
}
st.setSecTokenFromRequest();

- AuthNRequest authnReq=new AuthNRequest(st);
+ AuthNRequest authnReq = new AuthNRequest(st);

- AADispatchManager aadm=new
AADispatchManager(AADispatchProtocolFactory.getDefaultAADispatchProtocol());
+ AADispatchManager aadm = new AADispatchManager(
+
AADispatchProtocolFactory.getDefaultAADispatchProtocol());
AuthNResponse
authnRes=aadm.getAuthentication(authnReq);

if
(authnRes.getStatus()!=AuthNResponse.AUTHENTICATED) {
throw new
PerfSONARException(authnRes.getResultCode(),
- "This tool requires
authentication and the authentication " +
- "failed for your request.");
+ "This tool requires
authentication and the " +
+ "authentication failed for
your request.");
}
}
}
@@ -172,7 +175,6 @@
try {

// get a new class for that classname
-
//org.perfsonar.service.measurementPoint.commandLine.tools.Ping teste = new
org.perfsonar.service.measurementPoint.commandLine.tools.Ping();
tool = (CommandLineToolBundle)
Class.forName(className).newInstance();
}
catch (InstantiationException e) {

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Bwctl.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Bwctl.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Bwctl.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -529,15 +529,6 @@
br.close();
isr.close();
fis.close();
-
- try {
- if (os != null)
- os.delete();
- if (es != null)
- es.delete();
- }catch(Exception e){
-
- }
}
catch(IOException ioe)
{
@@ -549,17 +540,17 @@
"An error ocurred while trying to parse the results of
the request. Please try again. " +
"If this problem persists, contact the service
administrator."
);
+ }finally{
+ try {
+ if (os != null)
+ os.delete();
+ if (es != null)
+ es.delete();
+ }catch(Exception e){
+
+ }
}

- try {
- if (os != null)
- os.delete();
- if (es != null)
- es.delete();
- }catch(Exception e){
-
- }
-
Datum[][] datums = new Datum[datumList.length][];

datums[0] = new Datum[datumList[0].size()];

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Owamp.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Owamp.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Owamp.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -44,7 +44,7 @@

static private final String CNAME="OwampCommandLineToolBundle";

- private Hashtable toolOptions = null;
+ protected Hashtable toolOptions = null;

protected LoggerComponent logger = null;
protected CommandLineResourceProtector protector = null;
@@ -54,7 +54,7 @@
}

public String getToolName(){
- return "owamp";
+ return "owping";
}

public String getToolBundleVersion(){
@@ -321,17 +321,17 @@
"An error ocurred while trying to parse the results of
the request. Please try again. " +
"If this problem persists, contact the service
administrator."
);
+ }finally{
+ try {
+ if (os != null)
+ os.delete();
+ if (es != null)
+ es.delete();
+ }catch(Exception e){
+
+ }
}

- try {
-
- if (os != null)
- os.delete();
- if (es != null)
- es.delete();
- }catch(Exception e){
- }
-
Datum[] datums = new Datum[datumList.size()];
datumList.toArray(datums);


Added:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/OwampSummary.java

Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Ping.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Ping.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Ping.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -39,6 +39,7 @@
import org.perfsonar.service.measurementPoint.commandLine.CommandLineExec;
import
org.perfsonar.service.measurementPoint.commandLine.CommandLineResourceProtector;
import
org.perfsonar.service.measurementPoint.commandLine.CommandLineToolBundle;
+import org.perfsonar.service.measurementPoint.commandLine.utils.Constants;

public class Ping implements CommandLineToolBundle{

@@ -311,16 +312,17 @@
"An error ocurred while trying to parse the results of
the request. Please try again. " +
"If this problem persists, contact the service
administrator."
);
+ }finally{
+ try {
+ if (os != null)
+ os.delete();
+ if (es != null)
+ es.delete();
+ }catch(Exception e){
+
+ }
}

- try {
- if (os != null)
- os.delete();
- if (es != null)
- es.delete();
- }catch(Exception e){
- }
-
Datum[] datums = new Datum[datumList.size()];
datumList.toArray(datums);

@@ -331,8 +333,12 @@

public Ping() throws PerfSONARException{

- logger =
(LoggerComponent)AuxiliaryComponentManager.getInstance().getComponent(ComponentNames.LOGGER);
- protector =
(CommandLineResourceProtector)AuxiliaryComponentManager.getInstance().getComponent("clmprp");
+ logger = (LoggerComponent)
+ AuxiliaryComponentManager.getInstance()
+ .getComponent(ComponentNames.LOGGER);
+ protector = (CommandLineResourceProtector)
+
AuxiliaryComponentManager.getInstance()
+
.getComponent(Constants.RPComponent);

this.OS = System.getProperty("os.name").toLowerCase();


Modified:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Traceroute.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Traceroute.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools/Traceroute.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -357,17 +357,17 @@
"An error ocurred while trying to parse the results of
the request. Please try again. " +
"If this problem persists, contact the service
administrator."
);
+ }finally{
+ try {
+ if (os != null)
+ os.delete();
+ if (es != null)
+ es.delete();
+ }catch(Exception e){
+
+ }
}

- try {
-
- if (os != null)
- os.delete();
- if (es != null)
- es.delete();
- }catch(Exception e){
- }
-
Datum[] datums = new Datum[datumList.size()];
datumList.toArray(datums);


Added:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils/Constants.java

Added:
trunk/rnp_java-cl-mp/src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils/SelfTestUnit.java

Modified:
trunk/rnp_java-cl-mp/src/main/java/perfSONARWebAdmin/admin/wizard/services/CLMPHandler.java
===================================================================
---
trunk/rnp_java-cl-mp/src/main/java/perfSONARWebAdmin/admin/wizard/services/CLMPHandler.java
2008-09-22 12:46:40 UTC (rev 4525)
+++
trunk/rnp_java-cl-mp/src/main/java/perfSONARWebAdmin/admin/wizard/services/CLMPHandler.java
2008-09-22 13:59:50 UTC (rev 4526)
@@ -1,692 +1,692 @@
-package perfSONARWebAdmin.admin.wizard.services;
-
-import java.io.BufferedReader;
-import java.io.BufferedWriter;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.FileReader;
-import java.io.FileWriter;
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.Calendar;
-import java.util.Hashtable;
-import java.util.Iterator;
-
-import javax.servlet.http.HttpServletRequest;
-
-import perfSONARWebAdmin.auxiliary.PerfsonarProperties;
-import perfSONARWebAdmin.auxiliary.PerfsonarPropertiesImpl;
-import perfSONARWebAdmin.auxiliary.PerfsonarProperty;
-import perfSONARWebAdmin.auxiliary.ServiceProperties;
-import perfSONARWebAdmin.auxiliary.ServicePropertiesImpl;
-import perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler;
-import perfSONARWebAdmin.auxiliary.wizard.HTMLOutput;
-import perfSONARWebAdmin.auxiliary.wizard.WizardProperties;
-import perfSONARWebAdmin.auxiliary.wizard.WizardProperty;
-
-/**
- * Class implementing the ConfigurationHandler Interface. This is a reference
- * imlementation to be used exam
- *
- * @author Michalis Michael,CyNet
- *
- */
-public class CLMPHandler implements ConfigurationHandler {
-
- //
-----------------------------------------------------------------------
- // class fields
-
- // Hashtable containg Wizard Properties as values and the various
groups in
- // which the properties are divided to as keys
- private Hashtable<String, WizardProperties> groupedProperties = null;
-
- // All of the Wizard Properties
- private WizardProperties properties = null;
-
- // The HtTMLOutput class that is used for outputting html code to the
user.
- // Currently not used by this reference implementation
- @SuppressWarnings("unused")
- private HTMLOutput htmlOutput;
-
- // The path to the configuration directory
- private static final String confPath =
"WEB-INF/classes/perfsonar/conf/";
-
- // The path to the service.properties file
- private static final String ServicePropertiesPath = confPath
- + "service.properties";
-
- // The path to the logging properties file
- private static final String LoggingPropertiesPath = confPath
- + "log4j.properties";
-
- // The path to the componenets.properties file
- private static final String ComponentsPropertiesPath = confPath
- + "components.properties";
-
- // The path to the eventType-map file
- private static final String EventTypeMapPath = confPath
- + "eventType-map.xml";
-
- // The path to the objects properties file
- private static final String ObjectsConfigPath = confPath +
"objects.config";
-
- // The path to the wizard.properties file
- private static final String WizardPropertiesPath = confPath
- + "wizard.properties";
-
- // The path to the servlet.properties file
- private static final String ServletPropertiesPath = confPath
- + "servlet.properties";
-
- // The path to the directory under the webapps folder in which the
service
- // is installed
- private static String ServicePath = "";
-
- // Bollean that states if the configuration process is finished
- private static boolean configured = false;
-
- //
-----------------------------------------------------------------------
- // constructors
-
- /**
- * Class constructor
- */
- public CLMPHandler() {
-
- }
-
- //
-----------------------------------------------------------------------
- // public methods
-
- /*
- * (non-Javadoc)
- *
- * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#handleRequest(javax.servlet.http.HttpServletRequest)
- */
- public boolean handleRequest(HttpServletRequest request) throws
Exception {
-
- // Setting configured to false
- configured = false;
- // Also definining some more booleans for every different
group to be
- // configured
- boolean LSDone = false;
- // Authentication group.
- boolean authDone = false;
- // Other is every other group besides LS and Auth.
- boolean otherDone = false;
-
- // Each group is independent from each other and can be
configured
- // without any dependencies
- try {
- // Handling LS configuration
- // True if all is done properly
- LSDone = handleLS(request);
- } catch (Exception e) {
- throw new Exception(
- "Problem with LS configuration!Please
check your input.\n"
- + getFault(e));
- }
- try {
- // Handling other groups configuration
- // True if all is done properly
- authDone = handleAuthentication(request);
- } catch (Exception e) {
-
- throw new Exception(
- "Problem with Authentication
configuration!Please check your input.\n"
- + getFault(e));
- }
- try {
- // Handling other groups configuration
- // True if all is done properly
- otherDone = handleOther(request);
- } catch (Exception e) {
-
- throw new Exception(
- "Problem with Store
configuration!Please check your input.\n"
- + getFault(e));
- }
- // if every group has configured successfully then the final
- // configuration procedures are called
- if (LSDone && otherDone && authDone) {
- try {
- configured = finishConfiguration();
- // if everything has gone OK then true is
returned
- return configured;
- } catch (Exception e) {
- throw new Exception("Problem finishing
configuration.\n"
- + getFault(e));
- }
- } else {
- return configured;
- }
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#isConfigured()
- */
- public boolean isConfigured() {
-
- return configured;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setHTMLOutput(perfSONARWebAdmin.auxiliary.wizard.HTMLOutput)
- */
- public void setHTMLOutput(HTMLOutput output) {
-
- htmlOutput = output;
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setProperties(perfSONARWebAdmin.auxiliary.wizard.WizardProperties)
- */
- public void setProperties(WizardProperties loadedProperties) {
-
- properties = loadedProperties;
- }
-
- /*
- * (non-Javadoc)
- *
- * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setGroupedProperties(java.util.Hashtable)
- */
- public void setGroupedProperties(
- Hashtable<String, WizardProperties> otherProperties) {
-
- groupedProperties = otherProperties;
-
- }
-
- /*
- * (non-Javadoc)
- *
- * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setServicePath(java.lang.String)
- */
- public void setServicePath(String servicePath) {
-
- ServicePath = servicePath;
-
- }
-
- //
-----------------------------------------------------------------------
- // private methods
-
- /**
- * Method used for handling other groups configuration(That is other
than LS
- * and exist)
- *
- * @param request
- * The HttpServletRequest containing input from the user
- * @return True if other groups are configured successfully
- * @throws Exception
- */
- private boolean handleOther(HttpServletRequest request) throws
Exception {
-
- // Getting all groups
- Iterator groupIt = groupedProperties.keySet().iterator();
- // Setting done to true, You will see later why
- boolean done = true;
- // Iterating through the groups
- while (groupIt.hasNext()) {
- String group = (String) groupIt.next();
- // Every other group should be handled except for LS
- if (!(group.equals("LS") ||
group.equals("Authentication"))) {
-
- // Retrieving the properties belonging to the
group
- WizardProperties groupProperties =
groupedProperties.get(group);
- // Iterating through the properties. This way
using the key of
- // each property we can retrieve the users
input from the
- // request
- Iterator it = groupProperties.orderedKeys();
- while (it.hasNext()) {
- String key = (String) it.next();
- // get the value from the request
- String value =
request.getParameter(key).trim();
- WizardProperty pr =
groupProperties.getWizardProperty(key);
- // Set the property value
- pr.setPropertyValue(value);
- // if the property does not the check
field set, the also
- // put the user input as the proposed
value also
- // This happens, because properties
that have the check
- // property set, are usually
important for the rest of the
- // group properties since their value
would determine if the
- // rest need to be configured. So
their proposed value is
- // left to thr developer
- if (!pr.getCheck()) {
- pr.setProposedValue(value);
- }
- // Updating the property inside the
group propereties
-
groupProperties.setWizardProperty(key, pr);
- }
- // Updating the grouped properties
- groupedProperties.put(group, groupProperties);
- // Applying the configuration input from the
user to the service
- try {
- otherActions(group, groupProperties);
- } catch (Exception e) {
- // If actions had a problem then done
is set to false
- done = false;
- throw new Exception(getFault(e));
- }
- }
- }
-
- return done;
- }
-
- /**
- * Method used for handling LS registration configuration
- *
- * @param request
- * The HttpServletRequest containing input from the user
- * @return True if LS registration is configured successfully
- * @throws Exception
- */
- private boolean handleLS(HttpServletRequest request) throws Exception
{
-
- // Retrieving the useLS parameter. The useLS parammeter is
inserted as
- // input by the shoaAllProperties method of the HTMLOutput
class
- // automatically. It is the answer to if the user wants to
register to
- // an LS since their is no service property that corresponds
to this
- // question
- String useLS = request.getParameter("useLS").trim();
- // If yes all other properties regarding LS registration are
retrieved
- if (useLS.equals("yes")) {
- // Retrieving all propertie associated with LS
- WizardProperties lsProperties =
groupedProperties.get("LS");
- // Getting the keys of the properties
- Iterator it = lsProperties.orderedKeys();
- while (it.hasNext()) {
- String key = (String) it.next();
- // Using the keys for retrieving the users
input
- String value =
request.getParameter(key).trim();
- WizardProperty pr =
lsProperties.getWizardProperty(key);
- // Setting property value and proposed value
- pr.setPropertyValue(value);
- pr.setProposedValue(value);
- // Setting property
- lsProperties.setWizardProperty(key, pr);
- }
- // Setting the LS group properties
- groupedProperties.put("LS", lsProperties);
- boolean done = false;
- // Trying to perfom the LS configuration actions to
the service
- try {
- lsActions(lsProperties);
- done = true;
- } catch (Exception e) {
- // False if an error happens
- done = false;
- throw new Exception(getFault(e));
- }
-
- return done;
- }
- // If no then the registration componenets are commented in
the
- // components.properties file
- else {
- removeRegistrationComponents();
- return true;
- }
- }
-
- /**
- * Method used for handling CL-MP authentication configuration
- *
- * @param request
- * The HttpServletRequest containing input from the user
- * @return True if authentication is configured successfully
- * @throws Exception
- */
- private boolean handleAuthentication(HttpServletRequest request)
throws Exception {
-
- WizardProperties groupProperties =
groupedProperties.get("Authentication");
-
- if(groupProperties == null)
- throw new Exception("There must a group
Authentication in wizard.properties.\n");
-
-
if("yes".equals(request.getParameter("authentication.enable").trim())){
- groupProperties.remove("authentication.enable");
-
- ArrayList<String> keys = new ArrayList<String>();
-
- Iterator it = groupProperties.orderedKeys();
- while (it.hasNext()) {
- String key = (String) it.next();
- if(key.startsWith("authentication"))
-
keys.add(key.substring(key.indexOf('.')+1));
- }
-
- FileReader fr = new FileReader(ServicePath +
EventTypeMapPath);
- BufferedReader br = new BufferedReader(fr);
- StringBuffer contents = new StringBuffer();
-
- for(String line = br.readLine(); line != null; line =
br.readLine()){
- if(line.contains("<name>")){
- for(String key : keys)
- if(line.contains(key)){
- contents.append(line
+ "\n");
-
contents.append(br.readLine()+"\n"); /* read <class> */
- line = br.readLine();
-
if(!line.contains("<authentication>"))
- throw new
Exception("Malformed eventyType-map.xml file.\n");
-
- String value =
request.getParameter("authentication."+key).trim();
- if("no".equals(value))
- line =
line.replace("yes", "no");
- else
if("yes".equals(value))
- line =
line.replace("no", "yes");
- else
- throw new
Exception("Unrecognized option '"+value+"' for authentication configuration
of tools.\n");
-
-
groupProperties.remove("authentication."+key);
- break;
- }
- }
- contents.append(line+"\n");
- }
-
- br.close();
- fr.close();
-
- FileWriter fw = new FileWriter(ServicePath +
EventTypeMapPath);
- BufferedWriter bw = new BufferedWriter(fw);
- bw.write(contents.toString().trim());
- bw.close();
- fw.close();
-
-
- it = groupProperties.orderedKeys();
- while (it.hasNext()) {
- String key = (String) it.next();
- // get the value from the request
- String value =
request.getParameter(key).trim();
- WizardProperty pr =
groupProperties.getWizardProperty(key);
- // Set the property value
- pr.setPropertyValue(value);
- // if the property does not the check field
set, the also
- // put the user input as the proposed value
also
- // This happens, because properties that have
the check
- // property set, are usually important for
the rest of the
- // group properties since their value would
determine if the
- // rest need to be configured. So their
proposed value is
- // left to thr developer
- if (!pr.getCheck()) {
- pr.setProposedValue(value);
- }
- // Updating the property inside the group
propereties
- groupProperties.setWizardProperty(key, pr);
- }
- // Updating the grouped properties
- groupedProperties.put("Authentication",
groupProperties);
- // Applying the configuration input from the user to
the service
- try {
- otherActions("Authentication",
groupProperties);
- } catch (Exception e) {
- // If actions had a problem then exception is
thrown
- throw new Exception(getFault(e));
- }
- }
-
- return true;
- }
-
- /**
- * Method for handling all configuration actions regarding any other
group
- * besides LS and Authentication
- *
- * @param group
- * The group
- * @param functionProperties
- * The properties regardung the group
- * @throws IOException
- */
- private void otherActions(String group, WizardProperties
functionProperties)
- throws IOException {
-
- // In this case changes go into the service.properties file
that uses
- // groupig and description
- // In order to keep that functionality we need in this case
to use the
- // PerfsonarProperties class
- if (!group.equals("Administration")) {
-
- // Using PerfsonarProperties in order to keep the
grouping and
- // description
- PerfsonarProperties serviceProperties = null;
- serviceProperties = new PerfsonarPropertiesImpl();
- serviceProperties.loadProperties(new
FileInputStream(ServicePath
- + ServicePropertiesPath));
- // Getting the names for every property of the group
- Iterator it = functionProperties.orderedKeys();
- // Setting the value of each property
-
- // An object that holds the property
group,description,value and key
- PerfsonarProperty property = new PerfsonarProperty();
- while (it.hasNext()) {
- String key = (String) it.next();
- // Setting service properties and wizard
properties
-
- // Get the property
- property = serviceProperties.getProperty(key);
- // If key property does not exist the throw
an exception
- if (property == null) {
- throw new IOException("Key is invalid
" + key + " ");
- } else {
- // Change the value of the property
-
if(functionProperties.getProperty(key).equals("yes"))
- property.setValue("on");
- else if
(functionProperties.getProperty(key).equals("no"))
- property.setValue("off");
- else
-
property.setValue(functionProperties.getProperty(key));
-
- serviceProperties.setProperty(key,
property);
- }
- properties.setWizardProperty(key,
functionProperties
- .getWizardProperty(key));
- }
- // Storing all changes
- serviceProperties.storeProperties(new
FileOutputStream(ServicePath
- + ServicePropertiesPath));
- }
- // We don't really have any other groups just the ones for
the servlet
- // administration, that does not use grouping and description
so we can
- // use
- // the ServiceProperties class as usual
- else {
- // A class that makes modifying service properties a
little bit
- // easier
- ServiceProperties serviceProperties = new
ServicePropertiesImpl(
- ServicePath + ServletPropertiesPath);
- // Getting the names for every property of the group
- Iterator it = functionProperties.orderedKeys();
- // Setting the value of each property
- String value = null;
- while (it.hasNext()) {
- String key = (String) it.next();
- // Setting service properties and wizard
properties
- value = functionProperties.getProperty(key);
- if (value == null) {
- throw new IOException("Key is invalid
" + key + " ");
- } else {
- serviceProperties.setProperty(key,
value);
- }
- properties.setWizardProperty(key,
functionProperties
- .getWizardProperty(key));
- }
- serviceProperties.storeProperties();
-
- }
- properties.storeToXML(new FileOutputStream(new
File(ServicePath
- + WizardPropertiesPath)), " Last Modification
"
- +
Calendar.getInstance().getTime().toString());
- }
-
-
- /**
- * Method for handling all configuration actions regarding the LS
- * registration
- *
- * @param finalProperties
- * The WizardProperties that belong to the LS registration
group
- * @throws IOException
- */
- private void lsActions(WizardProperties finalProperties) throws
IOException {
- // Changes happen into the service.property file that uses
groupig and
- // description
- // In order to keep that functionality we need in this case
to use the
- // PerfsonarProperties class
- PerfsonarProperties serviceProperties = new
PerfsonarPropertiesImpl();
- serviceProperties.loadProperties(new
FileInputStream(ServicePath
- + ServicePropertiesPath));
- Iterator it = finalProperties.orderedKeys();
- // Iterating through the LS registration properties properties
-
- // Initializing the PerfsonarProperty object that holds
information
- // about grouping and description
- PerfsonarProperty property = new PerfsonarProperty();
- while (it.hasNext()) {
- String key = (String) it.next();
- // Set the service properties
-
- // Get the PerfsonarProperty object
- property = serviceProperties.getProperty(key);
-
- // If property key does not exist throw an exceptrion
- if (property == null) {
- throw new IOException("Key is invalid " + key
+ " ");
- } else {
- // Else set the value right
-
property.setValue(finalProperties.getProperty(key));
- serviceProperties.setProperty(key, property);
- }
- // Set the wizard properties
- properties.setWizardProperty(key, finalProperties
- .getWizardProperty(key));
- }
- // Storing service properties
- serviceProperties.storeProperties(new
FileOutputStream(ServicePath
- + ServicePropertiesPath));
- // Setting the LS registration componenets in components
properties file
- addRegistrationComponents();
- // Storing the wizard properties
- properties.storeToXML(new FileOutputStream(new
File(ServicePath
- + WizardPropertiesPath)), " Last Modification
"
- +
Calendar.getInstance().getTime().toString());
- }
-
- /**
- * Method used for adding registration componenets to the
- * componenets.properties file
- *
- * @throws IOException
- */
- private void addRegistrationComponents() throws IOException {
- File comp = new File(ServicePath + ComponentsPropertiesPath);
- FileReader fr = new FileReader(comp);
- StringBuffer contents = new StringBuffer();
- BufferedReader br = new BufferedReader(fr);
- String line = "";
- while (line != null) {
- if (line.startsWith("#registrator")) {
- line = line.substring(1);
- }
- contents.append(line + "\n");
- line = br.readLine();
- }
-
- FileWriter fw = new FileWriter(comp);
- BufferedWriter bw = new BufferedWriter(fw);
- bw.write(contents.toString().trim());
- bw.close();
- fw.close();
- br.close();
- fr.close();
- }
-
- /**
- * Method for removing ls registration components from
components.properties
- * file
- *
- * @throws IOException
- */
- private void removeRegistrationComponents() throws IOException {
- File comp = new File(ServicePath + ComponentsPropertiesPath);
- FileReader fr = new FileReader(comp);
- StringBuffer contents = new StringBuffer();
- BufferedReader br = new BufferedReader(fr);
- String line = "";
- while (line != null) {
- if (line.startsWith("registrator")) {
- line = "#" + line;
- }
- contents.append(line + "\n");
- line = br.readLine();
- }
-
- FileWriter fw = new FileWriter(comp);
- BufferedWriter bw = new BufferedWriter(fw);
- bw.write(contents.toString().trim());
- bw.close();
- fw.close();
- br.close();
- fr.close();
- }
-
- /**
- * Method for performing final actions for service configuration
- *
- * @return
- * @throws Exception
- */
- public boolean finishConfiguration() throws Exception {
-
- PerfsonarProperties serviceProperties = new
PerfsonarPropertiesImpl();
- serviceProperties.loadProperties(new
FileInputStream(ServicePath
- + ServicePropertiesPath));
- PerfsonarProperty property = new PerfsonarProperty();
- property.setKey("service.sax_parser.config");
- property.setValue(ServicePath + ObjectsConfigPath);
- property.setGroup("Internals");
- property.setDescription("Sax parser configuration paramater");
- serviceProperties.setProperty(property.getKey(), property);
- property = new PerfsonarProperty();
- property.setKey("service.log.log4j.config");
- property.setValue(ServicePath + LoggingPropertiesPath);
- property.setGroup("Internals");
- property.setDescription("Logging Properties path");
- serviceProperties.setProperty(property.getKey(), property);
- serviceProperties.storeProperties(new
FileOutputStream(ServicePath
- + ServicePropertiesPath));
-
- return true;
-
- }
-
- /**
- * Method to get the stack trace of an exception
- *
- * @param e
- * The exception
- * @return A string with stack the trace
- */
- private String getFault(Exception e) {
- StackTraceElement[] trace = e.getStackTrace();
- String fault = e.getMessage();
- for (int j = 0; j < trace.length; j++) {
- fault += trace[j].toString() + "\n";
- }
- return fault;
- }
-
+package perfSONARWebAdmin.admin.wizard.services;
+
+import java.io.BufferedReader;
+import java.io.BufferedWriter;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.FileReader;
+import java.io.FileWriter;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Calendar;
+import java.util.Hashtable;
+import java.util.Iterator;
+
+import javax.servlet.http.HttpServletRequest;
+
+import perfSONARWebAdmin.auxiliary.PerfsonarProperties;
+import perfSONARWebAdmin.auxiliary.PerfsonarPropertiesImpl;
+import perfSONARWebAdmin.auxiliary.PerfsonarProperty;
+import perfSONARWebAdmin.auxiliary.ServiceProperties;
+import perfSONARWebAdmin.auxiliary.ServicePropertiesImpl;
+import perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler;
+import perfSONARWebAdmin.auxiliary.wizard.HTMLOutput;
+import perfSONARWebAdmin.auxiliary.wizard.WizardProperties;
+import perfSONARWebAdmin.auxiliary.wizard.WizardProperty;
+
+/**
+ * Class implementing the ConfigurationHandler Interface. This is a reference
+ * imlementation to be used exam
+ *
+ * @author Michalis Michael,CyNet
+ *
+ */
+public class CLMPHandler implements ConfigurationHandler {
+
+ //
-----------------------------------------------------------------------
+ // class fields
+
+ // Hashtable containg Wizard Properties as values and the various
groups in
+ // which the properties are divided to as keys
+ private Hashtable<String, WizardProperties> groupedProperties = null;
+
+ // All of the Wizard Properties
+ private WizardProperties properties = null;
+
+ // The HtTMLOutput class that is used for outputting html code to the
user.
+ // Currently not used by this reference implementation
+ @SuppressWarnings("unused")
+ private HTMLOutput htmlOutput;
+
+ // The path to the configuration directory
+ private static final String confPath =
"WEB-INF/classes/perfsonar/conf/";
+
+ // The path to the service.properties file
+ private static final String ServicePropertiesPath = confPath
+ + "service.properties";
+
+ // The path to the logging properties file
+ private static final String LoggingPropertiesPath = confPath
+ + "log4j.properties";
+
+ // The path to the componenets.properties file
+ private static final String ComponentsPropertiesPath = confPath
+ + "components.properties";
+
+ // The path to the eventType-map file
+ private static final String EventTypeMapPath = confPath
+ + "eventType-map.xml";
+
+ // The path to the objects properties file
+ private static final String ObjectsConfigPath = confPath +
"objects.config";
+
+ // The path to the wizard.properties file
+ private static final String WizardPropertiesPath = confPath
+ + "wizard.properties";
+
+ // The path to the servlet.properties file
+ private static final String ServletPropertiesPath = confPath
+ + "servlet.properties";
+
+ // The path to the directory under the webapps folder in which the
service
+ // is installed
+ private static String ServicePath = "";
+
+ // Bollean that states if the configuration process is finished
+ private static boolean configured = false;
+
+ //
-----------------------------------------------------------------------
+ // constructors
+
+ /**
+ * Class constructor
+ */
+ public CLMPHandler() {
+
+ }
+
+ //
-----------------------------------------------------------------------
+ // public methods
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#handleRequest(javax.servlet.http.HttpServletRequest)
+ */
+ public boolean handleRequest(HttpServletRequest request) throws
Exception {
+
+ // Setting configured to false
+ configured = false;
+ // Also definining some more booleans for every different
group to be
+ // configured
+ boolean LSDone = false;
+ // Authentication group.
+ boolean authDone = false;
+ // Other is every other group besides LS and Auth.
+ boolean otherDone = false;
+
+ // Each group is independent from each other and can be
configured
+ // without any dependencies
+ try {
+ // Handling LS configuration
+ // True if all is done properly
+ LSDone = handleLS(request);
+ } catch (Exception e) {
+ throw new Exception(
+ "Problem with LS configuration!Please
check your input.\n"
+ + getFault(e));
+ }
+ try {
+ // Handling other groups configuration
+ // True if all is done properly
+ authDone = handleAuthentication(request);
+ } catch (Exception e) {
+
+ throw new Exception(
+ "Problem with Authentication
configuration!Please check your input.\n"
+ + getFault(e));
+ }
+ try {
+ // Handling other groups configuration
+ // True if all is done properly
+ otherDone = handleOther(request);
+ } catch (Exception e) {
+
+ throw new Exception(
+ "Problem with Store
configuration!Please check your input.\n"
+ + getFault(e));
+ }
+ // if every group has configured successfully then the final
+ // configuration procedures are called
+ if (LSDone && otherDone && authDone) {
+ try {
+ configured = finishConfiguration();
+ // if everything has gone OK then true is
returned
+ return configured;
+ } catch (Exception e) {
+ throw new Exception("Problem finishing
configuration.\n"
+ + getFault(e));
+ }
+ } else {
+ return configured;
+ }
+
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#isConfigured()
+ */
+ public boolean isConfigured() {
+
+ return configured;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setHTMLOutput(perfSONARWebAdmin.auxiliary.wizard.HTMLOutput)
+ */
+ public void setHTMLOutput(HTMLOutput output) {
+
+ htmlOutput = output;
+
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setProperties(perfSONARWebAdmin.auxiliary.wizard.WizardProperties)
+ */
+ public void setProperties(WizardProperties loadedProperties) {
+
+ properties = loadedProperties;
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setGroupedProperties(java.util.Hashtable)
+ */
+ public void setGroupedProperties(
+ Hashtable<String, WizardProperties> otherProperties) {
+
+ groupedProperties = otherProperties;
+
+ }
+
+ /*
+ * (non-Javadoc)
+ *
+ * @see
perfSONARWebAdmin.auxiliary.wizard.ConfigurationHandler#setServicePath(java.lang.String)
+ */
+ public void setServicePath(String servicePath) {
+
+ ServicePath = servicePath;
+
+ }
+
+ //
-----------------------------------------------------------------------
+ // private methods
+
+ /**
+ * Method used for handling other groups configuration(That is other
than LS
+ * and exist)
+ *
+ * @param request
+ * The HttpServletRequest containing input from the user
+ * @return True if other groups are configured successfully
+ * @throws Exception
+ */
+ private boolean handleOther(HttpServletRequest request) throws
Exception {
+
+ // Getting all groups
+ Iterator groupIt = groupedProperties.keySet().iterator();
+ // Setting done to true, You will see later why
+ boolean done = true;
+ // Iterating through the groups
+ while (groupIt.hasNext()) {
+ String group = (String) groupIt.next();
+ // Every other group should be handled except for LS
+ if (!(group.equals("LS") ||
group.equals("Authentication"))) {
+
+ // Retrieving the properties belonging to the
group
+ WizardProperties groupProperties =
groupedProperties.get(group);
+ // Iterating through the properties. This way
using the key of
+ // each property we can retrieve the users
input from the
+ // request
+ Iterator it = groupProperties.orderedKeys();
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ // get the value from the request
+ String value =
request.getParameter(key).trim();
+ WizardProperty pr =
groupProperties.getWizardProperty(key);
+ // Set the property value
+ pr.setPropertyValue(value);
+ // if the property does not the check
field set, the also
+ // put the user input as the proposed
value also
+ // This happens, because properties
that have the check
+ // property set, are usually
important for the rest of the
+ // group properties since their value
would determine if the
+ // rest need to be configured. So
their proposed value is
+ // left to thr developer
+ if (!pr.getCheck()) {
+ pr.setProposedValue(value);
+ }
+ // Updating the property inside the
group propereties
+
groupProperties.setWizardProperty(key, pr);
+ }
+ // Updating the grouped properties
+ groupedProperties.put(group, groupProperties);
+ // Applying the configuration input from the
user to the service
+ try {
+ otherActions(group, groupProperties);
+ } catch (Exception e) {
+ // If actions had a problem then done
is set to false
+ done = false;
+ throw new Exception(getFault(e));
+ }
+ }
+ }
+
+ return done;
+ }
+
+ /**
+ * Method used for handling LS registration configuration
+ *
+ * @param request
+ * The HttpServletRequest containing input from the user
+ * @return True if LS registration is configured successfully
+ * @throws Exception
+ */
+ private boolean handleLS(HttpServletRequest request) throws Exception
{
+
+ // Retrieving the useLS parameter. The useLS parammeter is
inserted as
+ // input by the shoaAllProperties method of the HTMLOutput
class
+ // automatically. It is the answer to if the user wants to
register to
+ // an LS since their is no service property that corresponds
to this
+ // question
+ String useLS = request.getParameter("useLS").trim();
+ // If yes all other properties regarding LS registration are
retrieved
+ if (useLS.equals("yes")) {
+ // Retrieving all propertie associated with LS
+ WizardProperties lsProperties =
groupedProperties.get("LS");
+ // Getting the keys of the properties
+ Iterator it = lsProperties.orderedKeys();
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ // Using the keys for retrieving the users
input
+ String value =
request.getParameter(key).trim();
+ WizardProperty pr =
lsProperties.getWizardProperty(key);
+ // Setting property value and proposed value
+ pr.setPropertyValue(value);
+ pr.setProposedValue(value);
+ // Setting property
+ lsProperties.setWizardProperty(key, pr);
+ }
+ // Setting the LS group properties
+ groupedProperties.put("LS", lsProperties);
+ boolean done = false;
+ // Trying to perfom the LS configuration actions to
the service
+ try {
+ lsActions(lsProperties);
+ done = true;
+ } catch (Exception e) {
+ // False if an error happens
+ done = false;
+ throw new Exception(getFault(e));
+ }
+
+ return done;
+ }
+ // If no then the registration componenets are commented in
the
+ // components.properties file
+ else {
+ removeRegistrationComponents();
+ return true;
+ }
+ }
+
+ /**
+ * Method used for handling CL-MP authentication configuration
+ *
+ * @param request
+ * The HttpServletRequest containing input from the user
+ * @return True if authentication is configured successfully
+ * @throws Exception
+ */
+ private boolean handleAuthentication(HttpServletRequest request)
throws Exception {
+
+ WizardProperties groupProperties =
groupedProperties.get("Authentication");
+
+ if(groupProperties == null)
+ throw new Exception("There must a group
Authentication in wizard.properties.\n");
+
+
if("yes".equals(request.getParameter("authentication.enable").trim())){
+ groupProperties.remove("authentication.enable");
+
+ ArrayList<String> keys = new ArrayList<String>();
+
+ Iterator it = groupProperties.orderedKeys();
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ if(key.startsWith("authentication"))
+
keys.add(key.substring(key.indexOf('.')+1));
+ }
+
+ FileReader fr = new FileReader(ServicePath +
EventTypeMapPath);
+ BufferedReader br = new BufferedReader(fr);
+ StringBuffer contents = new StringBuffer();
+
+ for(String line = br.readLine(); line != null; line =
br.readLine()){
+ if(line.contains("<name>")){
+ for(String key : keys)
+ if(line.contains(key)){
+ contents.append(line
+ "\n");
+
contents.append(br.readLine()+"\n"); /* read <class> */
+ line = br.readLine();
+
if(!line.contains("<authentication>"))
+ throw new
Exception("Malformed eventyType-map.xml file.\n");
+
+ String value =
request.getParameter("authentication."+key).trim();
+ if("no".equals(value))
+ line =
line.replace("yes", "no");
+ else
if("yes".equals(value))
+ line =
line.replace("no", "yes");
+ else
+ throw new
Exception("Unrecognized option '"+value+"' for authentication configuration
of tools.\n");
+
+
groupProperties.remove("authentication."+key);
+ break;
+ }
+ }
+ contents.append(line+"\n");
+ }
+
+ br.close();
+ fr.close();
+
+ FileWriter fw = new FileWriter(ServicePath +
EventTypeMapPath);
+ BufferedWriter bw = new BufferedWriter(fw);
+ bw.write(contents.toString().trim());
+ bw.close();
+ fw.close();
+
+
+ it = groupProperties.orderedKeys();
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ // get the value from the request
+ String value =
request.getParameter(key).trim();
+ WizardProperty pr =
groupProperties.getWizardProperty(key);
+ // Set the property value
+ pr.setPropertyValue(value);
+ // if the property does not the check field
set, the also
+ // put the user input as the proposed value
also
+ // This happens, because properties that have
the check
+ // property set, are usually important for
the rest of the
+ // group properties since their value would
determine if the
+ // rest need to be configured. So their
proposed value is
+ // left to thr developer
+ if (!pr.getCheck()) {
+ pr.setProposedValue(value);
+ }
+ // Updating the property inside the group
propereties
+ groupProperties.setWizardProperty(key, pr);
+ }
+ // Updating the grouped properties
+ groupedProperties.put("Authentication",
groupProperties);
+ // Applying the configuration input from the user to
the service
+ try {
+ otherActions("Authentication",
groupProperties);
+ } catch (Exception e) {
+ // If actions had a problem then exception is
thrown
+ throw new Exception(getFault(e));
+ }
+ }
+
+ return true;
+ }
+
+ /**
+ * Method for handling all configuration actions regarding any other
group
+ * besides LS and Authentication
+ *
+ * @param group
+ * The group
+ * @param functionProperties
+ * The properties regardung the group
+ * @throws IOException
+ */
+ private void otherActions(String group, WizardProperties
functionProperties)
+ throws IOException {
+
+ // In this case changes go into the service.properties file
that uses
+ // groupig and description
+ // In order to keep that functionality we need in this case
to use the
+ // PerfsonarProperties class
+ if (!group.equals("Administration")) {
+
+ // Using PerfsonarProperties in order to keep the
grouping and
+ // description
+ PerfsonarProperties serviceProperties = null;
+ serviceProperties = new PerfsonarPropertiesImpl();
+ serviceProperties.loadProperties(new
FileInputStream(ServicePath
+ + ServicePropertiesPath));
+ // Getting the names for every property of the group
+ Iterator it = functionProperties.orderedKeys();
+ // Setting the value of each property
+
+ // An object that holds the property
group,description,value and key
+ PerfsonarProperty property = new PerfsonarProperty();
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ // Setting service properties and wizard
properties
+
+ // Get the property
+ property = serviceProperties.getProperty(key);
+ // If key property does not exist the throw
an exception
+ if (property == null) {
+ throw new IOException("Key is invalid
" + key + " ");
+ } else {
+ // Change the value of the property
+
if(functionProperties.getProperty(key).equals("yes"))
+ property.setValue("on");
+ else if
(functionProperties.getProperty(key).equals("no"))
+ property.setValue("off");
+ else
+
property.setValue(functionProperties.getProperty(key));
+
+ serviceProperties.setProperty(key,
property);
+ }
+ properties.setWizardProperty(key,
functionProperties
+ .getWizardProperty(key));
+ }
+ // Storing all changes
+ serviceProperties.storeProperties(new
FileOutputStream(ServicePath
+ + ServicePropertiesPath));
+ }
+ // We don't really have any other groups just the ones for
the servlet
+ // administration, that does not use grouping and description
so we can
+ // use
+ // the ServiceProperties class as usual
+ else {
+ // A class that makes modifying service properties a
little bit
+ // easier
+ ServiceProperties serviceProperties = new
ServicePropertiesImpl(
+ ServicePath + ServletPropertiesPath);
+ // Getting the names for every property of the group
+ Iterator it = functionProperties.orderedKeys();
+ // Setting the value of each property
+ String value = null;
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ // Setting service properties and wizard
properties
+ value = functionProperties.getProperty(key);
+ if (value == null) {
+ throw new IOException("Key is invalid
" + key + " ");
+ } else {
+ serviceProperties.setProperty(key,
value);
+ }
+ properties.setWizardProperty(key,
functionProperties
+ .getWizardProperty(key));
+ }
+ serviceProperties.storeProperties();
+
+ }
+ properties.storeToXML(new FileOutputStream(new
File(ServicePath
+ + WizardPropertiesPath)), " Last Modification
"
+ +
Calendar.getInstance().getTime().toString());
+ }
+
+
+ /**
+ * Method for handling all configuration actions regarding the LS
+ * registration
+ *
+ * @param finalProperties
+ * The WizardProperties that belong to the LS registration
group
+ * @throws IOException
+ */
+ private void lsActions(WizardProperties finalProperties) throws
IOException {
+ // Changes happen into the service.property file that uses
groupig and
+ // description
+ // In order to keep that functionality we need in this case
to use the
+ // PerfsonarProperties class
+ PerfsonarProperties serviceProperties = new
PerfsonarPropertiesImpl();
+ serviceProperties.loadProperties(new
FileInputStream(ServicePath
+ + ServicePropertiesPath));
+ Iterator it = finalProperties.orderedKeys();
+ // Iterating through the LS registration properties properties
+
+ // Initializing the PerfsonarProperty object that holds
information
+ // about grouping and description
+ PerfsonarProperty property = new PerfsonarProperty();
+ while (it.hasNext()) {
+ String key = (String) it.next();
+ // Set the service properties
+
+ // Get the PerfsonarProperty object
+ property = serviceProperties.getProperty(key);
+
+ // If property key does not exist throw an exceptrion
+ if (property == null) {
+ throw new IOException("Key is invalid " + key
+ " ");
+ } else {
+ // Else set the value right
+
property.setValue(finalProperties.getProperty(key));
+ serviceProperties.setProperty(key, property);
+ }
+ // Set the wizard properties
+ properties.setWizardProperty(key, finalProperties
+ .getWizardProperty(key));
+ }
+ // Storing service properties
+ serviceProperties.storeProperties(new
FileOutputStream(ServicePath
+ + ServicePropertiesPath));
+ // Setting the LS registration componenets in components
properties file
+ addRegistrationComponents();
+ // Storing the wizard properties
+ properties.storeToXML(new FileOutputStream(new
File(ServicePath
+ + WizardPropertiesPath)), " Last Modification
"
+ +
Calendar.getInstance().getTime().toString());
+ }
+
+ /**
+ * Method used for adding registration componenets to the
+ * componenets.properties file
+ *
+ * @throws IOException
+ */
+ private void addRegistrationComponents() throws IOException {
+ File comp = new File(ServicePath + ComponentsPropertiesPath);
+ FileReader fr = new FileReader(comp);
+ StringBuffer contents = new StringBuffer();
+ BufferedReader br = new BufferedReader(fr);
+ String line = "";
+ while (line != null) {
+ if (line.startsWith("#registrator")) {
+ line = line.substring(1);
+ }
+ contents.append(line + "\n");
+ line = br.readLine();
+ }
+
+ FileWriter fw = new FileWriter(comp);
+ BufferedWriter bw = new BufferedWriter(fw);
+ bw.write(contents.toString().trim());
+ bw.close();
+ fw.close();
+ br.close();
+ fr.close();
+ }
+
+ /**
+ * Method for removing ls registration components from
components.properties
+ * file
+ *
+ * @throws IOException
+ */
+ private void removeRegistrationComponents() throws IOException {
+ File comp = new File(ServicePath + ComponentsPropertiesPath);
+ FileReader fr = new FileReader(comp);
+ StringBuffer contents = new StringBuffer();
+ BufferedReader br = new BufferedReader(fr);
+ String line = "";
+ while (line != null) {
+ if (line.startsWith("registrator")) {
+ line = "#" + line;
+ }
+ contents.append(line + "\n");
+ line = br.readLine();
+ }
+
+ FileWriter fw = new FileWriter(comp);
+ BufferedWriter bw = new BufferedWriter(fw);
+ bw.write(contents.toString().trim());
+ bw.close();
+ fw.close();
+ br.close();
+ fr.close();
+ }
+
+ /**
+ * Method for performing final actions for service configuration
+ *
+ * @return
+ * @throws Exception
+ */
+ public boolean finishConfiguration() throws Exception {
+
+ PerfsonarProperties serviceProperties = new
PerfsonarPropertiesImpl();
+ serviceProperties.loadProperties(new
FileInputStream(ServicePath
+ + ServicePropertiesPath));
+ PerfsonarProperty property = new PerfsonarProperty();
+ property.setKey("service.sax_parser.config");
+ property.setValue(ServicePath + ObjectsConfigPath);
+ property.setGroup("Internals");
+ property.setDescription("Sax parser configuration paramater");
+ serviceProperties.setProperty(property.getKey(), property);
+ property = new PerfsonarProperty();
+ property.setKey("service.log.log4j.config");
+ property.setValue(ServicePath + LoggingPropertiesPath);
+ property.setGroup("Internals");
+ property.setDescription("Logging Properties path");
+ serviceProperties.setProperty(property.getKey(), property);
+ serviceProperties.storeProperties(new
FileOutputStream(ServicePath
+ + ServicePropertiesPath));
+
+ return true;
+
+ }
+
+ /**
+ * Method to get the stack trace of an exception
+ *
+ * @param e
+ * The exception
+ * @return A string with stack the trace
+ */
+ private String getFault(Exception e) {
+ StackTraceElement[] trace = e.getStackTrace();
+ String fault = e.getMessage();
+ for (int j = 0; j < trace.length; j++) {
+ fault += trace[j].toString() + "\n";
+ }
+ return fault;
+ }
+
}
\ No newline at end of file



  • perfsonar: r4526 - in trunk/rnp_java-cl-mp: . ant conf conf/axis-1.4 conf/axis-1.4/WEB-INF conf/axis-1.4/graphics conf/cron conf/cron/local conf/scripts doc doc/schema lib/misc packaging packaging/deb packaging/rpm samples/requests samples/responses src/main/java/org/perfsonar/service/measurementPoint/commandLine src/main/java/org/perfsonar/service/measurementPoint/commandLine/tools src/main/java/org/perfsonar/service/measurementPoint/commandLine/utils src/main/java/perfSONARWebAdmin/admin/wizard/services, svnlog, 09/22/2008

Archive powered by MHonArc 2.6.16.

Top of Page