从6.1迁移后,我们正面临着liferay 6.2的性能问题。
我们的自定义以及liferay的插件portlet几乎都在响应very slow for non admin users
。
我们观察到权限检查似乎需要花费大量时间。以下查询被点击了很多次......
(
SELECT DISTINCT Group_.groupId AS groupId
,REPLACE(Group_.NAME, ' LFR_ORGANIZATION', '') AS groupName
,Group_.type_ AS groupType
,Group_.friendlyURL AS groupFriendlyURL
FROM Group_
INNER JOIN Users_Groups ON (Users_Groups.groupId = Group_.groupId)
WHERE (Group_.liveGroupId = 0)
AND (Group_.active_ = 1)
AND (Group_.liveGroupId = 0)
AND (Users_Groups.userId = 3391488)
AND (Group_.companyId = 10132)
AND (
Group_.classNameId = 10012
OR Group_.classNameId = 10024
)
AND (Group_.parentGroupId != - 1)
AND (Group_.liveGroupId = 0)
AND (Group_.NAME != 'Control Panel')
AND (
Group_.NAME LIKE NULL
OR NULL IS NULL
)
AND (
Group_.description LIKE NULL
OR NULL IS NULL
)
AND (Group_.type_ != 4)
)
UNION
(
SELECT DISTINCT Group_.groupId AS groupId
,REPLACE(Group_.NAME, ' LFR_ORGANIZATION', '') AS groupName
,Group_.type_ AS groupType
,Group_.friendlyURL AS groupFriendlyURL
FROM Group_
INNER JOIN Users_Orgs ON (Users_Orgs.organizationId = Group_.classPK)
WHERE (Group_.liveGroupId = 0)
AND (Group_.active_ = 1)
AND (Users_Orgs.userId = 3391488)
AND (Group_.companyId = 10132)
AND (
Group_.classNameId = 10012
OR Group_.classNameId = 10024
)
AND (Group_.parentGroupId != - 1)
AND (Group_.liveGroupId = 0)
AND (Group_.NAME != 'Control Panel')
AND (
Group_.NAME LIKE NULL
OR NULL IS NULL
)
AND (
Group_.description LIKE NULL
OR NULL IS NULL
)
AND (Group_.type_ != 4)
)
UNION
(
SELECT DISTINCT Group_.groupId AS groupId
,REPLACE(Group_.NAME, ' LFR_ORGANIZATION', '') AS groupName
,Group_.type_ AS groupType
,Group_.friendlyURL AS groupFriendlyURL
FROM Group_
INNER JOIN Groups_Orgs ON (Groups_Orgs.groupId = Group_.groupId)
INNER JOIN Users_Orgs ON (Users_Orgs.organizationId = Groups_Orgs.organizationId)
WHERE (Group_.liveGroupId = 0)
AND (Group_.active_ = 1)
AND (Group_.liveGroupId = 0)
AND (Users_Orgs.userId = 3391488)
AND (Group_.companyId = 10132)
AND (
Group_.classNameId = 10012
OR Group_.classNameId = 10024
)
AND (Group_.parentGroupId != - 1)
AND (Group_.liveGroupId = 0)
AND (Group_.NAME != 'Control Panel')
AND (
Group_.NAME LIKE NULL
OR NULL IS NULL
)
AND (
Group_.description LIKE NULL
OR NULL IS NULL
)
AND (Group_.type_ != 4)
)
UNION
(
SELECT DISTINCT Group_.groupId AS groupId
,REPLACE(Group_.NAME, ' LFR_ORGANIZATION', '') AS groupName
,Group_.type_ AS groupType
,Group_.friendlyURL AS groupFriendlyURL
FROM Group_
INNER JOIN Groups_UserGroups ON (Groups_UserGroups.groupId = Group_.groupId)
INNER JOIN Users_UserGroups ON (Users_UserGroups.userGroupId = Groups_UserGroups.userGroupId)
WHERE (Group_.liveGroupId = 0)
AND (Group_.active_ = 1)
AND (Group_.liveGroupId = 0)
AND (Users_UserGroups.userId = 3391488)
AND (Group_.companyId = 10132)
AND (
Group_.classNameId = 10012
OR Group_.classNameId = 10024
)
AND (Group_.parentGroupId != - 1)
AND (Group_.liveGroupId = 0)
AND (Group_.NAME != 'Control Panel')
AND (
Group_.NAME LIKE NULL
OR NULL IS NULL
)
AND (
Group_.description LIKE NULL
OR NULL IS NULL
)
AND (Group_.type_ != 4)
)
ORDER BY groupName ASC
想知道为什么liferay没有缓存它....