You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2014/06/26 13:57:34 UTC

svn commit: r1605751 - in /syncope/trunk: ./ console/src/main/webapp/css/ core/src/main/java/org/apache/syncope/core/notification/ core/src/main/java/org/apache/syncope/core/persistence/beans/ core/src/main/java/org/apache/syncope/core/persistence/dao/...

Author: ilgrosso
Date: Thu Jun 26 11:57:33 2014
New Revision: 1605751

URL: http://svn.apache.org/r1605751
Log:
[SYNCOPE-511] Merge from 1_1_X

Modified:
    syncope/trunk/   (props changed)
    syncope/trunk/console/src/main/webapp/css/style.css
    syncope/trunk/core/src/main/java/org/apache/syncope/core/notification/NotificationJob.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/beans/ExternalResource.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractDAOImpl.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractSubjectDAOImpl.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectPushResultHandler.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectSyncResultHandler.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/PushJob.java
    syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/UserSyncResultHandler.java

Propchange: syncope/trunk/
------------------------------------------------------------------------------
  Merged /syncope/branches/1_1_X:r1605303-1605741

Modified: syncope/trunk/console/src/main/webapp/css/style.css
URL: http://svn.apache.org/viewvc/syncope/trunk/console/src/main/webapp/css/style.css?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/console/src/main/webapp/css/style.css (original)
+++ syncope/trunk/console/src/main/webapp/css/style.css Thu Jun 26 11:57:33 2014
@@ -541,4 +541,10 @@ div.wicket-aa ul li.selected {
 .notificationpanel_row_ERROR span {  
   border:0 none;
 }    
-
+pre {
+  white-space: -moz-pre-wrap; /* Mozilla, supported since 1999 */
+  white-space: -pre-wrap; /* Opera */
+  white-space: -o-pre-wrap; /* Opera */
+  white-space: pre-wrap; /* CSS3 - Text module (Candidate Recommendation) http://www.w3.org/TR/css3-text/#white-space */
+  word-wrap: break-word; /* IE 5.5+ */
+}
\ No newline at end of file

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/notification/NotificationJob.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/notification/NotificationJob.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/notification/NotificationJob.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/notification/NotificationJob.java Thu Jun 26 11:57:33 2014
@@ -21,7 +21,6 @@ package org.apache.syncope.core.notifica
 import java.util.Date;
 
 import javax.mail.internet.MimeMessage;
-
 import org.apache.commons.lang3.StringUtils;
 import org.apache.syncope.common.types.AuditElements;
 import org.apache.syncope.common.types.AuditElements.Result;

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/beans/ExternalResource.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/beans/ExternalResource.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/beans/ExternalResource.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/beans/ExternalResource.java Thu Jun 26 11:57:33 2014
@@ -39,7 +39,6 @@ import javax.validation.constraints.Max;
 import javax.validation.constraints.Min;
 import javax.validation.constraints.NotNull;
 import org.apache.commons.lang3.StringUtils;
-import org.apache.openjpa.persistence.PersistentCollection;
 import org.apache.syncope.common.types.ConnConfProperty;
 import org.apache.syncope.common.types.PropagationMode;
 import org.apache.syncope.common.types.TraceLevel;

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractDAOImpl.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractDAOImpl.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractDAOImpl.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractDAOImpl.java Thu Jun 26 11:57:33 2014
@@ -24,8 +24,7 @@ import javax.persistence.CacheStoreMode;
 import javax.persistence.EntityManager;
 import javax.persistence.PersistenceContext;
 import javax.persistence.PersistenceContextType;
-
-import org.apache.commons.lang.StringUtils;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.syncope.core.persistence.beans.AbstractBaseBean;
 import org.apache.syncope.core.persistence.dao.DAO;
 import org.apache.syncope.core.persistence.dao.search.OrderByClause;

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractSubjectDAOImpl.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractSubjectDAOImpl.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractSubjectDAOImpl.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/persistence/dao/impl/AbstractSubjectDAOImpl.java Thu Jun 26 11:57:33 2014
@@ -32,7 +32,7 @@ import javax.persistence.TypedQuery;
 import org.apache.commons.jexl2.parser.Parser;
 import org.apache.commons.jexl2.parser.ParserConstants;
 import org.apache.commons.jexl2.parser.Token;
-import org.apache.commons.lang.StringUtils;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.syncope.core.persistence.beans.AbstractAttrValue;
 import org.apache.syncope.core.persistence.beans.AbstractAttributable;
 import org.apache.syncope.core.persistence.beans.AbstractDerSchema;

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectPushResultHandler.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectPushResultHandler.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectPushResultHandler.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectPushResultHandler.java Thu Jun 26 11:57:33 2014
@@ -23,6 +23,7 @@ import java.util.Collections;
 import java.util.HashSet;
 import java.util.Map;
 import java.util.Set;
+import org.apache.commons.lang3.exception.ExceptionUtils;
 import org.apache.syncope.common.types.AttributableType;
 import org.apache.syncope.common.types.AuditElements;
 import org.apache.syncope.common.types.AuditElements.Result;
@@ -225,7 +226,7 @@ public abstract class AbstractSubjectPus
             output = getRemoteObject(oclass, values.getKey(), profile.getSyncTask().getResource().getName());
         } catch (Exception e) {
             result.setStatus(SyncResult.Status.FAILURE);
-            result.setMessage(e.getMessage());
+            result.setMessage(ExceptionUtils.getRootCauseMessage(e));
             resultStatus = AuditElements.Result.FAILURE;
             output = e;
 

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectSyncResultHandler.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectSyncResultHandler.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectSyncResultHandler.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/AbstractSubjectSyncResultHandler.java Thu Jun 26 11:57:33 2014
@@ -19,12 +19,14 @@
 package org.apache.syncope.core.sync.impl;
 
 import org.apache.syncope.core.sync.SyncUtilities;
+
 import static org.apache.syncope.core.sync.impl.AbstractSyncopeResultHandler.LOG;
 
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
 import java.util.List;
+import org.apache.commons.lang3.exception.ExceptionUtils;
 import org.apache.syncope.common.mod.AbstractSubjectMod;
 import org.apache.syncope.common.to.AbstractSubjectTO;
 import org.apache.syncope.common.to.RoleTO;
@@ -183,7 +185,7 @@ public abstract class AbstractSubjectSyn
                 resultStatus = Result.FAILURE;
             } catch (Exception e) {
                 result.setStatus(SyncResult.Status.FAILURE);
-                result.setMessage(e.getMessage());
+                result.setMessage(ExceptionUtils.getRootCauseMessage(e));
                 LOG.error("Could not create {} {} ", attrUtil.getType(), _delta.getUid().getUidValue(), e);
                 output = e;
                 resultStatus = Result.FAILURE;
@@ -278,7 +280,7 @@ public abstract class AbstractSubjectSyn
                 resultStatus = Result.FAILURE;
             } catch (Exception e) {
                 result.setStatus(SyncResult.Status.FAILURE);
-                result.setMessage(e.getMessage());
+                result.setMessage(ExceptionUtils.getRootCauseMessage(e));
                 LOG.error("Could not update {} {}", attrUtil.getType(), delta.getUid().getUidValue(), e);
                 output = e;
                 resultStatus = Result.FAILURE;
@@ -387,7 +389,7 @@ public abstract class AbstractSubjectSyn
                 resultStatus = Result.FAILURE;
             } catch (Exception e) {
                 result.setStatus(SyncResult.Status.FAILURE);
-                result.setMessage(e.getMessage());
+                result.setMessage(ExceptionUtils.getRootCauseMessage(e));
                 LOG.error("Could not update {} {}", attrUtil.getType(), delta.getUid().getUidValue(), e);
                 output = e;
                 resultStatus = Result.FAILURE;
@@ -495,7 +497,7 @@ public abstract class AbstractSubjectSyn
                 resultStatus = Result.FAILURE;
             } catch (Exception e) {
                 result.setStatus(SyncResult.Status.FAILURE);
-                result.setMessage(e.getMessage());
+                result.setMessage(ExceptionUtils.getRootCauseMessage(e));
                 LOG.error("Could not update {} {}", attrUtil.getType(), delta.getUid().getUidValue(), e);
                 output = e;
                 resultStatus = Result.FAILURE;
@@ -575,7 +577,7 @@ public abstract class AbstractSubjectSyn
                         resultStatus = Result.SUCCESS;
                     } catch (Exception e) {
                         result.setStatus(SyncResult.Status.FAILURE);
-                        result.setMessage(e.getMessage());
+                        result.setMessage(ExceptionUtils.getRootCauseMessage(e));
                         LOG.error("Could not delete {} {}", attrUtil.getType(), id, e);
                         output = e;
                     }

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/PushJob.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/PushJob.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/PushJob.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/PushJob.java Thu Jun 26 11:57:33 2014
@@ -23,7 +23,7 @@ import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
 import java.util.Set;
