mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged HEAD-BUG-FIX (5.1/Cloud) to HEAD (5.1/Cloud)
89043: Merged V4.2-BUG-FIX (4.2.4) to HEAD-BUG-FIX (5.0/Cloud) 88875: Merged DEV (4.2.4) to V4.2-BUG-FIX (4.2.4) 88823: MNT-12587: MySQL: Query to retrieve orphaned content URLs can cause memory issues Added fetchSize parameter to select_ContentUrlsOrphaned query for MySQL. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@94598 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -199,6 +199,7 @@ Inbound settings from iBatis
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/locks-common-SqlMap.xml"/>
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/locks-insert-SqlMap.xml"/>
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/content-common-SqlMap.xml"/>
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/content-select-SqlMap.xml"/>
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/content-insert-SqlMap.xml"/>
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/node-common-SqlMap.xml"/>
|
||||
<mapper resource="alfresco/ibatis/#resource.dialect#/node-select-children-SqlMap.xml"/>
|
||||
|
@@ -271,22 +271,6 @@
|
||||
cd.id is null
|
||||
</select>
|
||||
|
||||
<!-- Get content URL entities that were orphaned before a give time -->
|
||||
<select id="select_ContentUrlsOrphaned" parameterType="ContentUrlOrphanQuery" resultMap="result_ContentUrl">
|
||||
<![CDATA[
|
||||
select
|
||||
cu.*
|
||||
from
|
||||
alf_content_url cu
|
||||
left outer join alf_content_data cd on (cd.content_url_id = cu.id)
|
||||
where
|
||||
cd.id is null and
|
||||
cu.orphan_time > 0 and
|
||||
cu.orphan_time < #{maxOrphanTimeExclusive} and
|
||||
cu.orphan_time is not null
|
||||
]]>
|
||||
</select>
|
||||
|
||||
<!-- Update a specific mimetype -->
|
||||
<update id="update_Mimetype" parameterType="Mimetype">
|
||||
update
|
||||
|
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<!--
|
||||
Select statements that require proper size limiting on the DB side
|
||||
Dialect: Generic
|
||||
-->
|
||||
<mapper namespace="alfresco.content.select">
|
||||
|
||||
<!-- Get content URL entities that were orphaned before a give time -->
|
||||
<select id="select_ContentUrlsOrphaned" parameterType="ContentUrlOrphanQuery" resultMap="result_ContentUrl">
|
||||
<![CDATA[
|
||||
select
|
||||
cu.*
|
||||
from
|
||||
alf_content_url cu
|
||||
left outer join alf_content_data cd on (cd.content_url_id = cu.id)
|
||||
where
|
||||
cd.id is null and
|
||||
cu.orphan_time > 0 and
|
||||
cu.orphan_time < #{maxOrphanTimeExclusive} and
|
||||
cu.orphan_time is not null
|
||||
]]>
|
||||
</select>
|
||||
|
||||
</mapper>
|
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
|
||||
<!--
|
||||
Select statements that require proper size limiting on the DB side
|
||||
Dialect: MySQL
|
||||
-->
|
||||
<mapper namespace="alfresco.content.select">
|
||||
|
||||
<!-- Get content URL entities that were orphaned before a give time -->
|
||||
<select id="select_ContentUrlsOrphaned" fetchSize="-2147483648" parameterType="ContentUrlOrphanQuery" resultMap="result_ContentUrl">
|
||||
<![CDATA[
|
||||
select
|
||||
cu.*
|
||||
from
|
||||
alf_content_url cu
|
||||
left outer join alf_content_data cd on (cd.content_url_id = cu.id)
|
||||
where
|
||||
cd.id is null and
|
||||
cu.orphan_time > 0 and
|
||||
cu.orphan_time < #{maxOrphanTimeExclusive} and
|
||||
cu.orphan_time is not null
|
||||
]]>
|
||||
</select>
|
||||
|
||||
</mapper>
|
@@ -56,7 +56,7 @@ public class ContentDataDAOImpl extends AbstractContentDataDAOImpl
|
||||
private static final String SELECT_CONTENT_URL_BY_ID = "alfresco.content.select_ContentUrlById";
|
||||
private static final String SELECT_CONTENT_URL_BY_KEY = "alfresco.content.select_ContentUrlByKey";
|
||||
private static final String SELECT_CONTENT_URL_BY_KEY_UNREFERENCED = "alfresco.content.select_ContentUrlByKeyUnreferenced";
|
||||
private static final String SELECT_CONTENT_URLS_ORPHANED = "alfresco.content.select_ContentUrlsOrphaned";
|
||||
private static final String SELECT_CONTENT_URLS_ORPHANED = "alfresco.content.select.select_ContentUrlsOrphaned";
|
||||
private static final String SELECT_CONTENT_DATA_BY_ID = "alfresco.content.select_ContentDataById";
|
||||
private static final String SELECT_CONTENT_DATA_BY_NODE_AND_QNAME = "alfresco.content.select_ContentDataByNodeAndQName";
|
||||
private static final String SELECT_CONTENT_DATA_BY_NODE_IDS = "alfresco.content.select_ContentDataByNodeIds";
|
||||
|
Reference in New Issue
Block a user