[Bug 2041] New: Improve ThreadTableController.ThreadTableControllerAction.run()

bugzilla-daemon at icedtea.classpath.org bugzilla-daemon at icedtea.classpath.org
Fri Oct 17 17:06:02 UTC 2014


            Bug ID: 2041
           Summary: Improve
           Product: Thermostat
           Version: hg
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P5
         Component: Thermostat
          Assignee: unassigned at icedtea.classpath.org
          Reporter: sgehwolf at redhat.com
                CC: thermostat at icedtea.classpath.org
            Blocks: 2038

ThreadTableController.ThreadTableControllerAction.run(): performs the following
in a timer (every second):
 - ThreadDao.getThreadStateTotalTimeRange(): performs 1 query
 - ThreadCollector.getThreads(): performs 1 query
 - For each thread (N) calls: ThreadDao.getThreadStates(): n queries.

Thus, 1 + 1 + n = O(n + 2) ops every second.

We should consider implementing projection + the 'in' operator in order to fold
those n queries into one.

QUERY thread-states([state]) WHERE 'vm-id' = ?s AND 'thread-id' IN ?s[

Projects on the state field and returns a set of size len('?s[').

You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20141017/ac733130/attachment-0001.html>

More information about the distro-pkg-dev mailing list