From 75936da5fc97e5dc242465ee6d76f260c96fa994 Mon Sep 17 00:00:00 2001 From: antelder Date: Sun, 3 Aug 2008 06:47:39 +0000 Subject: TUSCANY-2391, apply lates patch from Thilina Buddhika git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@682109 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/tuscany/geronimoace/GeronimoACE.java | 156 +++--- .../geronimo_ACE/src/main/webapp/pages/Cloud.jsp | 384 ++++++++++++++ .../src/main/webapp/pages/Composite.html | 577 +++++++++++---------- .../src/main/webapp/pages/Composite.jsp | 282 ++++++++++ .../geronimo_ACE/src/main/webapp/pages/Files.jsp | 120 +++++ .../src/main/webapp/pages/Workspace.jsp | 174 +++++++ 6 files changed, 1329 insertions(+), 364 deletions(-) create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Cloud.jsp create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.jsp create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Files.jsp create mode 100644 sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Workspace.jsp (limited to 'sandbox/thilina/geronimo_ACE/src') 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 3eb5b82ed3..8905bf7152 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 @@ -1,78 +1,78 @@ -/* - * 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.*; -import java.io.IOException; - -public class GeronimoACE extends GenericPortlet { - private String viewUrl = "/pages/Home.jsp"; // viewUrl is set to the home page by default - boolean isHome = true; // used for navigating back to the home page. - - - public void init(PortletConfig config) throws PortletException { - super.init(config); - } - - public void processAction(ActionRequest request, ActionResponse response) throws PortletException, IOException { - isHome = true; - String task = request.getParameter("task"); // getting request parameters task and domain name - String domain = request.getParameter("domainName"); - if (task != null) { - if (task.equals("composites")) { // if the request is for Composites,forwarding to Composites.html - viewUrl = "/pages/Composite.html"; - } - if (task.equals("workspace")) { // if the request is for Contributions,forwarding to workspace.html - viewUrl = "/pages/Workspace.html"; - } - if (task.equals("cloud")) { // if the request is for Clouds,forwarding to Cloud.html - viewUrl = "/pages/Cloud.html"; - } - if (task.equals("files")) { // iif the request is for Files,forwarding to Files.html - viewUrl = "/pages/Files.html"; - } - } - - response.setPortletMode(PortletMode.VIEW); // by changing portlet mode, doview methos is called again. - - - } - - public void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { - // Set the response to read HTML - response.setContentType("text/html;charset=UTF-8"); - - if (isHome) { - // dispatching to the appropriate page - PortletRequestDispatcher dispatcher = getPortletContext().getRequestDispatcher(viewUrl); - dispatcher.include(request, response); - isHome = false; - } else { - // dispatching to the home page. - PortletRequestDispatcher dispatcher = getPortletContext().getRequestDispatcher("/pages/Home.jsp"); - dispatcher.include(request, response); - isHome = true; - } - } - -} - - - +/* + * 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.*; +import java.io.IOException; + +public class GeronimoACE extends GenericPortlet { + private String viewUrl = "/pages/Home.jsp"; // viewUrl is set to the home page by default + boolean isHome = true; // used for navigating back to the home page. + + + public void init(PortletConfig config) throws PortletException { + super.init(config); + } + + public void processAction(ActionRequest request, ActionResponse response) throws PortletException, IOException { + isHome = true; + String task = request.getParameter("task"); // getting request parameters task and domain name + String domain = request.getParameter("domainName"); + if (task != null) { + if (task.equals("composites")) { // if the request is for Composites,forwarding to Composites.html + viewUrl = "/pages/Composite.jsp"; + } + if (task.equals("workspace")) { // if the request is for Contributions,forwarding to workspace.html + viewUrl = "/pages/Workspace.jsp"; + } + if (task.equals("cloud")) { // if the request is for Clouds,forwarding to Cloud.html + viewUrl = "/pages/Cloud.jsp"; + } + if (task.equals("files")) { // iif the request is for Files,forwarding to Files.html + viewUrl = "/pages/Files.jsp"; + } + } + + response.setPortletMode(PortletMode.VIEW); // by changing portlet mode, doview methos is called again. + + + } + + public void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { + // Set the response to read HTML + response.setContentType("text/html;charset=UTF-8"); + + if (isHome) { + // dispatching to the appropriate page + PortletRequestDispatcher dispatcher = getPortletContext().getRequestDispatcher(viewUrl); + dispatcher.include(request, response); + isHome = false; + } else { + // dispatching to the home page. + PortletRequestDispatcher dispatcher = getPortletContext().getRequestDispatcher("/pages/Home.jsp"); + dispatcher.include(request, response); + isHome = true; + } + } + +} + + + diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Cloud.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Cloud.jsp new file mode 100644 index 0000000000..c264528092 --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Cloud.jsp @@ -0,0 +1,384 @@ +<%-- + Created by IntelliJ IDEA. + User: thilinamb + Date: Jul 30, 2008 + Time: 3:13:19 PM + To change this template use File | Settings | File Templates. +--%> +<%@ page contentType="text/html;charset=UTF-8" language="java" %> +<%@ include file="header.jsp" %> + +SCA Domain - Cloud + + + + + + + + + +
+ +
+
+ + SCA Domain

+ Cloud  +
+

+ Here is the list of SCA nodes configured in your SCA domain cloud. +

+ +
+
+ + + + + + + + + + +
NodeStatusCompositeContributionNode Config
+
+
+ + + +
+ +

+ +
+ + + + + + + +
Add a Node
Add a node to the cloud. The node will run the SCA components declared in the specified composite. +
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
Node name:e.g. YourNode
Node URI:e.g. http://yourhost:8080
Composite namespace:e.g. http://your/namespace
Composite name:e.g. yourcomposite
Contribution URI:e.g. yourcontrib, http://yourcontrib
+ +
+ +
+ + \ No newline at end of file diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.html b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.html index f616f61bd6..164ea2e6b4 100644 --- a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.html +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.html @@ -1,286 +1,291 @@ - - - -SCA Domain - Domain Composite - - - - - - - - - - -
- -
-
- - SCA Domain

- Domain Composite  -
-

- Here is the list of SCA composites currently included as top-level composites in your SCA domain. - -

- - -
- -
- - - - - - - - -
CompositeContributionComponents
-
-
- -
- -

- -
- - - - - - - -
Add Composite
Add an SCA composite describing your SCA service components.
-
- - - - - - - - - - - - - - - - -
Composite namespace:e.g. http://your/namespace
Composite name:e.g. yourcomposite
Contribution URI:e.g. yourcontrib, http://yourcontrib
- -
- -
- - + + + +SCA Domain - Domain Composite + + + + + + + + + + +
+ +
+
+ + SCA Domain

+ Domain Composite  +
+

+ Here is the list of SCA composites currently included as top-level composites in your SCA domain. + +

+ + +
+ +
+ + + + + + + + +
CompositeContributionComponents
+
+
+ +
+ +

+ +
+ + + + + + + +
Add Composite
Add an SCA composite describing your SCA service components.
+
+ + + + + + + + + + + + + + + + +
Composite namespace:e.g. http://your/namespace
Composite name:e.g. yourcomposite
Contribution URI:e.g. yourcontrib, http://yourcontrib
+ +
+ +
+ + diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.jsp new file mode 100644 index 0000000000..8dcc0e005c --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Composite.jsp @@ -0,0 +1,282 @@ +<%-- + Created by IntelliJ IDEA. + User: thilinamb + Date: Jul 25, 2008 + Time: 5:52:31 PM + To change this template use File | Settings | File Templates. +--%> +<%@ page contentType="text/html;charset=UTF-8" language="java" %> +<%@ include file="header.jsp" %> + + +SCA Domain - Domain Composite + + + + + + + + + + +
+ +
+
+ + SCA Domain

+ Domain Composite  +
+

+ Here is the list of SCA composites currently included as top-level composites in your SCA domain. + +

+ + +
+ +
+ + + + + + + + +
CompositeContributionComponents
+
+
+ +
+ +

+ +
+ + + + + + + +
Add Composite
Add an SCA composite describing your SCA service components.
+
+ + + + + + + + + + + + + + + + +
Composite namespace:e.g. http://your/namespace
Composite name:e.g. yourcomposite
Contribution URI:e.g. yourcontrib, http://yourcontrib
+ +
+ +
+ + diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Files.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Files.jsp new file mode 100644 index 0000000000..0b5e76c203 --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Files.jsp @@ -0,0 +1,120 @@ +<%-- + Created by IntelliJ IDEA. + User: thilinamb + Date: Jul 30, 2008 + Time: 3:18:21 PM + To change this template use File | Settings | File Templates. +--%> +<%@ page contentType="text/html;charset=UTF-8" language="java" %> +<%@ include file="header.jsp" %> + + + + SCA Domain - Contribution File Server + + + + + + + + + +
+ +
+
+ + SCA Domain

+ File Server  +
+

+ This is a simple ATOM-based file server useful to share files if you don't have an FTP, SVN or Maven repository. +

+ +
+
+ + + + + + +
Files
+
+
+ +
+ +

+ +
+ + + + + + + +
Upload File
Upload a file to the server.
+
+ + + + + +
File:
+
+ +
+ +
+ + \ No newline at end of file diff --git a/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Workspace.jsp b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Workspace.jsp new file mode 100644 index 0000000000..c2e3a84246 --- /dev/null +++ b/sandbox/thilina/geronimo_ACE/src/main/webapp/pages/Workspace.jsp @@ -0,0 +1,174 @@ +<%-- + Created by IntelliJ IDEA. + User: thilinamb + Date: Jul 30, 2008 + Time: 3:20:23 PM + To change this template use File | Settings | File Templates. +--%> +<%@ page contentType="text/html;charset=UTF-8" language="java" %> +<%@ include file="header.jsp" %> + + +SCA Domain - Contributions + + + + + + + + + +
+ +
+
+ + SCA Domain

+ Contributions
+

+ Here is the list of SCA contributions currently available in your SCA domain. +

+ +
+
+ + + + + + + + +
ContributionDependenciesDeployable Composites
+
+
+ +
+ +

+ +
+ + + + + + + +
Add Contribution
Add an SCA contribution containing your application artifacts to the SCA domain.
+
+ + + + + + + + + + + +
Contribution URI:e.g. yourcontrib, http://yourcontrib
Location:e.g. http://host/yourjar.jar, file:/yourdir, file:/yourjar.jar
+ +
+ +
+ + \ No newline at end of file -- cgit v1.2.3