Return-Path: X-Original-To: apmail-camel-commits-archive@www.apache.org Delivered-To: apmail-camel-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9033F10185 for ; Fri, 29 Nov 2013 15:45:18 +0000 (UTC) Received: (qmail 27628 invoked by uid 500); 29 Nov 2013 15:44:36 -0000 Delivered-To: apmail-camel-commits-archive@camel.apache.org Received: (qmail 27527 invoked by uid 500); 29 Nov 2013 15:44:30 -0000 Mailing-List: contact commits-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list commits@camel.apache.org Received: (qmail 27346 invoked by uid 99); 29 Nov 2013 15:44:18 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 29 Nov 2013 15:44:18 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 09806908B85; Fri, 29 Nov 2013 15:44:18 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: davsclaus@apache.org To: commits@camel.apache.org Date: Fri, 29 Nov 2013 15:44:17 -0000 Message-Id: <0e297efd7a144ab49c070771ef459b55@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [1/2] git commit: CAMEL-7023: Added hawtio goal to camel maven plugin. Updated Branches: refs/heads/camel-2.12.x d2ef3e266 -> cdb579454 refs/heads/master 799f95cbb -> 5520035be CAMEL-7023: Added hawtio goal to camel maven plugin. Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/5520035b Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/5520035b Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/5520035b Branch: refs/heads/master Commit: 5520035be29cb842d27e0bf2b77ed0c1a4cc17eb Parents: 799f95c Author: Claus Ibsen Authored: Fri Nov 29 16:46:05 2013 +0100 Committer: Claus Ibsen Committed: Fri Nov 29 16:46:05 2013 +0100 ---------------------------------------------------------------------- .../src/main/java/org/apache/camel/maven/HawtioMojo.java | 2 +- .../src/main/java/org/apache/camel/maven/RunMojo.java | 11 ++++++++++- 2 files changed, 11 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/5520035b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/HawtioMojo.java ---------------------------------------------------------------------- diff --git a/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/HawtioMojo.java b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/HawtioMojo.java index 1c8f697..b7b6159 100644 --- a/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/HawtioMojo.java +++ b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/HawtioMojo.java @@ -43,7 +43,7 @@ public class HawtioMojo extends RunMojo { } @Override - void beforeBootstrapCamel() throws Exception { + protected void beforeBootstrapCamel() throws Exception { getLog().info("Starting hawtio ..."); Method hawtioMain = Thread.currentThread().getContextClassLoader().loadClass("io.hawt.app.App") .getMethod("main", new Class[] {String[].class}); http://git-wip-us.apache.org/repos/asf/camel/blob/5520035b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/RunMojo.java ---------------------------------------------------------------------- diff --git a/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/RunMojo.java b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/RunMojo.java index bb2fdcb..edf46fc 100644 --- a/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/RunMojo.java +++ b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/RunMojo.java @@ -488,6 +488,8 @@ public class RunMojo extends AbstractExecMojo { main.setAccessible(true); } main.invoke(main, new Object[] {arguments}); + + afterBootstrapCamel(); } catch (Exception e) { // just pass it on // let it be printed so end users can see the exception on the console getLog().error("*************************************"); @@ -540,7 +542,14 @@ public class RunMojo extends AbstractExecMojo { /** * Allows plugin extensions to do custom logic before bootstrapping Camel. */ - void beforeBootstrapCamel() throws Exception { + protected void beforeBootstrapCamel() throws Exception { + // noop + } + + /** + * Allows plugin extensions to do custom logic after bootstrapping Camel. + */ + protected void afterBootstrapCamel() throws Exception { // noop }