mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Performance tweaks for AVM Indexing.
Removed calls to getXXXPaths(). Changed mappings of properties and aspects on AVM Nodes to favor get all calls. Added getAspects() and getNodeProperties() which take AVMNodeDescriptors. Used these in AVM Indexing to reduce the number of redundant full lookups. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6121 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -51,6 +51,22 @@
|
||||
<key column="id"/>
|
||||
<element type="QName" not-null="true" column="name" length="200"/>
|
||||
</set>
|
||||
<map name="properties" fetch="join" lazy="false" table="avm_node_properties_new" cascade="all" optimistic-lock="true">
|
||||
<cache usage="read-write"/>
|
||||
<key column="node_id" not-null="true"/>
|
||||
<map-key type="QName" length="200" column="qname"/>
|
||||
<composite-element class="org.alfresco.repo.domain.PropertyValue">
|
||||
<property name="actualType" column="actual_type" type="string" length="15" not-null="true" />
|
||||
<property name="multiValued" column="multi_valued" type="boolean" not-null="true" />
|
||||
<property name="persistedType" column="persisted_type" type="string" length="15" not-null="true" />
|
||||
<property name="booleanValue" column="boolean_value" type="boolean" />
|
||||
<property name="longValue" column="long_value" type="long" />
|
||||
<property name="floatValue" column="float_value" type="float" />
|
||||
<property name="doubleValue" column="double_value" type="double" />
|
||||
<property name="stringValue" column="string_value" type="string" length="1024"/>
|
||||
<property name="serializableValue" column="serializable_value" type="serializable" length="16384"/>
|
||||
</composite-element>
|
||||
</map>
|
||||
<!-- Deleted nodes -->
|
||||
<subclass name="DeletedNodeImpl"
|
||||
proxy="DeletedNode"
|
||||
|
@@ -1,5 +1,6 @@
|
||||
package org.alfresco.repo.avm.hibernate;
|
||||
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
|
||||
import org.alfresco.repo.avm.AVMNode;
|
||||
@@ -91,4 +92,15 @@ class AVMNodePropertyDAOHibernate extends HibernateDaoSupport
|
||||
delete.setParameter("name", name);
|
||||
delete.executeUpdate();
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see org.alfresco.repo.avm.AVMNodePropertyDAO#iterate()
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public Iterator<AVMNodeProperty> iterate()
|
||||
{
|
||||
Query query =
|
||||
getSession().createQuery("from AVMNodePropertyImpl anp");
|
||||
return (Iterator<AVMNodeProperty>)query.iterate();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user