在OBIEE Weblogic中执行时查询比在数据库上花费更多时间

时间:2016-04-04 11:51:36

标签: oracle obiee

我刚刚开始研究Oracle BI,我有一个场景,加载仪表板需要很长时间。起初我认为这种缓慢性能背后的罪魁祸首是数据库查询。但是当查看日志时,在数据库(MDS)上执行几秒钟的查询在Weblogics中显示为6秒作为执行时间。

下面是一个简单查询的日志,它在Weblogics上执行需要将近6秒,并且在数据库上执行时需要897毫秒。

[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-0] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:3] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] ############################################## [[
-------------------- SQL Request, logical request hash:
44507272
SET VARIABLE QUERY_SRC_CD='ValuePrompt';SELECT "Project"."Project Type#1" saw_0 FROM "PLM PPM - Project Summary" ORDER BY saw_0
FETCH FIRST 65001 ROWS ONLY


]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-23] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:3] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- General Query Info: [[
Repository: Star, Subject Area: PLMA, Presentation: PLM PPM - Project Summary

]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-2] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:3] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Logical Request (before navigation): [[

RqList  distinct 
    Dim - Project.Project Type as c1 GB
OrderBy: c1 asc

]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-48] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:5] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- The logical query block fail to hits or seed the cache in subrequest level due to   [[
 only one subrequest 


]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-51] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:5] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- The logical plan contains non-cacheable node, plan  [[
RqList <<82402988>> distinct 
    D1.c1 as c1 GB
Child Nodes (RqJoinSpec): <<82403017>>
    RqJoinNode <<82403016>> []
        (
            RqList <<82402995>>
                Dim_PPM_PROJECT_D.PRJ_USRDEF_LIST0 as c1 GB
            Child Nodes (RqJoinSpec): <<82403009>>
                RqJoinNode <<82403008>> []
                    PPM_PROJECT_D AS Dim_PPM_PROJECT_D
            DetailFilter: Dim_PPM_PROJECT_D.DELETE_FLG = 0
        ) as D1
OrderBy: c1 asc
node cache seed not inserted  due to multiple plan not cacheable

]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-50] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:5] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- The logical query seed the plan cache [[
plan 
RqList <<82403049>> [for database 3023:57:PLMA,57] distinct  /* FETCH FIRST 65001 ROWS ONLY */ 
    Dim_PPM_PROJECT_D.PRJ_USRDEF_LIST0 as c1 GB [for database 3023:57,57]
Child Nodes (RqJoinSpec): <<82403053>> [for database 3023:57:PLMA,57]
    RqJoinNode <<82403054>> []
        PPM_PROJECT_D AS Dim_PPM_PROJECT_D
DetailFilter: Dim_PPM_PROJECT_D.DELETE_FLG = 0 [for database 3023:57]
OrderBy: c1 asc [for database 3023:57,57]

]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-16] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:5] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Execution plan: [[

RqList <<82402995>> [for database 3023:57:PLMA,57] distinct  /* FETCH FIRST 65001 ROWS ONLY */ 
    Dim_PPM_PROJECT_D.PRJ_USRDEF_LIST0 as c1 GB [for database 3023:57,57]
Child Nodes (RqJoinSpec): <<82403009>> [for database 3023:57:PLMA,57]
    RqJoinNode <<82403008>> []
        PPM_PROJECT_D AS Dim_PPM_PROJECT_D
DetailFilter: Dim_PPM_PROJECT_D.DELETE_FLG = 0 [for database 3023:57]
OrderBy: c1 asc [for database 3023:57,57]

]]
[2016-04-04T05:11:58.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-18] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:9:5] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Sending query to database named PLMA (id: <<82402995>>), connection pool named Connection Pool, logical request hash 44507272, physical request hash f82d8b03: [[

select D1.c1 as c1 from ( select distinct T286689.PRJ_USRDEF_LIST0 as c1
from 
     PPM_PROJECT_D T286689 /* Dim_PPM_PROJECT_D */ 
where  ( T286689.DELETE_FLG = 0 ) 
order by c1 ) D1 where rownum <= 65001

]]
[2016-04-04T05:12:04.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-34] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:11] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Query Status: Successful Completion [[

]]
[2016-04-04T05:12:04.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-26] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:11] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Rows 5, bytes 20060 retrieved from database query id: <<82402995>> [[

]]
[2016-04-04T05:12:04.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-28] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:11] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Physical query response time 5 (seconds), id <<82402995>> [[

]]
[2016-04-04T05:12:04.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-29] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:11] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Physical Query Summary Stats: Number of physical queries 1, Cumulative time 5, DB-connect time 0 (seconds) [[

]]
[2016-04-04T05:12:04.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-24] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:11] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Rows returned to Client 5 [[

]]
[2016-04-04T05:12:04.000-07:00] [OracleBIServerComponent] [TRACE:4] [USER-33] [] [ecid: 77bb740f357d872f:52e5f112:1522a219085:-8000-00000000004961ca,0:1:11] [tid: dbf7c700] [requestid: 157d0024] [sessionid: 157d0000] [username: weblogic] -------------------- Logical Query Summary Stats: Elapsed time 6, Response time 5, Compilation time 0 (seconds) [[

]] 

有谁能告诉我如何找到这个问题的根本原因。

1 个答案:

答案 0 :(得分:1)

首先是基础知识,您如何衡量查询所需的时间?您是否正在使用计时器(或萤火虫等)并测量自打开仪表板页面以来显示结果所需的时间? 或者您是否激活用户跟踪,执行时间是使用情况跟踪表中的数据库时间? 如果它是第一个选项,那么我建议激活使用情况跟踪并查看执行时间的花费。也许OBIEE服务器和数据库之间或服务器和分析之间存在延迟...... 为了更好地理解OBIEE性能,我建议在Rittman Mead博客上发布Robin Moffat的系列博客文章。它有很多要消化的东西,而且你的问题没有简单的答案,但是如果你和obiee一起工作,你最好学习组件以及每个组件的工作原理。 此致