-import org.apache.commons.lang.StringUtils;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.syncope.common.types.SubjectType;
 import org.apache.syncope.common.types.SyncPolicySpec;
 import org.apache.syncope.core.persistence.beans.PushTask;

Modified: syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/UserSyncResultHandler.java
URL: http://svn.apache.org/viewvc/syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/UserSyncResultHandler.java?rev=1605751&r1=1605750&r2=1605751&view=diff
==============================================================================
--- syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/UserSyncResultHandler.java (original)
+++ syncope/trunk/core/src/main/java/org/apache/syncope/core/sync/impl/UserSyncResultHandler.java Thu Jun 26 11:57:33 2014
@@ -19,11 +19,13 @@
 package org.apache.syncope.core.sync.impl;
 
 import static org.apache.syncope.core.sync.impl.AbstractSyncopeResultHandler.LOG;
+
 import java.util.AbstractMap;
 import java.util.Collections;
 import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
+import org.apache.commons.lang3.exception.ExceptionUtils;
 import org.apache.syncope.common.mod.AbstractSubjectMod;
 import org.apache.syncope.common.mod.UserMod;
 import org.apache.syncope.common.to.AbstractSubjectTO;
@@ -107,7 +109,8 @@ public class UserSyncResultHandler exten
             LOG.error("Update of user {} failed, trying to sync its status anyway (if configured)", before.getId(), e);
 
             result.setStatus(SyncResult.Status.FAILURE);
-            result.setMessage("Update failed, trying to sync status anyway (if configured)\n" + e.getMessage());
+            result.setMessage("Update failed, trying to sync status anyway (if configured)\n"
+                    + ExceptionUtils.getRootCauseMessage(e));
 
             updated = new WorkflowResult<Map.Entry<UserMod, Boolean>>(
                     new AbstractMap.SimpleEntry<UserMod, Boolean>(userMod, false), new PropagationByResource(),