openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rick Curtis (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (OPENJPA-2427) Allow a user to easily profile SQL data
Date Tue, 17 Sep 2013 19:23:52 GMT

    [ https://issues.apache.org/jira/browse/OPENJPA-2427?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13769835#comment-13769835
] 

Rick Curtis commented on OPENJPA-2427:
--------------------------------------

When I enable my current prototype, it will dump data (in csv form) as shown before on EMF
closure(). At this point in time, it is either enabled on or off (openjpa.jdbc.SqlProfiler=true).
I know there are a number of cool things we could do if this data is exposed via a MBean,
but I don't have time to cross that bridge currently.

Any thoughts on what I have thus far?

Executions, Total Time (ns), Time per execution (ns), SQL Statement
1,184442,184442,"INSERT INTO EntityB (entityb_id, name, optLock, entityc_id) VALUES (?, ?,
?, ?)"
1,193314,193314,"INSERT INTO EntityC (entityc_id, name, optLock, entityd_id) VALUES (?, ?,
?, ?)"
1,320323,320323,"INSERT INTO EntityD (entityd_id, name, optLock, entitya_id, entityb_id) VALUES
(?, ?, ?, ?, ?)"
1,182108,182108,"INSERT INTO EntityA (entitya_id, name, optLock, entityb_id) VALUES (?, ?,
?, ?)"
4,844233,211058,"UPDATE OPENJPA_SEQUENCE_TABLE SET SEQUENCE_VALUE = ? WHERE ID = ? AND SEQUENCE_VALUE
= ?"
1,512703,512703,"SELECT t0.optLock, t1.entityd_id, t1.optLock, t2.entitya_id, t2.optLock,
t3.entityb_id, t3.optLock, t4.entityc_id, t4.optLock, t4.entityd_id, t4.name, t3.name, t2.name,
t5.entityb_id, t5.optLock, t5.entityc_id, t5.name, t1.name, t0.name FROM EntityC t0 INNER
JOIN EntityD t1 ON t0.entityd_id = t1.entityd_id LEFT OUTER JOIN EntityA t2 ON t1.entitya_id
= t2.entitya_id LEFT OUTER JOIN EntityB t5 ON t1.entityb_id = t5.entityb_id LEFT OUTER JOIN
EntityB t3 ON t2.entityb_id = t3.entityb_id LEFT OUTER JOIN EntityC t4 ON t3.entityc_id =
t4.entityc_id WHERE t0.entityc_id = ?"
1,794269,794269,"SELECT t0.optLock, t1.entityc_id, t1.optLock, t2.entityd_id, t2.optLock,
t3.entitya_id, t3.optLock, t4.entityb_id, t4.optLock, t4.entityc_id, t4.name, t3.name, t5.entityb_id,
t5.optLock, t5.entityc_id, t5.name, t2.name, t1.name, t0.name FROM EntityB t0 INNER JOIN EntityC
t1 ON t0.entityc_id = t1.entityc_id INNER JOIN EntityD t2 ON t1.entityd_id = t2.entityd_id
LEFT OUTER JOIN EntityA t3 ON t2.entitya_id = t3.entitya_id LEFT OUTER JOIN EntityB t5 ON
t2.entityb_id = t5.entityb_id LEFT OUTER JOIN EntityB t4 ON t3.entityb_id = t4.entityb_id
WHERE t0.entityb_id = ?"
4,944624,236156,"SELECT SEQUENCE_VALUE FROM OPENJPA_SEQUENCE_TABLE WHERE ID = ? FOR UPDATE"
1,411843,411843,"SELECT t0.optLock, t1.entitya_id, t1.optLock, t2.entityb_id, t2.optLock,
t3.entityc_id, t3.optLock, t4.entityd_id, t4.optLock, t4.entitya_id, t4.entityb_id, t4.name,
t3.name, t2.name, t1.name, t5.entityb_id, t5.optLock, t5.entityc_id, t5.name, t0.name FROM
EntityD t0 LEFT OUTER JOIN EntityA t1 ON t0.entitya_id = t1.entitya_id LEFT OUTER JOIN EntityB
t5 ON t0.entityb_id = t5.entityb_id LEFT OUTER JOIN EntityB t2 ON t1.entityb_id = t2.entityb_id
LEFT OUTER JOIN EntityC t3 ON t2.entityc_id = t3.entityc_id LEFT OUTER JOIN EntityD t4 ON
t3.entityd_id = t4.entityd_id WHERE t0.entityd_id = ?"
                
> Allow a user to easily profile SQL data
> ---------------------------------------
>
>                 Key: OPENJPA-2427
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-2427
>             Project: OpenJPA
>          Issue Type: Improvement
>          Components: jdbc, logging, performance
>    Affects Versions: 2.3.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>            Priority: Minor
>              Labels: perfomance
>             Fix For: 2.3.0
>
>
> With this JIRA I'd like to add a feature that would allow a user to set a property and
OpenJPA would collect some SQL statistics so that some fairly high level performance analysis
could be done.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message