You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by cw...@apache.org on 2013/01/02 20:10:20 UTC

svn commit: r1427914 [1/6] - in /uima/sandbox/uima-ducc/trunk/uima-ducc-common: main/ main/java/ main/java/.settings/ main/java/org/ main/java/org/apache/ main/java/org/apache/uima/ main/java/org/apache/uima/ducc/ main/java/org/apache/uima/ducc/common/...

Author: cwiklik
Date: Wed Jan  2 19:10:17 2013
New Revision: 1427914

URL: http://svn.apache.org/viewvc?rev=1427914&view=rev
Log:
UIMA-2491

Added:
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/.settings/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/.settings/org.eclipse.jdt.core.prefs
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ANodeStability.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/DuccNode.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDucc.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDuccEnv.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IIdentity.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Identity.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Node.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/NodeIdentity.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Pair.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ServiceStatistics.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/UimaAsServiceMonitor.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEvent.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEventKill.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccNodeCpuUsage.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccProcessCpuUsage.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/NodeCpuUsage.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/ProcessCpuUsage.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccNodeMemory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccProcessResidentMemory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/NodeMemory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/ProcessResidentMemory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationManager.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationResult.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/IAuthenticationManager.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/IAuthenticationResult.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/SessionManager.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/boot/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/boot/DuccDaemonRuntimeProperties.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/component/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/component/AbstractDuccComponent.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/component/AbstractDuccComponentMBean.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/component/DuccComponent.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/component/DuccLifecycle.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/config/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/config/CommonConfiguration.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/config/DuccBlastGuardPredicate.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/crypto/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/crypto/Crypto.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/crypto/CryptoException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/crypto/ICrypto.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/exception/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/exception/DuccComponentInitializationException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/exception/DuccConfigurationException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/exception/DuccException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/exception/DuccRuntimeException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/internationalization/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/internationalization/Messages.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/internationalization/Messages.properties   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/internationalization/Placeholders.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/JdConstants.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/files/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/files/IWorkItemState.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/files/WorkItemState.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/files/WorkItemStateManager.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/AbstractJdProcessExceptionHandler.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/IJdProcessExceptionHandler.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/JdProcessExceptionHandler.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/JdProcessExceptionHandlerLoader.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/TestJdProcessExceptionHandler.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/example/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/jd/plugin/example/ExampleJdProcessExceptionHandler.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/launcher/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/launcher/ssh/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/launcher/ssh/DuccRemoteLauncher.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/launcher/ssh/ProcessLaunchException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/main/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/main/DuccAdmin.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/main/DuccService.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/ByteBufferParser.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/DefaultNodeLoadAverageInfo.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/Metric.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeCpuInfo.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeInventory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeLoadAverage.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeLoadAverageInfo.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeMemoryInfo.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeMetrics.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/NodeUsersInfo.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/ProcessGarbageCollectionStats.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/node/metrics/ProcessResidentMemoryInfo.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/IPropertiesFileManager.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/PropertiesFileManager.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/services/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/services/IStateServices.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/services/StateServices.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/services/StateServicesDirectory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/persistence/services/StateServicesSet.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/system/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/system/SystemState.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/test/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/test/DuccCamelSpringTestSupport.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/test/DuccUnitTestDriver.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/DuccJobProcessFC.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/DuccJobProcessFC.xml   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/InitializationExceptionAE.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/InitializationExceptionPercentageAE.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/InvalidOverrideParameterException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/ProcessExceptionAE.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/ProcessExceptionPercentageAE.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/uima/UimaUtils.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/DeferredOpenRollingAppender.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/DuccCollectionUtils.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/DuccLogger.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/DuccLoggerComponents.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/DuccProperties.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/DuccPropertiesResolver.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/IDuccLoggerComponents.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/IOHelper.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/LinuxUtils.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/LoggingException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/MissingPropertyException.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/SystemPropertyResolver.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/TimeStamp.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/TimeStampConvert.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/Utils.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/Version.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/XStreamUtils.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/id/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/id/ADuccId.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/id/DuccId.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/id/DuccIdFactory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/id/IDuccId.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/utils/id/IDuccIdFactory.java   (with props)
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/resources/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/test/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/test/java/
    uima/sandbox/uima-ducc/trunk/uima-ducc-common/test/resources/

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/.settings/org.eclipse.jdt.core.prefs
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/.settings/org.eclipse.jdt.core.prefs?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/.settings/org.eclipse.jdt.core.prefs (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/.settings/org.eclipse.jdt.core.prefs Wed Jan  2 19:10:17 2013
@@ -0,0 +1,12 @@
+#Wed Jun 01 14:15:16 EDT 2011
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
+org.eclipse.jdt.core.compiler.compliance=1.6
+org.eclipse.jdt.core.compiler.debug.lineNumber=generate
+org.eclipse.jdt.core.compiler.debug.localVariable=generate
+org.eclipse.jdt.core.compiler.debug.sourceFile=generate
+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
+org.eclipse.jdt.core.compiler.source=1.6

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ANodeStability.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ANodeStability.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ANodeStability.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ANodeStability.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,121 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.util.HashMap;
+import java.util.Map;
+
+
+public abstract class ANodeStability
+    implements Runnable
+{
+
+    private HashMap<Node, Integer> heartbeats = new HashMap<Node, Integer>();
+    private int     nodeStability;
+    private int     agentMetricsRate;
+    private boolean shutdown = false;
+    private Thread  watchThread;
+
+    public ANodeStability(int nodeStability, int agentMetricsRate)
+    {
+        this.nodeStability = nodeStability;
+        this.agentMetricsRate = agentMetricsRate;
+    }
+
+    /**
+     * Starts the watchdog thread.
+     */
+    public void start()
+    {
+        watchThread = new Thread(this);
+        watchThread.setDaemon(true);
+        watchThread.start();
+    }
+
+    /**
+     * This callback is invoked when node death is suspected.  You need to do your own
+     * synchronization on your own implementation of this method if you need it.
+     */
+    public abstract void nodeDeath(Map<Node, Node> nodes);
+
+    /**
+     * Record the arrival of a node.  Implementor may want to override this to
+     * perform other logic.  Be sure to call super.nodeArrives(n) if you
+     * override or none of this works.
+     */
+    public synchronized void nodeArrives(Node n)
+    {
+        heartbeats.put(n, 0);
+    }
+
+    /**
+     * Called if a heartbeat is missed, in case caller wants to do take some action
+     * such as logging the event.  OK to do nothing. Implementor must synchronize if desired.
+     */
+    public abstract void missedNode(Node n, int c);
+
+    /**
+     * Graceful shutdown of the thread.
+     */
+    public synchronized void shutdown()
+    {
+        this.shutdown = true;
+        watchThread.interrupt();
+    }
+
+    /**
+     * Thread main, run forvever checking for delinquent nodes.
+     */
+    public void run()
+    {
+        HashMap<Node, Node> deadNodes = new HashMap<Node, Node>();
+        while ( true ) {            
+            synchronized(this)                
+            {
+                if ( shutdown ) return;
+
+                for ( Node n : heartbeats.keySet() ) {
+                    int c = heartbeats.get(n);
+                    
+                    if ( c++ > nodeStability )  deadNodes.put(n,n);
+                    if ( c > 1 )                missedNode(n, c);    // tell implementor if he cares
+                                                                     // note that first miss is "free"
+                                                                     // because of timing, it may not be
+                                                                     // a real miss
+                    heartbeats.put(n, c);
+                }
+            }
+            
+            if ( deadNodes.size() > 0 ) {
+                nodeDeath(deadNodes);                 // tell implementors
+                for ( Node n : deadNodes.keySet() ) {          // clear from list of known nodes
+                    heartbeats.remove(n);             //   so we don't keep harassing implementors
+                }
+                deadNodes.clear();                    // and clear our own list 
+            }
+
+            try {
+				Thread.sleep(agentMetricsRate);
+			} catch (InterruptedException e) {
+				// nothing
+			}
+        }
+        
+    }
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ANodeStability.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/DuccNode.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/DuccNode.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/DuccNode.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/DuccNode.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,86 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import org.apache.uima.ducc.common.node.metrics.NodeMetrics;
+
+public class DuccNode implements Node {
+	private static final long serialVersionUID = -2579068359378835062L;
+	private NodeIdentity nodeIdentity;
+	private NodeMetrics nodeMetrics;
+	private boolean duccLingExists;
+	private boolean runWithDuccLing;
+	
+	public DuccNode( NodeIdentity nodeIdentity, NodeMetrics nodeMetrics) {
+		this.nodeIdentity = nodeIdentity;
+		this.nodeMetrics = nodeMetrics;
+	}
+	public boolean duccLingExists() {
+		return duccLingExists;
+	}
+	public void duccLingExists(boolean duccLingExists) {
+		this.duccLingExists = duccLingExists;
+	}
+	public boolean runWithDuccLing() {
+		return runWithDuccLing;
+	}
+	public void runWithDuccLing(boolean runWithDuccLing) {
+		this.runWithDuccLing = runWithDuccLing;
+	}
+
+	public NodeMetrics getNodeMetrics() {
+		return nodeMetrics;
+	}
+
+	public NodeIdentity getNodeIdentity() {
+		return nodeIdentity;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.lang.Object#hashCode()
+	 */
+	@Override
+	public int hashCode() {
+		final int prime = 31;
+		int result = 1;
+		result = prime * result
+				+ ((nodeIdentity == null) ? 0 : nodeIdentity.hashCode());
+		return result;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.lang.Object#equals(java.lang.Object)
+	 */
+	@Override
+	public boolean equals(Object obj) {
+		if (this == obj)
+			return true;
+		if (obj == null)
+			return false;
+		if (getClass() != obj.getClass())
+			return false;
+		DuccNode other = (DuccNode) obj;
+		if (nodeIdentity == null) {
+			if (other.nodeIdentity != null)
+				return false;
+		} else if (!nodeIdentity.equals(other.nodeIdentity))
+			return false;
+		return true;
+	}
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/DuccNode.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDucc.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDucc.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDucc.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDucc.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.io.File;
+
+public class IDucc {
+	
+	public static final String userLogsSubDirectory = File.separator+"ducc"+File.separator+"logs"+File.separator;
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDucc.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDuccEnv.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDuccEnv.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDuccEnv.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDuccEnv.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.io.File;
+
+public interface IDuccEnv {
+
+	public static final String DUCC_HOME = System.getenv().get("DUCC_HOME");
+	
+	public static final String DUCC_HOME_DIR = DUCC_HOME+File.separator;
+	public static final String DUCC_RESOURCES_DIR = DUCC_HOME_DIR+"resources"+File.separator;
+	public static final String DUCC_PROPERTIES_FILE = DUCC_RESOURCES_DIR+"ducc.properties";
+	//TODO
+	@Deprecated
+	public static final String DUCC_AUTHORIZED_MACHINES_FILE = DUCC_RESOURCES_DIR+"ducc.authorized-machines-list";
+	public static final String DUCC_NODES_FILE_NAME = "ducc.nodes";
+	public static final String DUCC_NODES_FILE_PATH = DUCC_RESOURCES_DIR+DUCC_NODES_FILE_NAME;
+	public static final String DUCC_ADMINISTRATORS_FILE = DUCC_RESOURCES_DIR+"ducc.administrators";
+	
+	public static final String DUCC_STATE_DIR = DUCC_HOME_DIR+"state"+File.separator;
+	public static final String DUCC_DAEMONS_DIR = DUCC_STATE_DIR+"daemons"+File.separator;
+	
+	public static final String DUCC_HISTORY_DIR = DUCC_HOME_DIR+"history"+File.separator;
+	public static final String DUCC_HISTORY_JOBS_DIR = DUCC_HOME_DIR+"history"+File.separator+"jobs"+File.separator;
+	public static final String DUCC_HISTORY_RESERVATIONS_DIR = DUCC_HOME_DIR+"history"+File.separator+"reservations"+File.separator;
+	public static final String DUCC_HISTORY_SERVICES_DIR = DUCC_HOME_DIR+"history"+File.separator+"services"+File.separator;
+
+	public static final String DUCC_STATE_SERVICES_DIR = DUCC_HOME_DIR+"state"+File.separator+"services"+File.separator;
+	
+	public static final String DUCC_LOGS_DIR = DUCC_HOME_DIR+"logs"+File.separator;
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IDuccEnv.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IIdentity.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IIdentity.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IIdentity.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IIdentity.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.io.Serializable;
+
+public interface IIdentity extends Serializable {
+	public String getName();
+	public String getIP();
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/IIdentity.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Identity.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Identity.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Identity.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Identity.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+public class Identity implements IIdentity {
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = 1L;
+	private String name;
+	private String ip;
+	
+	public Identity( String name, String ip ) {
+		this.name = name;
+		this.ip = ip;
+	}
+	public String getName() {
+		return name;
+	}
+
+	public String getIP() {
+		return ip;
+	}
+
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Identity.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Node.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Node.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Node.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Node.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.io.Serializable;
+
+import org.apache.uima.ducc.common.node.metrics.NodeMetrics;
+
+
+public interface Node extends Serializable {
+	public NodeMetrics getNodeMetrics();
+	public NodeIdentity getNodeIdentity();
+	public boolean duccLingExists();
+	public boolean runWithDuccLing();
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Node.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/NodeIdentity.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/NodeIdentity.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/NodeIdentity.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/NodeIdentity.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,114 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.io.Serializable;
+import java.net.InetAddress;
+import java.net.NetworkInterface;
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.util.List;
+
+public class NodeIdentity implements Serializable {
+	private static final long serialVersionUID = -3725003472985192870L;
+	private String name;
+	private String ip;
+	private List<IIdentity> nodeIdentities = new ArrayList<IIdentity>();
+	public NodeIdentity(String ip, String name) throws Exception {
+		setName(name);
+		setIp(ip);
+		nodeIdentities.add( new Identity(name, ip));
+	}
+	public NodeIdentity() throws Exception {
+		setName(InetAddress.getLocalHost().getCanonicalHostName());
+		setIp(InetAddress.getLocalHost().getHostAddress());
+		
+		Enumeration<NetworkInterface> netinterfaces = 
+				NetworkInterface.getNetworkInterfaces();
+	    while (netinterfaces.hasMoreElements()) {
+	        NetworkInterface iface = netinterfaces.nextElement();
+	        Enumeration<InetAddress> addresses = iface.getInetAddresses();
+	        while (addresses.hasMoreElements()) {
+	            InetAddress add = addresses.nextElement();
+	    		nodeIdentities.add( new Identity(add.getCanonicalHostName(), add.getHostAddress()));
+	        }
+	    }
+	}
+	public List<IIdentity> getNodeIdentities() {
+		return nodeIdentities;
+	}
+
+	public String getName() {
+		return name;
+	}
+
+	protected void setName(String name) {
+		this.name = name;
+	}
+
+	public String getIp() {
+		return ip;
+	}
+
+	protected void setIp(String ip) {
+		this.ip = ip;
+	}
+
+	@Override
+	public String toString() {
+		return "Name:"+name+" IP:"+ip;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.lang.Object#hashCode()
+	 */
+	@Override
+	public int hashCode() {
+		final int prime = 31;
+		int result = 1;
+		result = prime * result + ((ip == null) ? 0 : ip.hashCode());
+		result = prime * result + ((name == null) ? 0 : name.hashCode());
+		return result;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.lang.Object#equals(java.lang.Object)
+	 */
+	@Override
+	public boolean equals(Object obj) {
+		if (this == obj)
+			return true;
+		if (obj == null)
+			return false;
+		if (getClass() != obj.getClass())
+			return false;
+		NodeIdentity other = (NodeIdentity) obj;
+		if (ip == null) {
+			if (other.ip != null)
+				return false;
+		} else if (!ip.equals(other.ip))
+			return false;
+		if (name == null) {
+			if (other.name != null)
+				return false;
+		} else if (!name.equals(other.name))
+			return false;
+		return true;
+	}
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/NodeIdentity.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Pair.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Pair.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Pair.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Pair.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,57 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+/**
+ * This is a simple association of two objects
+ */
+
+public class Pair<F, S>
+{
+    private F f;
+    private S s;
+
+    public Pair()
+    {
+        f = null;
+        s = null;
+    }
+
+    public Pair(F first, S second)
+    {
+        this.f = first;
+        this.s = second;
+    }
+
+    public F first()
+    {
+        return f;
+    }
+
+    public S second()
+    {
+        return s;
+    }
+
+    public String toString()
+    {
+        return f.toString() + " " + s.toString();
+    }
+
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/Pair.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ServiceStatistics.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ServiceStatistics.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ServiceStatistics.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ServiceStatistics.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,202 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import java.io.Serializable;
+
+public class ServiceStatistics
+    implements Serializable
+{
+
+    
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = -1;
+	private static final String colWidth = "6";
+    private static final int    ncols = 10;
+    private String headerFormat = "";
+    private String dataFormat = "";
+
+    long consumerCount;
+    long producerCount;
+    long queueSize;
+
+	long queueTime;
+
+    long minEnqueueTime;
+    long maxEnqueueTime;
+    long inFlightCount;
+    long dequeueCount;
+
+    long enqueueCount;
+    long dispatchCount;
+    long expiredCount;
+
+    boolean ping;
+
+    public ServiceStatistics()
+    {
+        StringBuffer hb = new StringBuffer();
+        StringBuffer db = new StringBuffer();
+        for ( int i = 0; i < ncols; i++ ) {
+            hb.append("%");
+            hb.append(colWidth);
+            hb.append("s ");
+
+            db.append("%");
+            db.append(colWidth);
+            db.append("d ");
+        }
+        headerFormat = hb.toString();
+        dataFormat = db.toString();
+    }
+
+    public long getConsumerCount() {
+		return consumerCount;
+	}
+
+	public void setConsumerCount(long consumerCount) {
+		this.consumerCount = consumerCount;
+	}
+
+	public long getProducerCount() {
+		return producerCount;
+	}
+
+	public void setProducerCount(long producerCount) {
+		this.producerCount = producerCount;
+	}
+
+	public long getQueueSize() {
+		return queueSize;
+	}
+
+	public void setQueueSize(long queueSize) {
+		this.queueSize = queueSize;
+	}
+
+	public long getQueueTime() {
+		return queueTime;
+	}
+
+	public void setQueueTime(long queueTime) {
+		this.queueTime = queueTime;
+	}
+
+	public long getMinEnqueueTime() {
+		return minEnqueueTime;
+	}
+
+	public void setMinEnqueueTime(long minEnqueueTime) {
+		this.minEnqueueTime = minEnqueueTime;
+	}
+
+	public long getMaxEnqueueTime() {
+		return maxEnqueueTime;
+	}
+
+	public void setMaxEnqueueTime(long maxEnqueueTime) {
+		this.maxEnqueueTime = maxEnqueueTime;
+	}
+
+	public long getInFlightCount() {
+		return inFlightCount;
+	}
+
+	public void setInFlightCount(long inFlightCount) {
+		this.inFlightCount = inFlightCount;
+	}
+
+	public long getDequeueCount() {
+		return dequeueCount;
+	}
+
+	public void setDequeueCount(long dequeueCount) {
+		this.dequeueCount = dequeueCount;
+	}
+
+	public long getEnqueueCount() {
+		return enqueueCount;
+	}
+
+	public void setEnqueueCount(long enqueueCount) {
+		this.enqueueCount = enqueueCount;
+	}
+
+	public long getDispatchCount() {
+		return dispatchCount;
+	}
+
+	public void setDispatchCount(long dispatchCount) {
+		this.dispatchCount = dispatchCount;
+	}
+
+	public long getExpiredCount() {
+		return expiredCount;
+	}
+
+	public void setExpiredCount(long expiredCount) {
+		this.expiredCount = expiredCount;
+	}
+
+    public void setPing(boolean p)
+    {
+        this.ping = p;
+    }
+
+    public boolean getPing()
+    {
+        return ping;
+    }
+
+    public String header()
+    {
+        return String.format(headerFormat,
+                             "Consum",
+                             "Prod",
+                             "Qsize",
+                             "minNQ",
+                             "maxNQ",
+                             "expCnt",
+                             "inFlgt",
+                             "DQ",
+                             "NQ",
+                             "Disp");                             
+        
+    }
+
+    public String toString()
+    {
+        return String.format(dataFormat,
+                             consumerCount,  
+                             producerCount,  
+                             queueSize,      
+                             minEnqueueTime, 
+                             maxEnqueueTime,
+                             expiredCount,
+                             inFlightCount,  
+                             dequeueCount,   
+                             enqueueCount,   
+                             dispatchCount
+                             );  
+ 
+    }
+
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/ServiceStatistics.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/UimaAsServiceMonitor.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/UimaAsServiceMonitor.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/UimaAsServiceMonitor.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/UimaAsServiceMonitor.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,150 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common;
+
+import javax.management.MBeanServerConnection;
+import javax.management.MBeanServerInvocationHandler;
+import javax.management.ObjectName;
+import javax.management.QueryExp;
+import javax.management.remote.JMXConnector;
+import javax.management.remote.JMXConnectorFactory;
+import javax.management.remote.JMXServiceURL;
+
+import org.apache.activemq.broker.jmx.BrokerViewMBean;
+import org.apache.activemq.broker.jmx.QueueViewMBean;
+
+public class UimaAsServiceMonitor
+{
+    private String qname;
+    private String broker_url;
+
+    private QueueViewMBean monitoredQueue;
+    private ServiceStatistics qstats;
+
+    public UimaAsServiceMonitor(String qname, String broker_host, int broker_port)
+    {
+        this.qname = qname;
+        this.broker_url = "service:jmx:rmi:///jndi/rmi://"+ broker_host + ":" + broker_port + "/jmxrmi";        
+        this.qstats = new ServiceStatistics();
+        // System.out.println("Broker url: " + broker_url);
+    }
+
+    public ServiceStatistics getServiceStatistics()
+    {
+    	return qstats;
+    }
+    
+    /**
+     * Connect to ActiveMq and find the mbean for the queue we're trying to monitor
+     */
+    public void connect()
+        throws Exception
+    {
+        
+        JMXServiceURL url = new JMXServiceURL(broker_url);
+        JMXConnector jmxc = JMXConnectorFactory.connect(url);
+        MBeanServerConnection conn = jmxc.getMBeanServerConnection();        
+        String jmxDomain = "org.apache.activemq";  
+
+        //
+        // First get the broker name
+        //
+        ObjectName brokerObjectName = null;        
+        for (Object nameObject : conn.queryNames(new ObjectName(jmxDomain + ":*,Type=Broker"), (QueryExp) null)) {
+            //find the brokername object
+            brokerObjectName = (ObjectName) nameObject;
+            if (brokerObjectName.getCanonicalName().endsWith("Type=Broker")) {
+                // Extract just the name from the canonical name
+                String brokerName = brokerObjectName.getCanonicalName().substring(0, brokerObjectName.getCanonicalName().indexOf(","));
+                //System.out.println("Canonical name of broker is " + brokerObjectName.getCanonicalName());
+                //System.out.println("broker name is " + brokerName);
+            }
+        }
+
+        //ObjectName activeMQ = new ObjectName("org.apache.activemq:BrokerName=" + broker_name +",Type=Broker");
+
+        BrokerViewMBean mbean = (BrokerViewMBean) MBeanServerInvocationHandler.newProxyInstance(conn, brokerObjectName ,BrokerViewMBean.class, true);
+        for (ObjectName name : mbean.getQueues()) {
+            QueueViewMBean qView = (QueueViewMBean)
+                MBeanServerInvocationHandler.newProxyInstance(conn, name, QueueViewMBean.class, true);
+            
+            if ( qname.equals(qView.getName()) ) {
+                monitoredQueue = qView;
+            } else {
+                // System.out.println("Skipping queue " + qView.getName());
+            }
+        }
+        
+        if ( monitoredQueue == null ) {
+            throw new IllegalStateException("Cannot find queue: " + qname);
+        }        
+    }
+
+    public void collect()
+        throws Throwable
+    {
+        qstats.setConsumerCount(monitoredQueue.getConsumerCount());
+        qstats.setProducerCount(monitoredQueue.getProducerCount());
+        qstats.setQueueSize(monitoredQueue.getQueueSize());
+        qstats.setMinEnqueueTime(monitoredQueue.getMinEnqueueTime());
+        qstats.setMaxEnqueueTime(monitoredQueue.getMaxEnqueueTime());
+        qstats.setInFlightCount(monitoredQueue.getInFlightCount());
+        qstats.setDequeueCount(monitoredQueue.getDequeueCount());
+        qstats.setEnqueueCount(monitoredQueue.getEnqueueCount());
+        qstats.setDispatchCount(monitoredQueue.getDispatchCount());
+        qstats.setExpiredCount(monitoredQueue.getExpiredCount());
+    }
+
+    public static void main(String[] args)
+    {
+        // System.out.println(args[0] + " " + args[1] + " " + args[2]);
+        UimaAsServiceMonitor m = new UimaAsServiceMonitor(args[0], args[1], Integer.parseInt(args[2])); // qname, broker host, broker port
+        ServiceStatistics qs = m.qstats;
+
+        try {
+			m.connect();                      // connect to amq
+		} catch (Exception e1) {
+			// TODO Auto-generated catch block
+			System.out.println("Cannot connect:");
+			e1.printStackTrace();
+            return;
+		}
+
+        int lim = 10;
+        int ctr =   0;
+        while ( true ) {
+
+            try {
+                m.collect();
+            } catch (Throwable t) {
+                System.out.println("Cannot collect stats.  The queue may have been deleted. Details:");
+                t.printStackTrace();
+                return;
+            }
+            if ( (ctr++) % lim == 0 ) {
+                System.out.println(qs.header());
+            }
+            System.out.println(qs.toString());
+            try {
+				Thread.sleep(3000);
+			} catch (InterruptedException e) {
+			}
+        }
+    }
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/UimaAsServiceMonitor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEvent.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEvent.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEvent.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEvent.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,29 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.admin.event;
+
+import java.io.Serializable;
+
+public abstract class DuccAdminEvent implements Serializable {
+	private static final long serialVersionUID = 1753129558912646806L;
+	
+	public String toString() {
+		return this.getClass().getName();
+	}
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEvent.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEventKill.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEventKill.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEventKill.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEventKill.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.admin.event;
+
+public class DuccAdminEventKill extends DuccAdminEvent {
+
+	private static final long serialVersionUID = -8101741014979144426L;
+
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/admin/event/DuccAdminEventKill.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccNodeCpuUsage.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccNodeCpuUsage.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccNodeCpuUsage.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccNodeCpuUsage.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,81 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.cpu;
+
+import org.apache.uima.ducc.common.node.metrics.ByteBufferParser;
+
+/**
+ * All values in terms of Jiffies, typically hundreds of a sec 
+ *
+ */
+public class DuccNodeCpuUsage extends ByteBufferParser 
+implements NodeCpuUsage {
+
+	private static final long serialVersionUID = 1L;
+	public static final int USERJIFFIES=1;
+	public static final int NICEJIFFIES=2;
+	public static final int SYSTEMJIFFIES=3;
+	public static final int IDLEJIFFIES=4;
+	public static final int IOWAITJIFFIES=5;
+	public static final int IRQJIFFIES=6;
+	public static final int SOFTIRQJIFFIES=7;
+	
+	public DuccNodeCpuUsage(byte[] memInfoBuffer,
+			int[] memInfoFieldOffsets, int[] memInfoFiledLengths) {
+		super(memInfoBuffer, memInfoFieldOffsets, memInfoFiledLengths);
+	}	
+	public long getUserJiffies() {
+		return super.getFieldAsLong(USERJIFFIES);
+	}
+
+	public long getNiceJiffies() {
+		return super.getFieldAsLong(NICEJIFFIES);
+	}
+
+	public long getSystemJiffies() {
+		return super.getFieldAsLong(SYSTEMJIFFIES);
+	}
+
+	public long getIdleJiffies() {
+		return super.getFieldAsLong(IDLEJIFFIES);
+	}
+
+	public long getIowaitJiffies() {
+		return super.getFieldAsLong(IOWAITJIFFIES);
+	}
+
+	public long getIrqJiffies() {
+		return super.getFieldAsLong(IRQJIFFIES);
+	}
+
+	public long getSoftirqs() {
+		return super.getFieldAsLong(USERJIFFIES);
+	}
+	
+	public long getTotal() {
+		return getUserJiffies() +
+				getNiceJiffies() +
+				getSystemJiffies() +
+				getIdleJiffies() +
+				getIowaitJiffies() +
+				getIrqJiffies() +
+				getSoftirqs();
+	}
+
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccNodeCpuUsage.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccProcessCpuUsage.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccProcessCpuUsage.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccProcessCpuUsage.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccProcessCpuUsage.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.cpu;
+
+import org.apache.uima.ducc.common.node.metrics.ByteBufferParser;
+
+public class DuccProcessCpuUsage extends ByteBufferParser 
+implements ProcessCpuUsage {
+	private static final long serialVersionUID = 1L;
+	public static final int USERJIFFIES=13;
+	public static final int SYSTEMJIFFIES=14;
+    
+	public DuccProcessCpuUsage(byte[] memInfoBuffer,
+			int[] memInfoFieldOffsets, int[] memInfoFiledLengths) {
+		super(memInfoBuffer, memInfoFieldOffsets, memInfoFiledLengths);
+	}	
+	public long getUserJiffies() {
+		return super.getFieldAsLong(USERJIFFIES);
+	}
+	public long getKernelJiffies() {
+		return super.getFieldAsLong(SYSTEMJIFFIES);
+	}
+	public long getTotalJiffies() {
+		return (getUserJiffies()+getKernelJiffies());
+	}
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/DuccProcessCpuUsage.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/NodeCpuUsage.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/NodeCpuUsage.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/NodeCpuUsage.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/NodeCpuUsage.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.cpu;
+
+import java.io.Serializable;
+
+public interface NodeCpuUsage extends Serializable {
+	
+	public long getUserJiffies();
+
+	public long getNiceJiffies();
+
+	public long getSystemJiffies();
+
+	public long getIdleJiffies();
+
+	public long getIowaitJiffies();
+
+	public long getIrqJiffies();
+
+	public long getSoftirqs();
+
+	public long getTotal();
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/NodeCpuUsage.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/ProcessCpuUsage.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/ProcessCpuUsage.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/ProcessCpuUsage.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/ProcessCpuUsage.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.cpu;
+
+import java.io.Serializable;
+
+public interface ProcessCpuUsage extends Serializable {
+	public long getUserJiffies();
+	public long getKernelJiffies();
+	public long getTotalJiffies();
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/cpu/ProcessCpuUsage.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccNodeMemory.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccNodeMemory.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccNodeMemory.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccNodeMemory.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,108 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.memory;
+
+public class DuccNodeMemory implements NodeMemory {
+
+	private static final long serialVersionUID = -6166465040486459917L;
+	private long memTotal;
+	private long memFree;
+	private long buffers;
+	private long cached;
+	private long swapCached;
+	private long active;
+	private long inactive;
+	private long swapFree;
+	private long swapTotal;
+	
+	public long getMemTotal() {
+		return memTotal;
+	}
+
+	public long getMemFree() {
+		return memFree;
+	}
+
+	public long getBuffers() {
+		return buffers;
+	}
+
+	public long getCached() {
+		return cached;
+	}
+
+	public long getSwapCached() {
+		return swapCached;
+	}
+
+	public long getActive() {
+		return active;
+	}
+
+	public long getInactive() {
+		return inactive;
+	}
+
+	public long getSwapTotal() {
+		return swapTotal;
+	}
+
+	public long getSwapFree() {
+		return swapFree;
+	}
+
+	public void setMemTotal(long memTotal) {
+		this.memTotal = memTotal;
+	}
+
+	public void setMemFree(long memFree) {
+		this.memFree = memFree;
+	}
+
+	public void setBuffers(long buffers) {
+		this.buffers = buffers;
+	}
+
+	public void setCached(long cached) {
+		this.cached = cached;
+	}
+
+	public void setSwapCached(long swapCached) {
+		this.swapCached = swapCached;
+	}
+
+	public void setActive(long active) {
+		this.active = active;
+	}
+
+	public void setInactive(long inactive) {
+		this.inactive = inactive;
+	}
+
+	public void setSwapFree(long swapFree) {
+		this.swapFree = swapFree;
+	}
+
+	public void setSwapTotal(long swapTotal) {
+		this.swapTotal = swapTotal;
+	}
+
+
+
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccNodeMemory.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccProcessResidentMemory.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccProcessResidentMemory.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccProcessResidentMemory.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccProcessResidentMemory.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.memory;
+
+import org.apache.uima.ducc.common.node.metrics.ByteBufferParser;
+
+public class DuccProcessResidentMemory extends ByteBufferParser implements
+		ProcessResidentMemory {
+
+	private static final long serialVersionUID = 8563460863767404377L;
+	private static final int TOTAL = 0;
+	private static final int RESIDENT = 1;
+
+	public DuccProcessResidentMemory(byte[] memInfoBuffer,
+			int[] memInfoFieldOffsets, int[] memInfoFiledLengths) {
+		super(memInfoBuffer, memInfoFieldOffsets, memInfoFiledLengths);
+	}
+
+	public long get() {
+		return super.getFieldAsLong(RESIDENT);
+	}
+	
+	public long getTotal() {
+		return super.getFieldAsLong(TOTAL);
+	}
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/DuccProcessResidentMemory.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/NodeMemory.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/NodeMemory.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/NodeMemory.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/NodeMemory.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,41 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.memory;
+
+import java.io.Serializable;
+
+public interface NodeMemory extends Serializable {
+	public long getMemTotal();
+
+	public long getMemFree();
+
+	public long getBuffers();
+
+	public long getCached();
+
+	public long getSwapCached();
+
+	public long getActive();
+
+	public long getInactive();
+
+	public long getSwapTotal();
+
+	public long getSwapFree();
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/NodeMemory.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/ProcessResidentMemory.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/ProcessResidentMemory.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/ProcessResidentMemory.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/ProcessResidentMemory.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.agent.metrics.memory;
+
+import java.io.Serializable;
+
+public interface ProcessResidentMemory extends Serializable{
+	
+	public long get(); 
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/agent/metrics/memory/ProcessResidentMemory.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationManager.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationManager.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationManager.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationManager.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,114 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.authentication;
+
+import org.apache.log4j.Logger;
+import org.apache.uima.ducc.common.utils.DuccPropertiesResolver;
+
+
+public class AuthenticationManager implements IAuthenticationManager {
+	
+	private static final IAuthenticationResult default_authenticationResult = new AuthenticationResult();
+	
+	private static IAuthenticationManager instance = new AuthenticationManager();
+	
+	private final String version = "common 1.0";
+	
+	public static IAuthenticationManager getInstance() {
+		return instance;
+	}
+	
+	@Override
+	public String getVersion() {
+		return version;
+	}
+	
+	@Override
+	public IAuthenticationResult isAuthenticate(String userid, String domain, String password) {
+		IAuthenticationResult authenticationResult = default_authenticationResult;
+		String ducc_pw = DuccPropertiesResolver.getInstance().getFileProperty(DuccPropertiesResolver.ducc_ws_authentication_pw);
+		if(ducc_pw != null) {
+			ducc_pw = ducc_pw.trim();
+			if(ducc_pw.equals(password)) {
+				authenticationResult = new AuthenticationResult();
+				authenticationResult.setSuccess();
+			}
+		}
+		return authenticationResult;
+	}
+
+	@Override
+	public IAuthenticationResult isGroupMember(String userid, String domain, Role role) {
+		AuthenticationResult authenticationResult = new AuthenticationResult();
+		authenticationResult.setSuccess();
+		return authenticationResult;
+	}
+
+	/*
+	 * <test cases>
+	 */
+	
+	public static final String user = System.getProperty("user.name");
+	
+	private static void testUser(Logger logt, String userid, String password)
+	{
+		testUser(logt,userid,null,password);
+	}
+	
+	private static void testUser(Logger logt, String userid, String domain, String password)
+	{
+		IAuthenticationResult ar = AuthenticationManager.getInstance().isAuthenticate(userid, domain, password);
+		logt.info(userid+" "+ar.isSuccess());
+	}
+	
+	private static void testGroup(Logger logt, String userid, String domain, Role role)
+	{
+		IAuthenticationResult ar = AuthenticationManager.getInstance().isGroupMember(userid,domain,role);
+		logt.info(userid+" "+" "+role+" "+ar.isSuccess());
+	}
+	
+	private static void test(String[] args) 
+	{
+		Logger logt = Logger.getLogger("Test");
+		logt.info("test.enter");
+		testUser(logt,user,"xxxxxxxx");
+		testUser(logt,user,"foobar");
+		testUser(logt,user,"watson.ibm.com","xxxxxxxx");
+		testUser(logt,user,"watson.ibm.com","foobar");
+		testGroup(logt,user,"",Role.User);
+		testGroup(logt,user,"",Role.Admin);
+		testGroup(logt,"foobar","",Role.User);
+		logt.info("test.exit");
+	}
+	
+	public static void main(String[] args) 
+	{
+		try {
+			test(args);
+			System.out.println("Successs!");
+		}
+		catch(Exception e) {
+			e.printStackTrace();
+		}
+	}
+	
+	/*
+	 * </test cases>
+	 */
+}

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationManager.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationResult.java
URL: http://svn.apache.org/viewvc/uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationResult.java?rev=1427914&view=auto
==============================================================================
--- uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationResult.java (added)
+++ uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationResult.java Wed Jan  2 19:10:17 2013
@@ -0,0 +1,77 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+*/
+package org.apache.uima.ducc.common.authentication;
+	
+public class AuthenticationResult implements IAuthenticationResult {
+	
+	private boolean result = true;
+	private int code = -1;
+	private String reason = null;
+	private Exception exception = null;
+		
+	public AuthenticationResult() {
+	}
+	
+	public AuthenticationResult(String reason, Exception exception) {
+		setFailure();
+		setReason(reason);
+		setException(exception);
+	}
+	
+	public void setSuccess() {
+		this.result = true;
+	}
+	
+	public void setFailure() {
+		this.result = false;
+	}
+	
+	public boolean isSuccess() {
+		return this.result;
+	}
+	
+	public boolean isFailure() {
+		return !this.result;
+	}
+	
+	public void setReason(String reason) {
+		this.reason = reason;
+	}
+	
+	public String getReason() {
+		return this.reason;
+	}
+	
+	public void setException(Exception exception) {
+		this.exception = exception;
+	}
+	
+	public Exception getException() {
+		return this.exception;
+	}
+	
+	public void setCode(int code) {
+		this.code = code;
+	}
+
+	public int getCode() {
+		return code;
+	}
+}
+

Propchange: uima/sandbox/uima-ducc/trunk/uima-ducc-common/main/java/org/apache/uima/ducc/common/authentication/AuthenticationResult.java
------------------------------------------------------------------------------
    svn:eol-style = native