From 074ca094dfe08c4d154f4ffdfd6575ac28d986c3 Mon Sep 17 00:00:00 2001 From: antelder Date: Sun, 6 Jul 2008 09:53:42 +0000 Subject: TUSCANY-2391: Apply latest patch from Thilina Buddhika for the GSoC Tuscany SCA support in the Geronimo Admin Console project git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@674279 13f79535-47bb-0310-9956-ffa450edef68 --- sandbox/thilina/geronimo_ACE/README.txt | 19 ++--- sandbox/thilina/geronimo_ACE/pom.xml | 94 ++++++++++++---------- .../apache/tuscany/geronimoace/GeronimoACE.java | 48 ++++++++--- .../src/main/webapp/WEB-INF/geronimo-web.xml | 20 +++++ .../src/main/webapp/WEB-INF/portlet.xml | 25 ++++-- .../geronimo_ACE/src/main/webapp/WEB-INF/web.xml | 35 ++++---- .../geronimo_ACE/src/main/webapp/pages/Home.jsp | 71 ++++++++++++++++ .../src/main/webapp/pages/ListDomains.jsp | 23 ++++++ .../src/main/webapp/pages/ManageDomain.jsp | 23 ++++++ 9 files changed, 272 insertions(+), 86 deletions(-) create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Home.jsp create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ListDomains.jsp create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ManageDomain.jsp (limited to 'sandbox') diff --git a/sandbox/thilina/geronimo_ACE/README.txt b/sandbox/thilina/geronimo_ACE/README.txt index 38cdfe0a46..fd53333d2a 100644 --- a/sandbox/thilina/geronimo_ACE/README.txt +++ b/sandbox/thilina/geronimo_ACE/README.txt @@ -1,9 +1,10 @@ -How to build the Admin Console Extension -======================================== - -1.Extract the archive. -2.Go to the directory created after extracting the archive. -3.Type the following command "mvn install" -4.It will create a directory named "target" which contains the "org.apache.tuscany.geronimoace.geronimo-ace-1.0-SNAPSHOT.war". -5.Deploy this in geronimo. - + +How to build the Admin Console Extension +======================================== + +1.Extract the archive. +2.Go to the directory created after extracting the archive. +3.Type the following command "mvn install" +4.It will create a directory named "target" which contains the "org.apache.tuscany.geronimoace.geronimo-ace-1.0-SNAPSHOT.war". +5.Deploy this in geronimo. + diff --git a/sandbox/thilina/geronimo_ACE/pom.xml b/sandbox/thilina/geronimo_ACE/pom.xml index 9bbeb2ed9d..4d6cd5764d 100644 --- a/sandbox/thilina/geronimo_ACE/pom.xml +++ b/sandbox/thilina/geronimo_ACE/pom.xml @@ -1,44 +1,50 @@ - - 4.0.0 - org.apache.tuscany.geronimoace - org.apache.tuscany.geronimoace.geronimo-ace - war - 1.0-SNAPSHOT - geronimo-ace - http://maven.apache.org - - - junit - junit - 3.8.1 - test - - - portlet-api - portlet-api - 1.0 - - - javax.portlet - portlet-api - 1.0 - - - - - install - ${basedir}/target - ${artifactId}-${version} - - - WEB-INF - false - ${basedir}/src/webapp/WEB-INF - - web.xml - - - - - + + 4.0.0 + org.apache.tuscany.geronimoace + org.apache.tuscany.geronimoace.geronimo-ace + war + 1.0-SNAPSHOT + geronimo-ace + http://maven.apache.org + + + junit + junit + 3.8.1 + test + + + portlet-api + portlet-api + 1.0 + + + javax.portlet + portlet-api + 1.0 + + + javax.servlet + servlet-api + 2.4 + provided + + + + + install + ${basedir}/target + ${artifactId}-${version} + + + WEB-INF + false + ${basedir}/src/webapp/WEB-INF + + web.xml + + + + + diff --git a/sandbox/thilina/geronimo_ACE/src/main/java/org/apache/tuscany/geronimoace/GeronimoACE.java b/sandbox/thilina/geronimo_ACE/src/main/java/org/apache/tuscany/geronimoace/GeronimoACE.java index eb52936bb6..a692e4eac7 100644 --- a/sandbox/thilina/geronimo_ACE/src/main/java/org/apache/tuscany/geronimoace/GeronimoACE.java +++ b/sandbox/thilina/geronimo_ACE/src/main/java/org/apache/tuscany/geronimoace/GeronimoACE.java @@ -17,6 +17,25 @@ * under the License. */ +/* + * 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.tuscany.geronimoace; import javax.portlet.*; @@ -24,17 +43,26 @@ import java.io.IOException; import java.io.PrintWriter; public class GeronimoACE extends GenericPortlet { - public void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { + private String viewUrl; + + + public void init(PortletConfig config) throws PortletException { + + super.init(config); + // viewUrl = config.getInitParameter("view_url"); + } + + + public void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { // Set the response to read HTML - response.setContentType("text/html;charset=UTF-8"); - - // Required call for use of getWriter() and getPortletOutputStream() - PrintWriter out = response.getWriter(); - out.println(""); - out.println("Hello World"); - out.println(""); - out.flush(); - out.close(); + response.setContentType("text/html;charset=UTF-8"); + + + PortletRequestDispatcher dispatcher = getPortletContext().getRequestDispatcher("/pages/Home.jsp"); + dispatcher.include(request,response); + + } + } diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/geronimo-web.xml b/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/geronimo-web.xml index 7b0c484c49..dde24a2a71 100644 --- a/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/geronimo-web.xml +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/geronimo-web.xml @@ -18,6 +18,26 @@ --> + + + diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/portlet.xml b/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/portlet.xml index f8f722e8cd..3f54ae7fef 100644 --- a/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/portlet.xml +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/portlet.xml @@ -18,7 +18,24 @@ --> - + Geronimo Admin Console for Tuscany org.apache.tuscany.geronimoace.GeronimoACE - + text/html view @@ -38,6 +55,4 @@ xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http: Tuscany ACE - - - + \ No newline at end of file diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/web.xml b/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/web.xml index c40f92057e..df6dd829ce 100644 --- a/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/web.xml +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/WEB-INF/web.xml @@ -1,22 +1,21 @@ - + * 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. +--> diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Home.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Home.jsp new file mode 100644 index 0000000000..d23cf9c7a0 --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Home.jsp @@ -0,0 +1,71 @@ + + +<%@ page language="java" contentType="text/html; charset=ISO-8859-1" + pageEncoding="ISO-8859-1"%> + + + +Simple jsp page + + + + + + + + +
Tuscany SCA Domain Manager
+

 

+ + + + + + + +
+

 

+

 

+

 

+

 

+

 

+ + + + + +
AboutTuscany Home
+

 

+ + \ No newline at end of file diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ListDomains.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ListDomains.jsp new file mode 100644 index 0000000000..0e5257fb0d --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ListDomains.jsp @@ -0,0 +1,23 @@ + +<%@ page contentType="text/html;charset=UTF-8" language="java" %> + + Simple jsp page + Place your content here + \ No newline at end of file diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ManageDomain.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ManageDomain.jsp new file mode 100644 index 0000000000..0e5257fb0d --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/ManageDomain.jsp @@ -0,0 +1,23 @@ + +<%@ page contentType="text/html;charset=UTF-8" language="java" %> + + Simple jsp page + Place your content here + \ No newline at end of file -- cgit v1.2.3