From d46a124be3196b02266f3edb7f3a2e6763074736 Mon Sep 17 00:00:00 2001 From: Amnon Heiman Date: Sun, 12 Apr 2015 12:48:28 +0300 Subject: [PATCH] Adding the MBean Service Support This adds the java project that expose the system MBean. The Main would start any required classes and would wait forever. The mvn creates jar with main and set the classpath accordingly. To start do: java -jar target/urchin-mbean-1.0.jar Signed-off-by: Amnon Heiman --- pom.xml | 72 +++++++++++++++++++++++ src/main/java/com/cloudius/main/Main.java | 13 ++++ 2 files changed, 85 insertions(+) create mode 100644 pom.xml create mode 100644 src/main/java/com/cloudius/main/Main.java diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..8ec48f7 --- /dev/null +++ b/pom.xml @@ -0,0 +1,72 @@ + + 4.0.0 + + com.cloudius.urchin + urchin-mbean + 1.0 + jar + + Urchin MBean + + + 1.8 + 1.8 + + + + + com.sun.jersey + jersey-client + 1.19 + + + + junit + junit + 4.8.2 + test + + + org.glassfish + javax.json + 1.0.4 + + + + + + org.apache.maven.plugins + maven-dependency-plugin + + + copy-dependencies + prepare-package + + copy-dependencies + + + ${project.build.directory}/lib + false + false + true + + + + + + org.apache.maven.plugins + maven-jar-plugin + + + + true + ${project.build.directory}/lib/ + com.cloudius.main.Main + + + + + + + diff --git a/src/main/java/com/cloudius/main/Main.java b/src/main/java/com/cloudius/main/Main.java new file mode 100644 index 0000000..87b12f7 --- /dev/null +++ b/src/main/java/com/cloudius/main/Main.java @@ -0,0 +1,13 @@ +/* + * Copyright 2015 Cloudius Systems + */ +package com.cloudius.main; + +public class Main { + + public static void main(String[] args) throws Exception { + System.out.println("Starting the JMX server"); + Thread.sleep(Long.MAX_VALUE); + } + +}