4 Replies Latest reply on Sep 8, 2016 11:36 AM by Scott Saniuk

    Monitoring load times for views

    Scott Saniuk

      I am trying to determine the best way that we can monitor the performance of views.  The "Stats for load times" view has this information so I am trying to model my own queries off of that, but haven't had any luck reverse-engineering it to get the numbers from that report.  I was wondering if anyone else had been able to do that successfully, or if anyone else had another method they were using to monitor the performance of views.

        • 1. Re: Monitoring load times for views
          Jeff Strauss

          what release are you on and do you have admin rights to remote into your server?  If so, you can find the source for the admin views including the "stats for load times" within the Tableau Server directories.  This is where I found it within 9.2.6, but I believe it changes a bit with Tableau 10.  It's quite helpful to use this as a starting point...

           

          G:\Tableau\Tableau Server\worker.1\wgserver\z5\WEB-INF\admin

          • 2. Re: Monitoring load times for views
            Scott Saniuk

            Thanks so I actually do have the workbook open and have the query used for the datasource.  I'll paste it below.  It seems like it should be pretty straightforward, there is a completed at field and a created at field.  But the numbers I get from that are not the values I am seeing in the report.  I've tried drilling down through the measurements but just haven't had any success. 

             

            SELECT "_users"."id" AS "id",

              "_users"."name" AS "name",

              "_users"."login_at" AS "login_at",

              "_users"."friendly_name" AS "friendly_name",

              "_users"."licensing_role_id" AS "licensing_role_id",

              "_users"."licensing_role_name" AS "licensing_role_name",

              "_users"."domain_id" AS "domain_id",

              "_users"."system_user_id" AS "system_user_id",

              "_users"."domain_name" AS "domain_name",

              "_users"."domain_short_name" AS "domain_short_name",

              "_users"."site_id" AS "site_id",

              "_http_requests"."controller" AS "controller",

              "_http_requests"."action" AS "action",

              "_http_requests"."http_referer" AS "http_referer",

              "_http_requests"."http_user_agent" AS "http_user_agent",

              "_http_requests"."http_request_uri" AS "http_request_uri",

              "_http_requests"."remote_ip" AS "remote_ip",

              "_http_requests"."created_at" AS "created_at",

              "_http_requests"."session_id" AS "session_id",

              "_http_requests"."completed_at" AS "completed_at",

              "_http_requests"."port" AS "port",

              "_http_requests"."user_id" AS "user_id",

              "_http_requests"."worker" AS "worker",

              "_http_requests"."vizql_session" AS "vizql_session",

              "_http_requests"."user_ip" AS "user_ip",

              "_http_requests"."currentsheet" AS "currentsheet",

              "_http_requests"."site_id" AS "site_id (_http_requests)",

              "_sessions"."session_id" AS "session_id (_sessions)",

              "_sessions"."updated_at" AS "updated_at",

              "_sessions"."user_id" AS "user_id (_sessions)",

              "_sessions"."user_name" AS "user_name",

              "_sessions"."system_user_id" AS "system_user_id (_sessions)",

              "_sessions"."site_id" AS "site_id (_sessions)",

              "_sites"."id" AS "id (_sites)",

              "_sites"."name" AS "name (_sites)",

              "_sites"."url_namespace" AS "url_namespace",

              "_sites"."status" AS "status",

              86400 * ("_http_requests"."completed_at" - "_http_requests"."created_at") as "LTIME"

            FROM "public"."_users" "_users"

              RIGHT JOIN "public"."_http_requests" "_http_requests" ON ("_users"."id" = "_http_requests"."user_id")

              LEFT JOIN "public"."_sessions" "_sessions" ON ("_http_requests"."session_id" = "_sessions"."session_id")

              LEFT JOIN "public"."_sites" "_sites" ON ("_http_requests"."site_id" = "_sites"."id")

            1 of 1 people found this helpful
            • 3. Re: Monitoring load times for views
              Jeff Strauss

              Yep, this looks like the SQL, but look closely at the viz itself.  Some of them have some data blending and also have some tricky table calcs.

              • 4. Re: Monitoring load times for views
                Scott Saniuk

                I think I may be getting somewhere.  Looking at the viz itself it looks like it is doing a max on the completed at - created at fields for a particular view.  So for example one particular view looks like it has 42 entries in the http_requests table, and just taking the max of all of those completed at - created at values gives me the "load time" for that particular view.   I have tried that with several and it is very close to what the reports are showing.  It doesn't seem to me like that would equal "load time" though.  But I'd probably need to better understand what all those entries were before I could be sure.

                 

                It's also possible I'm not looking at that view correctly but this is the first time I'm able to consistently match what the report is showing.