You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rave.apache.org by mf...@apache.org on 2013/02/27 21:47:58 UTC

svn commit: r1450952 - in /rave/trunk: rave-components/rave-core/src/main/java/org/apache/rave/portal/activities/specification/ rave-components/rave-core/src/main/java/org/apache/rave/portal/model/ rave-components/rave-jpa/src/main/java/org/apache/rave...

Author: mfranklin
Date: Wed Feb 27 20:47:57 2013
New Revision: 1450952

URL: http://svn.apache.org/r1450952
Log:
Added MongoDB ActivityStreams Converter RAVE-880

Added:
    rave/trunk/rave-components/rave-mongodb/src/main/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverter.java
    rave/trunk/rave-components/rave-mongodb/src/test/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverterTest.java
Removed:
    rave/trunk/rave-components/rave-core/src/main/java/org/apache/rave/portal/activities/specification/
Modified:
    rave/trunk/rave-components/rave-core/src/main/java/org/apache/rave/portal/model/ActivityStreamsObject.java
    rave/trunk/rave-components/rave-jpa/src/main/java/org/apache/rave/portal/model/conversion/JpaActivityStreamsMediaLinkConverter.java
    rave/trunk/rave-portal-resources/src/main/resources/db/initial-data.json
    rave/trunk/rave-portal-resources/src/main/webapp/static/script/rave_opensocial.js

Modified: rave/trunk/rave-components/rave-core/src/main/java/org/apache/rave/portal/model/ActivityStreamsObject.java
URL: http://svn.apache.org/viewvc/rave/trunk/rave-components/rave-core/src/main/java/org/apache/rave/portal/model/ActivityStreamsObject.java?rev=1450952&r1=1450951&r2=1450952&view=diff
==============================================================================
--- rave/trunk/rave-components/rave-core/src/main/java/org/apache/rave/portal/model/ActivityStreamsObject.java (original)
+++ rave/trunk/rave-components/rave-core/src/main/java/org/apache/rave/portal/model/ActivityStreamsObject.java Wed Feb 27 20:47:57 2013
@@ -25,49 +25,36 @@ import java.util.List;
 
 public interface ActivityStreamsObject extends ActivityStreamsItem {
 
-
     public List<ActivityStreamsObject> getAttachments() ;
 
     public void setAttachments(List<ActivityStreamsObject> attachments) ;
 
     public ActivityStreamsObject getAuthor() ;
 
-
     public void setAuthor(ActivityStreamsObject author) ;
 
-
     public String getContent() ;
 
-
     public void setContent(String content) ;
 
-
     public String getDisplayName() ;
 
-
     public void setDisplayName(String displayName) ;
 
-
     public List<String> getDownstreamDuplicates() ;
 
-
     public void setDownstreamDuplicates(List<String> downstreamDuplicates) ;
 
-
     public ActivityStreamsMediaLink getImage() ;
 
-
     public void setImage(ActivityStreamsMediaLink image) ;
 
-
     public String getSummary() ;
 
     public void setSummary(String summary) ;
 
-
     public List<String> getUpstreamDuplicates() ;
 
-
     public void setUpstreamDuplicates(List<String> upstreamDuplicates) ;
 
     public String getAlias() ;

Modified: rave/trunk/rave-components/rave-jpa/src/main/java/org/apache/rave/portal/model/conversion/JpaActivityStreamsMediaLinkConverter.java
URL: http://svn.apache.org/viewvc/rave/trunk/rave-components/rave-jpa/src/main/java/org/apache/rave/portal/model/conversion/JpaActivityStreamsMediaLinkConverter.java?rev=1450952&r1=1450951&r2=1450952&view=diff
==============================================================================
--- rave/trunk/rave-components/rave-jpa/src/main/java/org/apache/rave/portal/model/conversion/JpaActivityStreamsMediaLinkConverter.java (original)
+++ rave/trunk/rave-components/rave-jpa/src/main/java/org/apache/rave/portal/model/conversion/JpaActivityStreamsMediaLinkConverter.java Wed Feb 27 20:47:57 2013
@@ -70,7 +70,5 @@ public class JpaActivityStreamsMediaLink
         converted.setHeight(source.getHeight());
         converted.setWidth(source.getWidth());
         converted.setUrl(source.getUrl());
-
-
     }
 }

