portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject svn commit: r1662799 - in /portals/jetspeed-2/portal/trunk: ./ components/jetspeed-portal/ components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/ componen...
Date Fri, 27 Feb 2015 19:02:52 GMT
Author: taylor
Date: Fri Feb 27 19:02:51 2015
New Revision: 1662799

URL: http://svn.apache.org/r1662799
Log:
JS2-1316: restful services for new profiler admin

Added:
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileCriterionBean.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileDataTableBean.java
      - copied, changed from r1653148, portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UserDataTableBean.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileEditBean.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileListBean.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UpdateResultBean.java
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/ProfilerManagementService.java
      - copied, changed from r1653148, portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/UserManagerService.java
Modified:
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/pom.xml
    portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/util/PathSegmentUtils.java
    portals/jetspeed-2/portal/trunk/jetspeed-archetype/src/main/resources/archetype-resources/jetspeed-mvn-settings.xml
    portals/jetspeed-2/portal/trunk/jetspeed-installer/BUILD.txt
    portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-restful-services.xml
    portals/jetspeed-2/portal/trunk/pom.xml

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/pom.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/pom.xml?rev=1662799&r1=1662798&r2=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/pom.xml (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/pom.xml Fri Feb 27 19:02:51 2015
@@ -185,12 +185,18 @@
     <dependency>
       <groupId>org.codehaus.jackson</groupId>
       <artifactId>jackson-jaxrs</artifactId>
-      <scope>runtime</scope>
     </dependency>
     <dependency>
       <groupId>org.codehaus.jackson</groupId>
       <artifactId>jackson-xc</artifactId>
-      <scope>runtime</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.codehaus.jackson</groupId>
+      <artifactId>jackson-mapper-asl</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.codehaus.jackson</groupId>
+      <artifactId>jackson-core-asl</artifactId>
     </dependency>
     <dependency>
       <groupId>org.openid4java</groupId>

Added: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileCriterionBean.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileCriterionBean.java?rev=1662799&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileCriterionBean.java (added)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileCriterionBean.java Fri Feb 27 19:02:51 2015
@@ -0,0 +1,75 @@
+/*
+ * 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.jetspeed.services.beans;
+
+public class ProfileCriterionBean {
+    private String name;
+    private String value;
+    private String resolverType;
+    private int fallback;
+    private int order;
+
+    public ProfileCriterionBean() {}
+
+    public ProfileCriterionBean(String name, String value, String resolverType, int fallback, int order) {
+        this.name = name;
+        this.value = value;
+        this.resolverType = resolverType;
+        this.fallback = fallback;
+        this.order = order;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getValue() {
+        return value;
+    }
+
+    public void setValue(String value) {
+        this.value = value;
+    }
+
+    public String getResolverType() {
+        return resolverType;
+    }
+
+    public void setResolverType(String resolverType) {
+        this.resolverType = resolverType;
+    }
+
+    public int getFallback() {
+        return fallback;
+    }
+
+    public void setFallback(int fallback) {
+        this.fallback = fallback;
+    }
+
+    public int getOrder() {
+        return order;
+    }
+
+    public void setOrder(int order) {
+        this.order = order;
+    }
+}

Copied: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileDataTableBean.java (from r1653148, portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UserDataTableBean.java)
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileDataTableBean.java?p2=portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileDataTableBean.java&p1=portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UserDataTableBean.java&r1=1653148&r2=1662799&rev=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UserDataTableBean.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileDataTableBean.java Fri Feb 27 19:02:51 2015
@@ -16,25 +16,23 @@
  */
 package org.apache.jetspeed.services.beans;
 
+import org.apache.jetspeed.profiler.rules.ProfilingRule;
+
+import javax.xml.bind.annotation.XmlRootElement;
 import java.io.Serializable;
 import java.util.ArrayList;
-import java.util.HashMap;
+import java.util.Collection;
 import java.util.List;
 
-import javax.xml.bind.annotation.XmlRootElement;
-
-import org.apache.jetspeed.security.JetspeedPrincipal;
-import org.apache.jetspeed.security.JetspeedPrincipalResultList;
-
 /**
  * DTO for user search result list to be displayed in the view. The object will
  * be transformed to JSON to be transfered to the JS client.
  * 
- * @author <a href="mailto:joachim@wemove.com">Joachim Mueller</a>
+ * @author <a href="mailto:david@bluesunrise.com">David S Taylor</a>
  * 
  */
 @XmlRootElement(name = "data")
-public class UserDataTableBean implements Serializable {
+public class ProfileDataTableBean implements Serializable {
 
 	private static final long serialVersionUID = 1L;
 
@@ -44,22 +42,16 @@ public class UserDataTableBean implement
 	private String sort = "userName";
 	private String dir = "asc";
 	private long pageSize = 5;
-	private List<HashMap<String, String>> records = null;
+	//private List<HashMap<String, String>> records = null;
+	private List<ProfileListBean> records = new ArrayList<>();
 
-	public UserDataTableBean() {
+	public ProfileDataTableBean() {
 	}
 
-	public UserDataTableBean(JetspeedPrincipalResultList resultList) {
-		totalRecords = resultList.getTotalSize();
-		this.records = new ArrayList<HashMap<String, String>>();
-		HashMap<String, String> record = null;
-		for (JetspeedPrincipal p : resultList.getResults()) {
-			record = new HashMap<String, String>();
-			record.put("userName", p.getName());
-			record.put("firstName", p.getInfoMap().get("user.name.given") == null ? "" : p.getInfoMap().get(
-					"user.name.given"));
-			record.put("lastName", p.getInfoMap().get("user.name.family") == null ? "" : p.getInfoMap().get(
-					"user.name.family"));
+	public ProfileDataTableBean(Collection<ProfilingRule> rules) {
+		totalRecords = rules.size();
+		for (ProfilingRule rule : rules) {
+			ProfileListBean record = new ProfileListBean(rule.getId(), rule.getTitle(), rule.getClassname());
 			this.records.add(record);
 		}
 	}
@@ -157,7 +149,7 @@ public class UserDataTableBean implement
 	/**
 	 * @return the records
 	 */
-	public List<HashMap<String, String>> getRecords() {
+	public List<ProfileListBean> getRecords() {
 		return records;
 	}
 
@@ -165,7 +157,7 @@ public class UserDataTableBean implement
 	 * @param records
 	 *            the records to set
 	 */
-	public void setRecords(List<HashMap<String, String>> records) {
+	public void setRecords(List<ProfileListBean> records) {
 		this.records = records;
 	}
 

Added: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileEditBean.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileEditBean.java?rev=1662799&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileEditBean.java (added)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileEditBean.java Fri Feb 27 19:02:51 2015
@@ -0,0 +1,51 @@
+/*
+ * 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.jetspeed.services.beans;
+
+import javax.xml.bind.annotation.XmlRootElement;
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * DTO for profile search result list to be displayed in the view. The object will
+ * be transformed to JSON to be transferred to the JS client.
+ *
+ */
+@XmlRootElement(name = "profile")
+public class ProfileEditBean extends ProfileListBean implements Serializable {
+
+    private List<ProfileCriterionBean> criteria = new ArrayList<>();
+
+    public ProfileEditBean() {}
+
+    public ProfileEditBean(String id, String title, String concreteClass) {
+        super(id, title, concreteClass);
+    }
+
+    public void add(ProfileCriterionBean bean) {
+        criteria.add(bean);
+    }
+
+    public List<ProfileCriterionBean> getCriteria() {
+        return criteria;
+    }
+
+    public void setCriteria(List<ProfileCriterionBean> criteria) {
+        this.criteria = criteria;
+    }
+}

Added: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileListBean.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileListBean.java?rev=1662799&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileListBean.java (added)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/ProfileListBean.java Fri Feb 27 19:02:51 2015
@@ -0,0 +1,64 @@
+/*
+ * 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.jetspeed.services.beans;
+
+import javax.xml.bind.annotation.XmlRootElement;
+import java.io.Serializable;
+
+/**
+ * DTO for profile search result list to be displayed in the view. The object will
+ * be transformed to JSON to be transferred to the JS client.
+ *
+ */
+@XmlRootElement(name = "profile")
+public class ProfileListBean implements Serializable {
+    protected String id;
+    protected String title;
+    protected String concreteClass;
+
+    public ProfileListBean() {}
+
+    public ProfileListBean(String id, String title, String concreteClass) {
+        this.id = id;
+        this.title = title;
+        this.concreteClass = concreteClass;
+    }
+
+    public String getId() {
+        return id;
+    }
+
+    public void setId(String id) {
+        this.id = id;
+    }
+
+    public String getTitle() {
+        return title;
+    }
+
+    public void setTitle(String title) {
+        this.title = title;
+    }
+
+    public String getConcreteClass() {
+        return concreteClass;
+    }
+
+    public void setConcreteClass(String concreteClass) {
+        this.concreteClass = concreteClass;
+    }
+}

Added: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UpdateResultBean.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UpdateResultBean.java?rev=1662799&view=auto
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UpdateResultBean.java (added)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/beans/UpdateResultBean.java Fri Feb 27 19:02:51 2015
@@ -0,0 +1,28 @@
+package org.apache.jetspeed.services.beans;
+
+public class UpdateResultBean {
+
+    private int status;
+    private String message;
+
+    public UpdateResultBean(int status, String message) {
+        this.status = status;
+        this.message = message;
+    }
+
+    public int getStatus() {
+        return status;
+    }
+
+    public void setStatus(int status) {
+        this.status = status;
+    }
+
+    public String getMessage() {
+        return message;
+    }
+
+    public void setMessage(String message) {
+        this.message = message;
+    }
+}

Copied: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/ProfilerManagementService.java (from r1653148, portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/UserManagerService.java)
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/ProfilerManagementService.java?p2=portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/ProfilerManagementService.java&p1=portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/UserManagerService.java&r1=1653148&r2=1662799&rev=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/UserManagerService.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/ProfilerManagementService.java Fri Feb 27 19:02:51 2015
@@ -16,49 +16,40 @@
  */
 package org.apache.jetspeed.services.rest;
 
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import org.apache.commons.lang.StringUtils;
+import org.apache.jetspeed.JetspeedActions;
+import org.apache.jetspeed.exception.JetspeedException;
+import org.apache.jetspeed.layout.PortletActionSecurityBehavior;
+import org.apache.jetspeed.profiler.Profiler;
+import org.apache.jetspeed.profiler.rules.ProfilingRule;
+import org.apache.jetspeed.profiler.rules.RuleCriterion;
+import org.apache.jetspeed.request.RequestContext;
+import org.apache.jetspeed.services.beans.ProfileCriterionBean;
+import org.apache.jetspeed.services.beans.ProfileDataTableBean;
+import org.apache.jetspeed.services.beans.ProfileEditBean;
+import org.apache.jetspeed.services.beans.UpdateResultBean;
+import org.codehaus.jackson.map.ObjectMapper;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 
 import javax.servlet.http.HttpServletRequest;
+import javax.ws.rs.Consumes;
 import javax.ws.rs.DELETE;
-import javax.ws.rs.FormParam;
 import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
-import javax.ws.rs.QueryParam;
+import javax.ws.rs.Produces;
 import javax.ws.rs.WebApplicationException;
 import javax.ws.rs.core.Context;
+import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 import javax.ws.rs.core.UriInfo;
-import javax.ws.rs.core.Response.ResponseBuilder;
-import javax.ws.rs.core.Response.Status;
-
-import org.apache.jetspeed.Jetspeed;
-import org.apache.jetspeed.JetspeedActions;
-import org.apache.jetspeed.administration.PortalConfigurationConstants;
-import org.apache.jetspeed.exception.JetspeedException;
-import org.apache.jetspeed.layout.PortletActionSecurityBehavior;
-import org.apache.jetspeed.om.folder.Folder;
-import org.apache.jetspeed.page.PageManager;
-import org.apache.jetspeed.profiler.Profiler;
-import org.apache.jetspeed.profiler.rules.ProfilingRule;
-import org.apache.jetspeed.request.RequestContext;
-import org.apache.jetspeed.security.Group;
-import org.apache.jetspeed.security.GroupManager;
-import org.apache.jetspeed.security.JetspeedPrincipalQueryContext;
-import org.apache.jetspeed.security.PasswordCredential;
-import org.apache.jetspeed.security.Role;
-import org.apache.jetspeed.security.RoleManager;
-import org.apache.jetspeed.security.SecurityException;
-import org.apache.jetspeed.security.User;
-import org.apache.jetspeed.security.UserManager;
-import org.apache.jetspeed.security.UserResultList;
-import org.apache.jetspeed.services.beans.UserDataTableBean;
-import org.apache.jetspeed.services.beans.UserDetailBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
 
 /**
  * UserManagerService. This REST service provides access to the jetspeed user manager. The access of all methods are restricted to the users with the 'admin'
@@ -66,27 +57,19 @@ import org.slf4j.LoggerFactory;
  * 
  * @version $Id$
  */
-@Path("/usermanager/")
-public class UserManagerService
+@Path("/profiler/")
+public class ProfilerManagementService
 {
-    
-    private static Logger log = LoggerFactory.getLogger(UserManagerService.class);
-    
-    private UserManager userManager;
-    private RoleManager roleManager;
-    private GroupManager groupManager;
+
+    private static Logger log = LoggerFactory.getLogger(ProfilerManagementService.class);
+
     private Profiler profiler;
-    private PageManager pageManager;
     private PortletActionSecurityBehavior securityBehavior;
 
-    public UserManagerService(UserManager userManager, RoleManager roleManager, GroupManager groupManager, Profiler profiler, PageManager pageManager,
-                              PortletActionSecurityBehavior securityBehavior)
+    public ProfilerManagementService(Profiler profiler,
+                                     PortletActionSecurityBehavior securityBehavior)
     {
-        this.userManager = userManager;
-        this.roleManager = roleManager;
-        this.groupManager = groupManager;
         this.profiler = profiler;
-        this.pageManager = pageManager;
         this.securityBehavior = securityBehavior;
     }
 
@@ -95,408 +78,153 @@ public class UserManagerService
      * 
      * @param servletRequest
      * @param uriInfo
-     * @param userName
-     * @param roles
-     * @param groups
-     * @param startIndex
-     * @param results
-     * @param sortDirection
-     * @param attributeKeys
-     * @param attributeValues
      * @return
      */
     @GET
-    @Path("/users/")
-    public UserDataTableBean findUsers(@Context HttpServletRequest servletRequest, @Context UriInfo uriInfo, @QueryParam("name") String userName,
-                                       @QueryParam("roles") List<String> roles, @QueryParam("groups") List<String> groups,
-                                       @QueryParam("start") long startIndex, @QueryParam("results") long results, @QueryParam("sort") String sortDirection,
-                                       @QueryParam("attribute_key") List<String> attributeKeys, @QueryParam("attribute_value") List<String> attributeValues)
+    @Path("/list")
+    public ProfileDataTableBean listProfiles(@Context HttpServletRequest servletRequest, @Context UriInfo uriInfo)
     {
         checkPrivilege(servletRequest, JetspeedActions.VIEW);
         
-        Map<String, String> attributeMap = null;
-        
-        if (attributeKeys != null && attributeKeys.size() > 0 && attributeKeys.size() == attributeValues.size())
-        {
-            attributeMap = new HashMap<String, String>();
-            
-            for (int i = 0; i < attributeKeys.size(); i++)
-            {
-                if (attributeValues.get(i) != null && attributeValues.get(i).length() > 0)
-                {
-                    attributeMap.put(attributeKeys.get(i), attributeValues.get(i));
-                }
-            }
-        }
-        
-        JetspeedPrincipalQueryContext ctx = new JetspeedPrincipalQueryContext(userName, startIndex, results, sortDirection, roles, groups, null, attributeMap);
-        
-        try
-        {
-            UserResultList resultList = userManager.getUsersExtended(ctx);
-            UserDataTableBean result = new UserDataTableBean(resultList);
-            result.setStartIndex(startIndex);
-            result.setPageSize(results);
-            result.setRecordsReturned(results);
-            
-            return result;
-        }
-        catch (SecurityException e)
-        {
-            if (log.isDebugEnabled())
-            {
-                log.error("Error searching users:" + ctx, e);
-            }
-            else
-            {
-                log.error("Error searching users:" + ctx + ". " + e);
-            }
-        }
-        
-        return null;
+        Collection<ProfilingRule> rules = profiler.getRules();
+        return new ProfileDataTableBean(rules);
     }
 
-    /**
-     * Get users detail data, according to the users name. This method just gets all data that will be displayed in the view.
-     * 
-     * @param servletRequest
-     * @param uriInfo
-     * @param userName
-     * @return
-     */
     @GET
-    @Path("/users/{name}/")
-    public UserDetailBean getUserByName(@Context HttpServletRequest servletRequest, @Context UriInfo uriInfo, @PathParam("name") String userName)
-    {
-        checkPrivilege(servletRequest, JetspeedActions.VIEW);
-        
-        try
-        {
-            User user = userManager.getUser(userName);
-            PasswordCredential credential = userManager.getPasswordCredential(user);
-            List<Role> roles = roleManager.getRolesForUser(user.getName());
-            List<String> availableRoles = roleManager.getRoleNames(null);
-            List<Group> groups = groupManager.getGroupsForUser(user.getName());
-            List<String> availableGroups = groupManager.getGroupNames(null);
-            
-            return new UserDetailBean(user, credential, roles, groups, availableRoles, availableGroups);
+    @Path("/edit/{id}/")
+    public ProfileEditBean lookupProfile(@Context HttpServletRequest servletRequest,
+                                                  @Context UriInfo uriInfo,
+                                                  @PathParam("id") String profileId) {
+        if (StringUtils.isBlank(profileId)) {
+            throw new WebApplicationException(new IllegalArgumentException("Profile id not specified"));
+        }
+        ProfilingRule rule = profiler.getRule(profileId);
+        if (rule == null) {
+            throw new WebApplicationException(new IllegalArgumentException("Profile id not found with the specified id: " + profileId));
+        }
+        ProfileEditBean editBean = new ProfileEditBean(rule.getId(), rule.getTitle(), rule.getClassname());
+        for (RuleCriterion criterion : rule.getRuleCriteria()) {
+            editBean.add(new ProfileCriterionBean(criterion.getName(), criterion.getValue(),
+                               criterion.getType(), criterion.getFallbackType(), criterion.getFallbackOrder()));
         }
-        catch (Exception e)
-        {
-            if (log.isDebugEnabled())
-            {
-                log.debug("Error requesting users datail data:" + userName, e);
-            }
-        }
-        
-        return null;
+        return editBean;
     }
 
-    /**
-     * Update user data.
-     * 
-     * @param servletRequest
-     * @param uriInfo
-     * @param userName
-     * @return
-     */
     @POST
-    @Path("/users/{name}/")
-    public Boolean updateUserDetail(@Context HttpServletRequest servletRequest, @Context UriInfo uriInfo, @PathParam("name") String userName,
-                                    @FormParam("user_name_given") String userNameGiven, @FormParam("user_name_family") String userNameFamily,
-                                    @FormParam("user_email") String userEmail, @FormParam("password") String password,
-                                    @FormParam("password_confirm") String passwordConfirm, @FormParam("user_enabled") Boolean userEnabled,
-                                    @FormParam("credential_update_required") Boolean credentialUpdateRequired, @FormParam("roles") List<String> roles,
-                                    @FormParam("groups") List<String> groups)
-    {
-        checkPrivilege(servletRequest, JetspeedActions.VIEW);
-        
-        try
-        {
-            boolean changePassword = false;
-            
-            if (password != null && password.length() > 0)
-            {
-                if (!password.equals(passwordConfirm))
-                {
-                    ResponseBuilder builder = Response.status(Status.BAD_REQUEST);
-                    builder.type("text/plain");
-                    builder.entity("password.confirmation.failed");
-                    throw new WebApplicationException(builder.build());
-                }
-                
-                changePassword = true;
-            }
-            
-            User user = userManager.getUser(userName);
-            user.getSecurityAttributes().getAttribute("user.name.given", true).setStringValue(userNameGiven);
-            user.getSecurityAttributes().getAttribute("user.name.family", true).setStringValue(userNameFamily);
-            user.getSecurityAttributes().getAttribute("user.email", true).setStringValue(userEmail);
-            
-            if (userEnabled == null)
-            {
-                userEnabled = false;
-            }
-            
-            user.setEnabled(userEnabled);
-            
-            userManager.updateUser(user);
-            
-            if (credentialUpdateRequired == null)
-            {
-                credentialUpdateRequired = false;
-            }
-            
-            PasswordCredential credential = userManager.getPasswordCredential(user);
-            
-            if (changePassword)
-            {
-                credential.setPassword(password, false);
-            }
-            
-            credential.setUpdateRequired(credentialUpdateRequired);
-            
-            userManager.storePasswordCredential(credential);
-            
-            // merge roles
-            List<Role> currentRoles = roleManager.getRolesForUser(user.getName());
-            for (Role currentRole : currentRoles)
-            {
-                if (roles != null && roles.contains(currentRole.getName()))
-                {
-                    roles.remove(currentRole.getName());
-                }
-                else
-                {
-                    roleManager.removeRoleFromUser(userName, currentRole.getName());
-                }
-            }
-            
-            if (roles != null)
-            {
-                for (String roleName : roles)
-                {
-                    roleManager.addRoleToUser(userName, roleName);
-                }
-            }
-            
-            // merge groups
-            List<Group> currentGroups = groupManager.getGroupsForUser(user.getName());
-            
-            for (Group currentGroup : currentGroups)
-            {
-                if (groups != null && groups.contains(currentGroup.getName()))
-                {
-                    groups.remove(currentGroup.getName());
-                }
-                else
-                {
-                    groupManager.removeUserFromGroup(userName, currentGroup.getName());
-                }
-            }
-            
-            if (groups != null)
-            {
-                for (String groupName : groups)
-                {
-                    groupManager.addUserToGroup(userName, groupName);
-                }
-            }
-            
-            return new Boolean(true);
-        }
-        catch (WebApplicationException e)
-        {
-            // re-throw exception
-            throw e;
-        }
-        catch (SecurityException e)
-        {
-            ResponseBuilder builder = Response.status(Status.BAD_REQUEST);
-            builder.type("text/plain");
-            builder.entity(e.getKeyedMessage().getKey());
-            
-            throw new WebApplicationException(builder.build());
+    @Consumes({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
+    @Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
+    @Path("/update")
+    public UpdateResultBean addOrUpdateProfile(String json) {
+        ObjectMapper writeMapper = new ObjectMapper();
+        ProfileEditBean dtoProfile = null;
+        try {
+            dtoProfile = writeMapper.readValue(json, ProfileEditBean.class);
+        }
+        catch (Exception e) {
+            e.printStackTrace();
+            throw new WebApplicationException(new IllegalArgumentException("Bad input on profile data"));
+        }
+        if (StringUtils.isBlank(dtoProfile.getId())) {
+            throw new WebApplicationException(new IllegalArgumentException("Profile id not specified"));
+        }
+        if (StringUtils.isBlank(dtoProfile.getConcreteClass())) {
+            throw new WebApplicationException(new IllegalArgumentException("Concrete Class not specified"));
+        }
+        try {
+            boolean isAdd = false;
+            ProfilingRule rule = profiler.getRule(dtoProfile.getId());
+            if (rule == null) {
+                rule = profiler.createProfilingRule(dtoProfile.getConcreteClass().indexOf("StandardProfilingRule") > -1);
+                rule.setId(dtoProfile.getId());
+                isAdd = true;
+            }
+            rule.setId(dtoProfile.getId());
+            rule.setClassname(dtoProfile.getConcreteClass());
+            rule.setTitle(dtoProfile.getTitle());
+
+            // process criteria deletes
+            if (!isAdd) {
+                Map<String, ProfileCriterionBean> beanMap = new HashMap<>();
+                for (ProfileCriterionBean pcb : dtoProfile.getCriteria()) {
+                    beanMap.put(pcb.getName(), pcb);
+                }
+                List<RuleCriterion> deletes = new ArrayList<>();
+                for (RuleCriterion rc : rule.getRuleCriteria()) {
+                    if (beanMap.get(rc.getName()) == null) {
+                        deletes.add(rc);
+                    }
+                }
+                for (RuleCriterion rc : deletes) {
+                    rule.getRuleCriteria().remove(rc);
+                }
+            }
+
+            // process criteria adds and updates
+            Map<String, RuleCriterion> rulesMap = new HashMap<>();
+            for (RuleCriterion rc : rule.getRuleCriteria()) {
+                rulesMap.put(rc.getName(), rc);
+            }
+            for (ProfileCriterionBean dto : dtoProfile.getCriteria()) {
+                RuleCriterion rc = rulesMap.get(dto.getName());
+                if (rc == null) {
+                    rc = profiler.createRuleCriterion();
+                    rc.setName(dto.getName());
+                    rc.setValue(dto.getValue());
+                    rc.setType(dto.getResolverType());
+                    rc.setFallbackType(dto.getFallback());
+                    rc.setFallbackOrder(dto.getOrder());
+                    rc.setRuleId(rule.getId());
+                    rule.getRuleCriteria().add(rc);
+                }
+                else {
+                    rc.setValue(dto.getValue());
+                    rc.setType(dto.getResolverType());
+                    rc.setFallbackType(dto.getFallback());
+                    rc.setFallbackOrder(dto.getOrder());
+                    rc.setRuleId(rule.getId());
+                }
+            }
+
+            profiler.storeProfilingRule(rule);
+            return new UpdateResultBean(200, "OK");
+        }
+        catch (Exception e) {
+            log.error("failed to update profile for " + dtoProfile.getId(), e);
+            return new UpdateResultBean(500, e.getMessage());
         }
-        catch (Exception e)
-        {
-            // handle other exceptions
-            if (log.isErrorEnabled())
-            {
-                log.error("Error updating users :" + userName, e);
-            }
-            
-            throw new WebApplicationException(e);
-        }
-    }
 
-    /**
-     * <p> Create user data. </p> <p> It uses the property "registration.roles.default" from jetspeed.properties as default roles for new created users. </p>
-     * <p> It uses the property "registration.rules.default" from jetspeed.properties as default profiling rules for new created users. The locator name is
-     * always "default". </p> <p> It uses the property "psml.template.folder" from jetspeed.properties as PSML template folder to create new users. </p>
-     * 
-     * @param servletRequest
-     * @param uriInfo
-     * @param userName
-     * @param userNameGiven
-     * @param userNameFamily
-     * @param userEmail
-     * @param password
-     * @param passwordConfirm
-     * @param credentialUpdateRequired
-     * @return
-     */
-    @POST
-    @Path("/users/")
-    public Boolean createUser(@Context HttpServletRequest servletRequest, @Context UriInfo uriInfo, @FormParam("name") String userName,
-                              @FormParam("user_name_given") String userNameGiven, @FormParam("user_name_family") String userNameFamily,
-                              @FormParam("user_email") String userEmail, @FormParam("password") String password,
-                              @FormParam("password_confirm") String passwordConfirm, @FormParam("credential_update_required") Boolean credentialUpdateRequired)
-    {
-        checkPrivilege(servletRequest, JetspeedActions.VIEW);
-        
-        try
-        {
-            boolean changePassword = false;
-            
-            if (password != null && password.length() > 0)
-            {
-                if (!password.equals(passwordConfirm))
-                {
-                    ResponseBuilder builder = Response.status(Status.BAD_REQUEST);
-                    builder.type("text/plain");
-                    builder.entity("password.confirmation.failed");
-                    throw new WebApplicationException(builder.build());
-                }
-                
-                changePassword = true;
-            }
-            
-            User user = userManager.addUser(userName);
-            
-            user.getSecurityAttributes().getAttribute("user.name.given", true).setStringValue(userNameGiven);
-            user.getSecurityAttributes().getAttribute("user.name.family", true).setStringValue(userNameFamily);
-            user.getSecurityAttributes().getAttribute("user.email", true).setStringValue(userEmail);
-            
-            userManager.updateUser(user);
-            
-            if (credentialUpdateRequired == null)
-            {
-                credentialUpdateRequired = false;
-            }
-            
-            PasswordCredential credential = userManager.getPasswordCredential(user);
-            
-            if (changePassword)
-            {
-                credential.setPassword(password, false);
-            }
-            
-            credential.setUpdateRequired(credentialUpdateRequired);
-            userManager.storePasswordCredential(credential);
-            
-            // add default user roles
-            String[] defaultUserRoles = Jetspeed.getConfiguration().getStringArray(PortalConfigurationConstants.REGISTRATION_ROLES_DEFAULT);
-            
-            for (String defaultUserRole : defaultUserRoles)
-            {
-                roleManager.addRoleToUser(userName, defaultUserRole);
-            }
-            
-            // add default user profiling rules
-            String[] defaultUserProfilingRules = Jetspeed.getConfiguration().getStringArray(PortalConfigurationConstants.REGISTRATION_ROLES_DEFAULT);
-            
-            for (String defaultUserProfilingRule : defaultUserProfilingRules)
-            {
-                ProfilingRule profilingRule = profiler.getRule(defaultUserProfilingRule);
-                
-                if (profilingRule != null)
-                {
-                    profiler.setRuleForPrincipal(user, profilingRule, "default");
-                }
-                else
-                {
-                    log.error("Failed to set profiling rule for principal. Invalid profiling rule: " + defaultUserProfilingRule);
-                }
-            }
-            
-            // copy the entire directory tree from the template folder
-            String templateFolder = Jetspeed.getConfiguration().getString(PortalConfigurationConstants.PSML_TEMPLATE_FOLDER);
-            
-            if (!(templateFolder == null || templateFolder.trim().length() == 0))
-            {
-                Folder source = pageManager.getFolder(templateFolder);
-                pageManager.deepCopyFolder(source, Folder.USER_FOLDER + userName, userName);
-            }
-            
-            return new Boolean(true);
-        }
-        catch (WebApplicationException e)
-        {
-            // re-throw exception
-            throw e;
-        }
-        catch (SecurityException e)
-        {
-            ResponseBuilder builder = Response.status(Status.BAD_REQUEST);
-            builder.type("text/plain");
-            builder.entity(e.getKeyedMessage().getKey());
-            
-            throw new WebApplicationException(builder.build());
-        }
-        catch (Exception e)
-        {
-            // handle other exceptions
-            if (log.isErrorEnabled())
-            {
-                log.error("Error creating users :" + userName, e);
-            }
-            
-            throw new WebApplicationException(e);
-        }
     }
 
-    /**
-     * Get users detail data, according to the users name. This method just gets all data that will be displayed in the view.
-     * 
-     * @param servletRequest
-     * @param uriInfo
-     * @param userName
-     * @return
-     */
     @DELETE
-    @Path("/users/{name}/")
-    public Boolean deleteUserByName(@Context HttpServletRequest servletRequest, @Context UriInfo uriInfo, @PathParam("name") String userName)
-    {
-        checkPrivilege(servletRequest, JetspeedActions.VIEW);
-        
-        try
-        {
-            userManager.removeUser(userName);
-            return true;
+    @Produces({MediaType.APPLICATION_XML, MediaType.APPLICATION_JSON})
+    public UpdateResultBean deleteProfiles(List<String> profileIds) {
+        if (log.isDebugEnabled()) {
+            log.debug(String.format("processing DELETE on /profiler for %s", profileIds));
         }
-        catch (SecurityException e)
-        {
-            ResponseBuilder builder = Response.status(Status.BAD_REQUEST);
-            builder.type("text/plain");
-            builder.entity(e.getKeyedMessage().getKey());
-            throw new WebApplicationException(builder.build());
+
+        if (profileIds == null || profileIds.size() == 0) {
+            throw new WebApplicationException(new IllegalArgumentException("Profile ids to delete not specified"));
         }
-        catch (Exception e)
-        {
-            // handle other exceptions
-            if (log.isErrorEnabled())
-            {
-                log.error("Error creating users :" + userName, e);
+
+        try {
+            //profileIds = PathSegmentUtils.parseNames(profileIdsString);
+            for (String id : profileIds) {
+                ProfilingRule rule = profiler.getRule(id);
+                if (rule != null) {
+                    profiler.deleteProfilingRule(rule);
+                }
             }
-            throw new WebApplicationException(e);
+            return new UpdateResultBean(200, "OK");
+        } catch (Exception e) {
+            String message = String.format("Error converting profiler ids [%s]", profileIds);
+            log.debug(message);
+            throw new WebApplicationException(Response.status(Response.Status.BAD_REQUEST).entity(message).build());
         }
     }
 
     protected void checkPrivilege(HttpServletRequest servletRequest, String action)
     {
         RequestContext requestContext = (RequestContext) servletRequest.getAttribute(RequestContext.REQUEST_PORTALENV);
-        
         if (securityBehavior != null && !securityBehavior.checkAccess(requestContext, action))
         {
             throw new WebApplicationException(new JetspeedException("Insufficient privilege to access this REST service."));

Modified: portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/util/PathSegmentUtils.java
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/util/PathSegmentUtils.java?rev=1662799&r1=1662798&r2=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/util/PathSegmentUtils.java (original)
+++ portals/jetspeed-2/portal/trunk/components/jetspeed-portal/src/main/java/org/apache/jetspeed/services/rest/util/PathSegmentUtils.java Fri Feb 27 19:02:51 2015
@@ -16,9 +16,9 @@
  */
 package org.apache.jetspeed.services.rest.util;
 
-import java.util.List;
-
 import javax.ws.rs.core.PathSegment;
+import java.util.ArrayList;
+import java.util.List;
 
 /**
  * PathSegmentUtils
@@ -85,5 +85,45 @@ public class PathSegmentUtils
         
         return sbPath.toString();
     }
+
+    public static List<String> parseNames(String commaSeparated) {
+        String names[] = commaSeparated.split(",");
+        List<String> ids = new ArrayList<String>(names.length);
+        for (String name : names) {
+            ids.add(name.trim());
+        }
+        return ids;
+    }
+
+    public static String[] parseNamesArray(String commaSeparated) {
+        String names[] = commaSeparated.split(",");
+        int index = 0;
+        for (String name : names) {
+            names[index] = name.trim();
+            index++;
+        }
+        return names;
+    }
+
+    public static List<Integer> parseIds(String commaSeparated) throws NumberFormatException {
+        String stringIds[] = commaSeparated.split(",");
+        List<Integer> ids = new ArrayList<Integer>(stringIds.length);
+        for (String stringId : stringIds) {
+            ids.add(new Integer(stringId.trim()));
+        }
+        return ids;
+    }
+
+    public static Integer[] parseIdArray(String commaSeparated) throws NumberFormatException {
+        String stringIds[] = commaSeparated.split(",");
+        Integer ids[] = new Integer[stringIds.length];
+        int ix = 0;
+        for (String id : stringIds) {
+            ids[ix] = new Integer(id.trim());
+            ix++;
+        }
+        return ids;
+    }
+
     
 }

Modified: portals/jetspeed-2/portal/trunk/jetspeed-archetype/src/main/resources/archetype-resources/jetspeed-mvn-settings.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-archetype/src/main/resources/archetype-resources/jetspeed-mvn-settings.xml?rev=1662799&r1=1662798&r2=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-archetype/src/main/resources/archetype-resources/jetspeed-mvn-settings.xml (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-archetype/src/main/resources/archetype-resources/jetspeed-mvn-settings.xml Fri Feb 27 19:02:51 2015
@@ -55,8 +55,8 @@
       </activation>
       <properties>
         
-        <org.apache.jetspeed.server.home>/change/this/apache-tomcat-6.0.33/</org.apache.jetspeed.server.home>
-        <org.apache.jetspeed.catalina.version.major>6</org.apache.jetspeed.catalina.version.major>
+        <org.apache.jetspeed.server.home>/change/this/apache-tomcat-7.0.59/</org.apache.jetspeed.server.home>
+        <org.apache.jetspeed.catalina.version.major>7</org.apache.jetspeed.catalina.version.major>
         
         <!--
           <org.apache.jetspeed.production.database.default.name>mysql</org.apache.jetspeed.production.database.default.name>

Modified: portals/jetspeed-2/portal/trunk/jetspeed-installer/BUILD.txt
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-installer/BUILD.txt?rev=1662799&r1=1662798&r2=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-installer/BUILD.txt (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-installer/BUILD.txt Fri Feb 27 19:02:51 2015
@@ -16,6 +16,7 @@
 To build either of the installer, the Jetspeed Maven plugin for Maven-2 
 should be used as follows:
 
+> cd jetspeed-installer
 > mvn jetspeed:mvn -Dtarget=installer
 
 The self executing installer can be found in the maven target directory

Modified: portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-restful-services.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-restful-services.xml?rev=1662799&r1=1662798&r2=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-restful-services.xml (original)
+++ portals/jetspeed-2/portal/trunk/jetspeed-portal-resources/src/main/resources/assembly/jetspeed-restful-services.xml Fri Feb 27 19:02:51 2015
@@ -127,6 +127,10 @@
           <meta key="j2:cat" value="default" />
           <constructor-arg ref="jaxrsUserManagerService" />
         </bean>
+        <bean class="org.apache.cxf.jaxrs.lifecycle.SingletonResourceProvider">
+            <meta key="j2:cat" value="default" />
+            <constructor-arg ref="jaxrsProfilerManagementService"/>
+        </bean>
       </list>
     </property>
   </bean>
@@ -163,5 +167,12 @@
     <meta key="j2:cat" value="default" />
     <constructor-arg ref="org.apache.jetspeed.page.PageManager" />
   </bean>
-  
+
+  <!-- Profiler JAX-RS Service -->
+  <bean id="jaxrsProfilerManagementService" class="org.apache.jetspeed.services.rest.ProfilerManagementService">
+    <meta key="j2:cat" value="default" />
+    <constructor-arg ref="org.apache.jetspeed.profiler.Profiler" />
+    <constructor-arg ref="RolesSecurityBehavior" />
+  </bean>
+
 </beans>

Modified: portals/jetspeed-2/portal/trunk/pom.xml
URL: http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/pom.xml?rev=1662799&r1=1662798&r2=1662799&view=diff
==============================================================================
--- portals/jetspeed-2/portal/trunk/pom.xml (original)
+++ portals/jetspeed-2/portal/trunk/pom.xml Fri Feb 27 19:02:51 2015
@@ -1090,17 +1090,24 @@
         <groupId>org.codehaus.jackson</groupId>
         <artifactId>jackson-jaxrs</artifactId>
         <version>${jackson.version}</version>
-        <scope>runtime</scope>
       </dependency>
-      
-      <!-- Jacson Xml Compatibility extensions -->
+      <!-- Jackson Xml Compatibility extensions -->
       <dependency>
         <groupId>org.codehaus.jackson</groupId>
         <artifactId>jackson-xc</artifactId>
         <version>${jackson.version}</version>
-        <scope>runtime</scope>
       </dependency>
-      
+      <dependency>
+        <groupId>org.codehaus.jackson</groupId>
+        <artifactId>jackson-core-asl</artifactId>
+        <version>${jackson.version}</version>
+      </dependency>
+      <dependency>
+        <groupId>org.codehaus.jackson</groupId>
+        <artifactId>jackson-mapper-asl</artifactId>
+        <version>${jackson.version}</version>
+      </dependency>
+
       <!-- Test -->
       <dependency>
         <groupId>junit</groupId>
@@ -2150,8 +2157,10 @@
             <groupId>org.apache.rat</groupId>
             <artifactId>apache-rat-plugin</artifactId>
             <configuration>
+              <useDefaultExcludes>true</useDefaultExcludes>
               <excludes combine.children="append">
-                <exclude>jetspeed-mvn-settings.xml</exclude>                            
+                <exclude>.idea/**/*</exclude>
+                <exclude>jetspeed-mvn-settings.xml</exclude>
                 <exclude>MIT-LICENSE</exclude>                            
                 <exclude>YUI-LICENSE</exclude>                            
                 <exclude>JSCOOKMENU-LICENSE</exclude>              



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message