Examples of consumeEvent()


Examples of com.mysql.jdbc.profiler.ProfileEventSink.consumeEvent()

        if (this.profileSql) {
            fetchEndTime = System.currentTimeMillis();

            ProfileEventSink eventSink = ProfileEventSink.getInstance(this.connection);

            eventSink.consumeEvent(new ProfilerEvent(ProfilerEvent.TYPE_QUERY,
                    "", catalog, this.connection.getId(), //$NON-NLS-1$
                    (callingStatement != null) ? callingStatement.getId() : 999,
                    rs.resultId, System.currentTimeMillis(),
                    (int) (queryEndTime - queryStartTime), null,
                    new Throwable(), profileQueryToLog));
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfileEventSink.consumeEvent()

                    (callingStatement != null) ? callingStatement.getId() : 999,
                    rs.resultId, System.currentTimeMillis(),
                    (int) (queryEndTime - queryStartTime), null,
                    new Throwable(), profileQueryToLog));

            eventSink.consumeEvent(new ProfilerEvent(ProfilerEvent.TYPE_FETCH,
                    "", catalog, this.connection.getId(), //$NON-NLS-1$
                    (callingStatement != null) ? callingStatement.getId() : 999,
                    rs.resultId, System.currentTimeMillis(),
                    (int) (fetchEndTime - fetchBeginTime), null,
                    new Throwable(), null));
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfileEventSink.consumeEvent()

                    rs.resultId, System.currentTimeMillis(),
                    (int) (fetchEndTime - fetchBeginTime), null,
                    new Throwable(), null));

            if (this.queryBadIndexUsed) {
                eventSink.consumeEvent(new ProfilerEvent(
                        ProfilerEvent.TYPE_WARN, "", catalog, //$NON-NLS-1$
                        this.connection.getId(),
                        (callingStatement != null) ? callingStatement.getId()
                                                   : 999, rs.resultId,
                        System.currentTimeMillis(),
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfileEventSink.consumeEvent()

                        Messages.getString("MysqlIO.33") //$NON-NLS-1$
                         +profileQueryToLog));
            }

            if (this.queryNoIndexUsed) {
                eventSink.consumeEvent(new ProfilerEvent(
                        ProfilerEvent.TYPE_WARN, "", catalog, //$NON-NLS-1$
                        this.connection.getId(),
                        (callingStatement != null) ? callingStatement.getId()
                                                   : 999, rs.resultId,
                        System.currentTimeMillis(),
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfileEventSink.consumeEvent()

        if (hadMore) {

          ProfileEventSink eventSink = ProfileEventSink
              .getInstance(conn);

          eventSink
              .consumeEvent(new ProfilerEvent(
                  ProfilerEvent.TYPE_WARN,
                  "", //$NON-NLS-1$
                  this.owner.owningStatement == null ? "N/A" : this.owner.owningStatement.currentCatalog, //$NON-NLS-1$
                  conn.getId(),
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfilerEventHandler.consumeEvent()

          if (hadMore) {

            ProfilerEventHandler eventSink = ProfilerEventHandlerFactory
            .getInstance(conn);

            eventSink
            .consumeEvent(new ProfilerEvent(
                ProfilerEvent.TYPE_WARN,
                "", //$NON-NLS-1$
                this.owner.owningStatement == null ? "N/A" : this.owner.owningStatement.currentCatalog, //$NON-NLS-1$
                this.owner.connectionId,
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfilerEventHandler.consumeEvent()

              Long.valueOf(queryEndTime - queryStartTime)}));
          mesgBuf.append(profileQueryToLog);

          ProfilerEventHandler eventSink = ProfilerEventHandlerFactory.getInstance(this.connection);

          eventSink.consumeEvent(new ProfilerEvent(ProfilerEvent.TYPE_SLOW_QUERY,
              "", catalog, this.connection.getId(), //$NON-NLS-1$
              (callingStatement != null) ? callingStatement.getId() : 999,
                  ((ResultSetImpl)rs).resultId, System.currentTimeMillis(),
                  (int) (queryEndTime - queryStartTime), queryTimingUnits, null,
                  LogUtils.findCallingClassAndMethod(new Throwable()), mesgBuf.toString()));
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfilerEventHandler.consumeEvent()

        if (this.logSlowQueries) {

          ProfilerEventHandler eventSink = ProfilerEventHandlerFactory.getInstance(this.connection);

          if (this.queryBadIndexUsed && this.profileSql) {
            eventSink.consumeEvent(new ProfilerEvent(
                ProfilerEvent.TYPE_SLOW_QUERY, "", catalog, //$NON-NLS-1$
                this.connection.getId(),
                (callingStatement != null) ? callingStatement.getId()
                    : 999, ((ResultSetImpl)rs).resultId,
                    System.currentTimeMillis(),
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfilerEventHandler.consumeEvent()

                    Messages.getString("MysqlIO.33") //$NON-NLS-1$
                    +profileQueryToLog));
          }

          if (this.queryNoIndexUsed && this.profileSql) {
            eventSink.consumeEvent(new ProfilerEvent(
                ProfilerEvent.TYPE_SLOW_QUERY, "", catalog, //$NON-NLS-1$
                this.connection.getId(),
                (callingStatement != null) ? callingStatement.getId()
                    : 999, ((ResultSetImpl)rs).resultId,
                    System.currentTimeMillis(),
View Full Code Here

Examples of com.mysql.jdbc.profiler.ProfilerEventHandler.consumeEvent()

                    Messages.getString("MysqlIO.35") //$NON-NLS-1$
                    +profileQueryToLog));
          }
         
          if (this.serverQueryWasSlow && this.profileSql) {
            eventSink.consumeEvent(new ProfilerEvent(
                ProfilerEvent.TYPE_SLOW_QUERY, "", catalog, //$NON-NLS-1$
                this.connection.getId(),
                (callingStatement != null) ? callingStatement.getId()
                    : 999, ((ResultSetImpl)rs).resultId,
                    System.currentTimeMillis(),
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.