Added: rave/trunk/rave-components/rave-mongodb/src/main/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverter.java
URL: http://svn.apache.org/viewvc/rave/trunk/rave-components/rave-mongodb/src/main/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverter.java?rev=1450952&view=auto
==============================================================================
--- rave/trunk/rave-components/rave-mongodb/src/main/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverter.java (added)
+++ rave/trunk/rave-components/rave-mongodb/src/main/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverter.java Wed Feb 27 20:47:57 2013
@@ -0,0 +1,182 @@
+/*
+ * 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.rave.portal.model.conversion.impl;
+
+import com.google.common.collect.Lists;
+import org.apache.rave.portal.model.ActivityStreamsEntry;
+import org.apache.rave.portal.model.ActivityStreamsMediaLink;
+import org.apache.rave.portal.model.ActivityStreamsObject;
+import org.apache.rave.portal.model.conversion.HydratingModelConverter;
+import org.apache.rave.portal.model.impl.ActivityStreamsEntryImpl;
+import org.apache.rave.portal.model.impl.ActivityStreamsMediaLinkImpl;
+import org.apache.rave.portal.model.impl.ActivityStreamsObjectImpl;
+import org.springframework.stereotype.Component;
+
+import java.util.List;
+
+import static org.apache.rave.portal.model.util.MongoDbModelUtil.generateId;
+
+@Component
+public class MongoDbActivityStreamsEntryConverter implements HydratingModelConverter<ActivityStreamsEntry, ActivityStreamsEntryImpl> {
+
+    @Override
+    public void hydrate(ActivityStreamsEntryImpl dehydrated) {
+    }
+
+    @Override
+    public Class<ActivityStreamsEntry> getSourceType() {
+        return ActivityStreamsEntry.class;
+    }
+
+    @Override
+    public ActivityStreamsEntryImpl convert(ActivityStreamsEntry source) {
+        if (source != null) {
+            ActivityStreamsEntryImpl converted = new ActivityStreamsEntryImpl();
+            converted.setActor(convert(source.getActor()));
+            converted.setObject(convert(source.getObject()));
+            converted.setGenerator(convert(source.getGenerator()));
+            converted.setIcon(convert(source.getIcon()));
+            converted.setProvider(convert(source.getProvider()));
+            converted.setProvider(convert(source.getProvider()));
+            converted.setTarget(convert(source.getTarget()));
+            updateSimpleProperties(source, converted);
+
+            return converted;
+        }
+        return null;
+    }
+
+    private ActivityStreamsMediaLink convert(ActivityStreamsMediaLink source) {
+        if (source != null) {
+            ActivityStreamsMediaLink converted = new ActivityStreamsMediaLinkImpl();
+            converted.setId(source.getId() == null ? generateId() : source.getId());
+            converted.setDuration(source.getDuration());
+            converted.setHeight(source.getHeight());
+            converted.setWidth(source.getWidth());
+            converted.setUrl(source.getUrl());
+            converted.setOpenSocial(source.getOpenSocial());
+            return converted;
+        }
+        return null;
+    }
+
+    public ActivityStreamsObject convert(ActivityStreamsObject source) {
+        if (source != null) {
+            ActivityStreamsObjectImpl converted = new ActivityStreamsObjectImpl();
+            converted.setAuthor(convert(source.getAuthor()));
+            converted.setAttachments(convert(source.getAttachments()));
+            converted.setImage(convert(source.getImage()));
+            updateSimpleProperties(source, converted);
+            return converted;
+        }
+        return null;
+    }
+
+    private List<ActivityStreamsObject> convert(List<ActivityStreamsObject> sourceObjects) {
+        if (sourceObjects != null) {
+            List<ActivityStreamsObject> converted = Lists.newArrayList();
+            for (ActivityStreamsObject source : sourceObjects) {
+                converted.add(convert(source));
+            }
+        }
+        return null;
+    }
+
+    private void updateSimpleProperties(ActivityStreamsObject source, ActivityStreamsObjectImpl converted) {
+        converted.setId(source.getId() == null ? generateId() : source.getId());
+        converted.setOpenSocial(source.getOpenSocial());
+        converted.setObjectType(source.getObjectType());
+        converted.setExtensions(source.getExtensions());
+        converted.setDisplayName(source.getDisplayName());
+        converted.setAlias(source.getAlias());
+        converted.setAttendedBy(source.getAttendedBy());
+        converted.setAttending(source.getAttending());
+        converted.setDownstreamDuplicates(source.getDownstreamDuplicates());
+        converted.setFollowers(source.getFollowers());
+        converted.setFollowing(source.getFollowing());
+        converted.setFriend_requests(source.getFriend_requests());
+        converted.setInvited(source.getInvited());
+        converted.setLikes(source.getLikes());
+        converted.setMaybeAttending(source.getMaybeAttending());
+        converted.setNotAttendedBy(source.getNotAttendedBy());
+        converted.setNotAttending(source.getNotAttending());
+        converted.setSaves(source.getSaves());
+        converted.setShares(source.getShares());
+        converted.setReviews(source.getReviews());
+        converted.setSummary(source.getSummary());
+        converted.setUrl(source.getUrl());
+        converted.setReplies(source.getReplies());
+        converted.setContent(source.getContent());
+        converted.setDc(source.getDc());
+        converted.setGeojson(source.getGeojson());
+        converted.setLd(source.getLd());
+        converted.setLinks(source.getLinks());
+        converted.setEndTime(source.getEndTime());
+        converted.setLocation(source.getLocation());
+        converted.setMood(source.getMood());
+        converted.setOdata(source.getOdata());
+        converted.setPublished(source.getPublished());
+        converted.setOpengraph(source.getOpengraph());
+        converted.setRating(source.getRating());
+        converted.setSchema_org(source.getSchema_org());
+        converted.setSource(source.getSource());
+        converted.setUpdated(source.getUpdated());
+        converted.setUrl(source.getUrl());
+    }
+
+    private void updateSimpleProperties(ActivityStreamsEntry source, ActivityStreamsEntry converted) {
+        converted.setId(source.getId() == null ? generateId() : source.getId());
+        converted.setOpenSocial(source.getOpenSocial());
+        converted.setObjectType(source.getObjectType());
+        converted.setExtensions(source.getExtensions());
+        converted.setUrl(source.getUrl());
+        converted.setAppId(source.getAppId());
+        converted.setBcc(source.getBcc());
+        converted.setBto(source.getBto());
+        converted.setCc(source.getCc());
+        converted.setContent(source.getContent());
+        converted.setDc(source.getDc());
+        converted.setContext(source.getContext());
+        converted.setGeojson(source.getGeojson());
+        converted.setGroupId(source.getGroupId());
+        converted.setInReplyTo(source.getInReplyTo());
+        converted.setLd(source.getLd());
+        converted.setLinks(source.getLinks());
+        converted.setEndTime(source.getEndTime());
+        converted.setLocation(source.getLocation());
+        converted.setMood(source.getMood());
+        converted.setOdata(source.getOdata());
+        converted.setPriority(source.getPriority());
+        converted.setPublished(source.getPublished());
+        converted.setOpengraph(source.getOpengraph());
+        converted.setRating(source.getRating());
+        converted.setResult(source.getResult());
+        converted.setSchema_org(source.getSchema_org());
+        converted.setSource(source.getSource());
+        converted.setTags(source.getTags());
+        converted.setTitle(source.getTitle());
+        converted.setSource(source.getSource());
+        converted.setTo(source.getTo());
+        converted.setUpdated(source.getUpdated());
+        converted.setUserId(source.getUserId());
+        converted.setVerb(source.getVerb());
+        converted.setUrl(source.getUrl());
+    }
+}

Added: rave/trunk/rave-components/rave-mongodb/src/test/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverterTest.java
URL: http://svn.apache.org/viewvc/rave/trunk/rave-components/rave-mongodb/src/test/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverterTest.java?rev=1450952&view=auto
==============================================================================
--- rave/trunk/rave-components/rave-mongodb/src/test/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverterTest.java (added)
+++ rave/trunk/rave-components/rave-mongodb/src/test/java/org/apache/rave/portal/model/conversion/impl/MongoDbActivityStreamsEntryConverterTest.java Wed Feb 27 20:47:57 2013
@@ -0,0 +1,113 @@
+/*
+ * 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.rave.portal.model.conversion.impl;
+
+import org.apache.rave.portal.model.ActivityStreamsEntry;
+import org.apache.rave.portal.model.ActivityStreamsMediaLink;
+import org.apache.rave.portal.model.ActivityStreamsObject;
+import org.apache.rave.portal.model.impl.ActivityStreamsEntryImpl;
+import org.junit.Before;
+import org.junit.Test;
+
+import java.lang.reflect.InvocationHandler;
+import java.lang.reflect.Method;
+import java.lang.reflect.Proxy;
+import java.util.Date;
+
+import static org.hamcrest.CoreMatchers.*;
+import static org.junit.Assert.assertThat;
+
+public class MongoDbActivityStreamsEntryConverterTest {
+
+    private static final String VALUE = "VALUE";
+    private static final Date DATE_VALUE = new Date();
+    private MongoDbActivityStreamsEntryConverter converter;
+
+    @Before
+    public void setup() {
+        converter = new MongoDbActivityStreamsEntryConverter();
+    }
+
+    @Test
+    public void checkAllNull() {
+        ActivityStreamsEntry converted = converter.convert((ActivityStreamsEntry)null);
+        assertThat(converted, is(nullValue()));
+    }
+
+    @Test
+    public void checkNullProperties() {
+        ActivityStreamsEntry source = new ActivityStreamsEntryImpl();
+        ActivityStreamsEntry converted = converter.convert(source);
+        assertThat(converted, is(not(sameInstance(source))));
+    }
+
+    @Test
+    public void checkPopulatedProperties() {
+        ActivityStreamsEntry source = createSource(ActivityStreamsEntry.class, true);
+        ActivityStreamsEntry converted = converter.convert(source);
+        assertThat(converted, is(not(sameInstance(source))));
+        assertThat(converted.getId(), is(not(nullValue())));
+        assertThat(converted.getVerb(), is(equalTo(VALUE)));
+        assertThat(converted.getContent(), is(equalTo(VALUE)));
+        assertThat(converted.getActor().getId(), is(not(nullValue())));
+        assertThat(converted.getObject().getId(), is(not(nullValue())));
+        assertThat(converted.getTarget().getId(), is(not(nullValue())));
+    }
+
+    private static <T> T createSource(Class<T> clazz, final boolean createId) {
+        return (T)Proxy.newProxyInstance(MongoDbActivityStreamsEntryConverterTest.class.getClassLoader(), new Class[]{clazz}, getInvocationHandler(createId));
+    }
+
+    private static InvocationHandler getInvocationHandler(final boolean createId) {
+        return new ActivityTestInvocationHandler(createId);
+    }
+
+    private static class ActivityTestInvocationHandler implements InvocationHandler {
+
+        private final boolean nullId;
+
+        public ActivityTestInvocationHandler(boolean nullId) {
+            this.nullId = nullId;
+        }
+
+        @Override
+        public Object invoke(Object object, Method method, Object[] params) throws Throwable {
+            Object returnValue = null;
+            if(method.getName().startsWith("get")) {
+                if(params != null) {
+                    throw new IllegalArgumentException("POJO get cannot have params");
+                }
+                Class<?> returnType = method.getReturnType();
+                if(returnType.equals(ActivityStreamsObject.class)) {
+                    returnValue = method.getName().equals("getAuthor") ? null : createSource(returnType, nullId);
+                } else if(returnType.equals(ActivityStreamsMediaLink.class)){
+                    returnValue = createSource(returnType, nullId);
+                } else if(returnType.equals(String.class)) {
+                    returnValue = method.getName().equals("getId") ? nullId ? null : VALUE : VALUE;
+                } else if(returnType.equals(Date.class)) {
+                    returnValue = DATE_VALUE;
+                }
+            }
+            return returnValue;
+        }
+
+
+    }
+}

Modified: rave/trunk/rave-portal-resources/src/main/resources/db/initial-data.json
URL: http://svn.apache.org/viewvc/rave/trunk/rave-portal-resources/src/main/resources/db/initial-data.json?rev=1450952&r1=1450951&r2=1450952&view=diff
==============================================================================
--- rave/trunk/rave-portal-resources/src/main/resources/db/initial-data.json (original)
+++ rave/trunk/rave-portal-resources/src/main/resources/db/initial-data.json Wed Feb 27 20:47:57 2013
@@ -63,633 +63,654 @@
             "renderSequence": 8,
             "userSelectable": false
         }
-    ],
-    "users": [
-        {
-            "id": 1,
-            "username": "canonical",
-            "email": "canonical@example.com",
-            "displayName": "Canonical User",
-            "additionalName": null,
-            "familyName": "User",
-            "givenName": "Canonical",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$TkEgze5kLy9nRlfd8PT1zunh6P1ND8WPjLojFjAMNgZMu1D9D1n4.",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 2,
-                    "authority": "ROLE_ADMIN",
-                    "users": [],
-                    "defaultForNewUser": false
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 1,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 2,
-            "username": "john.doe",
-            "email": "john.doe@example.com",
-            "displayName": "John Doe",
-            "additionalName": null,
-            "familyName": "Doe",
-            "givenName": "John",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$8Dir7boy3UyVqy6erfj6WuQXUTf.ejTldPSsVIty7.pPT3Krkly26",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 2,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 3,
-            "username": "jane.doe",
-            "email": "jane.doe@example.net",
-            "displayName": "Jane Doe",
-            "additionalName": null,
-            "familyName": "Doe",
-            "givenName": "Jane",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$YP9cjZEA.gG/ng2YwTBIyucMpuiQ7Fvz0K8rOt14rIBhVwlOrh1tu",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 3,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
+    ], "users": [
+    {
+        "id": 1,
+        "username": "canonical",
+        "email": "canonical@example.com",
+        "displayName": "Canonical User",
+        "additionalName": null,
+        "familyName": "User",
+        "givenName": "Canonical",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [
+            {
+                "type": "thumbnailUrl",
+                "value": "http://opensocial2.org:8080/collabapp/images/avatars/BillRanney.jpg"
+            }
+        ],
+        "groups": [],
+        "password": "$2a$10$TkEgze5kLy9nRlfd8PT1zunh6P1ND8WPjLojFjAMNgZMu1D9D1n4.",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
             "id": 4,
-            "username": "george.doe",
-            "email": "george.doe@example.org",
-            "displayName": "George Doe",
-            "additionalName": null,
-            "familyName": "Doe",
-            "givenName": "George",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$0bcOUkQgAwE/qmdc1NcUveNzx/IYIcOUu4ydyT8DEicTCxGJF/vcW",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 2,
+                "authority": "ROLE_ADMIN",
+                "users": [],
+                "defaultForNewUser": false
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 1,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 2,
+        "username": "john.doe",
+        "email": "john.doe@example.com",
+        "displayName": "John Doe",
+        "additionalName": null,
+        "familyName": "Doe",
+        "givenName": "John",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [
+            {
+                "type": "thumbnailUrl",
+                "value": "http://opensocial2.org:8080/collabapp/images/avatars/DanMisawa.jpg"
+            }
+        ],
+        "groups": [],
+        "password": "$2a$10$8Dir7boy3UyVqy6erfj6WuQXUTf.ejTldPSsVIty7.pPT3Krkly26",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
             "id": 4,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 5,
-            "username": "mario.rossi",
-            "email": "mario.rossi@example.com",
-            "displayName": "Mario Rossi",
-            "additionalName": null,
-            "familyName": "Rossi",
-            "givenName": "Mario",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$HZ6WHAKQCs8waLooL98l6.fLzwh3D8u/V0.UebIjojawfXJhX1DQ2",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 5,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 6,
-            "username": "maija.m",
-            "email": "maijam@example.com",
-            "displayName": "Maija M",
-            "additionalName": null,
-            "familyName": "M",
-            "givenName": "Maija",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$3feYdjrW40hkqP4/xupKP.YMgdYmDsZZus./vK4FbBs9QZG2.FuNC",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 6,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 7,
-            "username": "one.col",
-            "email": "one.col@example.com",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "Column",
-            "givenName": "One",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$5VqE2YEqT75pCVjKqjP2b.gNGly9fsTVUOMQR/JEjkHSbqvA3A6IO",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 7,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 8,
-            "username": "twown.col",
-            "email": "twown.col@example.com",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "Column",
-            "givenName": "Two",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$Inpufv82TRUGYoPuXhYXVuMCKHkhLz44W6FijxW2e9n3T1hgyxcVq",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 8,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 9,
-            "username": "three.col",
-            "email": "three.col@example.com",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "Column",
-            "givenName": "Three",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$ImRXq4gFC9teBstOBdQrZeEwBkCAJ0S6.CwI9/9r7fxWKTZ30pgVC",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 9,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 10,
-            "username": "threewn.col",
-            "email": "threewn.col@example.com",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "ColumnWide",
-            "givenName": "Three",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$LLYTJoK6MCBpeDBbmdt7tu1LNt7Eenqe1IpMlfem8xVjzynn.HpxW",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 10,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 11,
-            "username": "four.col",
-            "email": "four.col@example.com",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "Column",
-            "givenName": "Four",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$tZgWcaG2EJPLtseZ339n7uTu3GZn31h3iTr20orwgbbRAI15uoIFK",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 11,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 12,
-            "username": "fourwn.col",
-            "email": "fourwn.col@example.com",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "ColumnWide",
-            "givenName": "Four",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$4kPYhgowurWqXGVDigxOxOVj/M.rqLRwqbn0kT/OD4pISL6pDG/c2",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": null,
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 12,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        },
-        {
-            "id": 13,
-            "username": "rave2011.myopenid.com",
-            "email": "rave2011_openid@example.org",
-            "displayName": null,
-            "additionalName": null,
-            "familyName": "OpenId",
-            "givenName": "Rave",
-            "honorificPrefix": null,
-            "honorificSuffix": null,
-            "preferredName": null,
-            "aboutMe": null,
-            "status": "Single",
-            "addresses": [],
-            "organizations": [],
-            "properties": [],
-            "groups": [],
-            "password": "$2a$10$dML97.rnOn4.iSlEEdju8OCB2NckuKw0Ki5yMVzzMmWQsWMvym3qC",
-            "expired": false,
-            "locked": false,
-            "enabled": true,
-            "openId": "http://rave2011.myopenid.com/",
-            "forgotPasswordHash": null,
-            "forgotPasswordTime": null,
-            "defaultPageLayout": {
-                "id": 4,
-                "code": "columns_3",
-                "numberOfRegions": 3,
-                "renderSequence": 3,
-                "userSelectable": true
-            },
-            "confirmPassword": null,
-            "defaultPageLayoutCode": null,
-            "authorities": [
-                {
-                    "id": 1,
-                    "authority": "ROLE_USER",
-                    "users": [],
-                    "defaultForNewUser": true
-                }
-            ],
-            "pageUsers": [],
-            "widgetTags": [],
-            "id": 13,
-            "accountNonLocked": true,
-            "credentialsNonExpired": true,
-            "accountNonExpired": true
-        }
-    ],
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 2,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 3,
+        "username": "jane.doe",
+        "email": "jane.doe@example.net",
+        "displayName": "Jane Doe",
+        "additionalName": null,
+        "familyName": "Doe",
+        "givenName": "Jane",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [
+            {
+                "type": "thumbnailUrl",
+                "value": "http://opensocial2.org:8080/collabapp/images/avatars/KellyHardart.jpg"
+            }
+        ],
+        "groups": [],
+        "password": "$2a$10$YP9cjZEA.gG/ng2YwTBIyucMpuiQ7Fvz0K8rOt14rIBhVwlOrh1tu",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 3,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 4,
+        "username": "george.doe",
+        "email": "george.doe@example.org",
+        "displayName": "George Doe",
+        "additionalName": null,
+        "familyName": "Doe",
+        "givenName": "George",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [
+
+        ],
+        "groups": [],
+        "password": "$2a$10$0bcOUkQgAwE/qmdc1NcUveNzx/IYIcOUu4ydyT8DEicTCxGJF/vcW",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 4,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 5,
+        "username": "mario.rossi",
+        "email": "mario.rossi@example.com",
+        "displayName": "Mario Rossi",
+        "additionalName": null,
+        "familyName": "Rossi",
+        "givenName": "Mario",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [
+            {
+                "type": "thumbnailUrl",
+                "value": "http://opensocial2.org:8080/collabapp/images/avatars/FrankAdams.jpg"
+            }
+        ],
+        "groups": [],
+        "password": "$2a$10$HZ6WHAKQCs8waLooL98l6.fLzwh3D8u/V0.UebIjojawfXJhX1DQ2",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 5,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 6,
+        "username": "maija.m",
+        "email": "maijam@example.com",
+        "displayName": "Maija M",
+        "additionalName": null,
+        "familyName": "M",
+        "givenName": "Maija",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$3feYdjrW40hkqP4/xupKP.YMgdYmDsZZus./vK4FbBs9QZG2.FuNC",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 6,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 7,
+        "username": "one.col",
+        "email": "one.col@example.com",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "Column",
+        "givenName": "One",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$5VqE2YEqT75pCVjKqjP2b.gNGly9fsTVUOMQR/JEjkHSbqvA3A6IO",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 7,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 8,
+        "username": "twown.col",
+        "email": "twown.col@example.com",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "Column",
+        "givenName": "Two",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$Inpufv82TRUGYoPuXhYXVuMCKHkhLz44W6FijxW2e9n3T1hgyxcVq",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 8,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 9,
+        "username": "three.col",
+        "email": "three.col@example.com",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "Column",
+        "givenName": "Three",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$ImRXq4gFC9teBstOBdQrZeEwBkCAJ0S6.CwI9/9r7fxWKTZ30pgVC",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 9,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 10,
+        "username": "threewn.col",
+        "email": "threewn.col@example.com",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "ColumnWide",
+        "givenName": "Three",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$LLYTJoK6MCBpeDBbmdt7tu1LNt7Eenqe1IpMlfem8xVjzynn.HpxW",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 10,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 11,
+        "username": "four.col",
+        "email": "four.col@example.com",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "Column",
+        "givenName": "Four",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$tZgWcaG2EJPLtseZ339n7uTu3GZn31h3iTr20orwgbbRAI15uoIFK",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 11,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 12,
+        "username": "fourwn.col",
+        "email": "fourwn.col@example.com",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "ColumnWide",
+        "givenName": "Four",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$4kPYhgowurWqXGVDigxOxOVj/M.rqLRwqbn0kT/OD4pISL6pDG/c2",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": null,
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 12,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    },
+    {
+        "id": 13,
+        "username": "rave2011.myopenid.com",
+        "email": "rave2011_openid@example.org",
+        "displayName": null,
+        "additionalName": null,
+        "familyName": "OpenId",
+        "givenName": "Rave",
+        "honorificPrefix": null,
+        "honorificSuffix": null,
+        "preferredName": null,
+        "aboutMe": null,
+        "status": "Single",
+        "addresses": [],
+        "organizations": [],
+        "properties": [],
+        "groups": [],
+        "password": "$2a$10$dML97.rnOn4.iSlEEdju8OCB2NckuKw0Ki5yMVzzMmWQsWMvym3qC",
+        "expired": false,
+        "locked": false,
+        "enabled": true,
+        "openId": "http://rave2011.myopenid.com/",
+        "forgotPasswordHash": null,
+        "forgotPasswordTime": null,
+        "defaultPageLayout": {
+            "id": 4,
+            "code": "columns_3",
+            "numberOfRegions": 3,
+            "renderSequence": 3,
+            "userSelectable": true
+        },
+        "confirmPassword": null,
+        "defaultPageLayoutCode": null,
+        "authorities": [
+            {
+                "id": 1,
+                "authority": "ROLE_USER",
+                "users": [],
+                "defaultForNewUser": true
+            }
+        ],
+        "pageUsers": [],
+        "widgetTags": [],
+        "id": 13,
+        "accountNonLocked": true,
+        "credentialsNonExpired": true,
+        "accountNonExpired": true
+    }
+],
     "groups": [
         {
             "id": 1,
@@ -1076,7 +1097,7 @@
         {
             "id": 18,
             "title": "Activity Stream",
-            "url": "https://raw.github.com/OpenSocial/examples/master/gadgets/activitystream/gadget.xml",
+            "url": "http://accelerator.opensocial2.org/gadgets/examples/gadgets/activitystream/gadget.xml",
             "type": "OpenSocial",
             "author": "OpenSocial Foundation",
             "description": "OpenSocial Activity Stream gadget with support for Embedded Experiences",
@@ -1208,7 +1229,7 @@
         {
             "id": 30,
             "title": "EE jQuery Photo Example",
-            "url": "http://eedemos.opensocial2.org/gadgets/jquery/photos/jquery_photo_ee.xml",
+            "url": "http://accelerator.opensocial2.org/gadgets/photos/jquery_photo_ee.xml",
             "type": "OpenSocial",
             "author": "OpenSocial Foundation",
             "description": "Example jQuery Photo Embedded Experience Gadget",
@@ -1550,7 +1571,7 @@
             },
             "openSocial": {
                 "embed": {
-                    "gadget": "http://eedemos.opensocial2.org/gadgets/jquery/photos/jquery_photo_ee.xml",
+                    "gadget": "http://accelerator.opensocial2.org/gadgets/photos/jquery_photo_ee.xml",
                     "preferredExperience": {
                         "display": {
                             "type": "text",
@@ -1620,7 +1641,7 @@
                 }
             },
             "verb": "make-friend",
-            "object" : {
+            "object": {
                 "url": "http://localhost:8080/portal/app/people/jane.doe",
                 "objectType": "person",
                 "id": "jane.doe",

Modified: rave/trunk/rave-portal-resources/src/main/webapp/static/script/rave_opensocial.js
URL: http://svn.apache.org/viewvc/rave/trunk/rave-portal-resources/src/main/webapp/static/script/rave_opensocial.js?rev=1450952&r1=1450951&r2=1450952&view=diff
==============================================================================
--- rave/trunk/rave-portal-resources/src/main/webapp/static/script/rave_opensocial.js (original)
+++ rave/trunk/rave-portal-resources/src/main/webapp/static/script/rave_opensocial.js Wed Feb 27 20:47:57 2013
@@ -107,12 +107,14 @@ rave.opensocial = rave.opensocial || (fu
             			  	  "widgetUrl": widgetUrl,
             			  	  "securityToken": data.securityToken,
             			  	  "metadata": opt_gadgetInfo
-            				}
-            		
+                            },
+                            height = data.metadata ? data.metadata.height : 500,
+                            width = data.metadata ? data.metadata.width : 525;
+
             				preloadMetadata(gadget);
                         
             				if (opt_viewTarget) {
-            					opt_callback(rave.createPopup(opt_viewTarget));
+            					opt_callback(rave.createPopup(opt_viewTarget, {"preferredHeight" : height, preferredWidth: width}));
             				}
             			} else {
             				console.log(data.error.message);