Merged V2.2 to HEAD

7653: Update and added deployment icons
   7655: Fixed multithreaded test case to handle case where threads can't get started due to lack of available DB connections.
   7657: AR-1903: Text attachments should be treated the same way as other attachments.
   7661: Fixed duplicate index creation for column that is also declared unique
   7662: Additional indexes related to permissions
   7664: Fixed query for specific property types
   7667: Used existing attachable aspect for email attachments - effectively reversing association direction.
   7682: Added AVM Console page to webapp (admin user protected)
   7683: Merged V2.1 to V2.2
      7642: Fix for WCM-949
      7668: Debugging output for getAPath(). Possible partial fix for LazyInitialization errors seen by some customers
      7672: Fixed sub optimal tree pruning in filesystem deployment


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@8442 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2008-03-06 21:28:43 +00:00
parent ab80624ce0
commit ecb74c1447
19 changed files with 215 additions and 79 deletions

View File

@@ -691,17 +691,17 @@ public class PropertyValue implements Cloneable, Serializable
}
/**
* Given an actual type qualified name, returns the <tt>String</tt> that represents it in
* the database.
* Given an actual type qualified name, returns the <tt>int</tt> ordinal number
* that represents it in the database.
*
* @param typeQName the type qualified name
* @return Returns the <tt>String</tt> representation of the type,
* e.g. <b>CONTENT</b> for type <b>d:content</b>.
* @return Returns the <tt>int</tt> representation of the type,
* e.g. <b>CONTENT.getOrdinalNumber()</b> for type <b>d:content</b>.
*/
public static String getActualTypeString(QName typeQName)
public static int convertToTypeOrdinal(QName typeQName)
{
ValueType valueType = makeValueType(typeQName);
return valueType.toString();
return valueType.getOrdinalNumber();
}
@Override

View File

@@ -158,18 +158,17 @@ public class QNameDAOTest extends TestCase
logger.debug("Failed to create QNameEntity. Might retry.", e);
throw e;
}
finally
{
// Notify the counter that this thread is done
logger.debug("Thread " + threadName + " is DONE");
doneLatch.countDown();
}
}
else
{
throw new RuntimeException("QName entity should not exist");
// In the case where the threads have to wait for database connections,
// it is quite possible that the entity was created as the ready latch
// is released after five seconds
}
assertNotNull("QName should now exist", qnameEntity);
// Notify the counter that this thread is done
logger.debug("Thread " + threadName + " is DONE");
doneLatch.countDown();
// Done
return qnameEntity;
}
@@ -201,7 +200,7 @@ public class QNameDAOTest extends TestCase
// Let the threads go
startLatch.countDown();
// Wait for them all to be done (within limit of 10 seconds per thread)
doneLatch.await(threadCount * 10, TimeUnit.SECONDS);
doneLatch.await(threadCount, TimeUnit.SECONDS);
if (doneLatch.getCount() > 0)
{
fail("Still waiting for threads to finish");

View File

@@ -451,8 +451,8 @@
node.properties prop
where
(
prop.actualType = :actualTypeString or
prop.actualType = 'SERIALIZABLE'
prop.actualType = :actualType or
prop.actualType = 9
) and
prop.persistedType != 0
</query>

View File

@@ -54,9 +54,9 @@
<version column="version" name="version" type="long" />
<property name="inherits" column="inherits" type="boolean" not-null="true" />
<property name="inherits" column="inherits" type="boolean" not-null="true" index="idx_pm_acl_inh" />
<property name="inheritsFrom" column="inherits_from" type="long" not-null="false" />
<property name="inheritsFrom" column="inherits_from" type="long" not-null="false" index="idx_pm_acl_inh" />
<property name="type" column="type" type="int" not-null="true" />