Added a UserScript to automatically log in to clarity
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
// ==UserScript==
|
||||
// @name AutoPerfReports
|
||||
// @namespace http://tampermonkey.net/
|
||||
// @version 0.4
|
||||
// @version 0.6
|
||||
// @description Automatically pull data out of Riverbed for the previous day.
|
||||
// @author joe.tretter@kcc.com
|
||||
// @match https://ttw.gws.kcc.com/*
|
||||
@@ -17,7 +17,7 @@
|
||||
simulateDate.setDate(today.getDate() - 1);
|
||||
|
||||
// To overwrite the simulate date uncomment the below and change the date (remember that the month starts at 0!
|
||||
//simulateDate = new Date(2018,11,1);
|
||||
//simulateDate = new Date(2019,1,17);
|
||||
|
||||
simulateDate = new Date(simulateDate.getFullYear(), simulateDate.getMonth(), simulateDate.getDate());
|
||||
|
||||
@@ -80,20 +80,22 @@
|
||||
let myInterval;
|
||||
return new Promise((resolve, reject) => {
|
||||
myInterval = window.setInterval(() => {
|
||||
if (document.getElementsByClassName("gwt-SuggestBox EKM0XQC-tb-f").length === 1) {
|
||||
if (document.getElementsByClassName("gwt-SuggestBox OT335KC-ub-f").length === 1) {
|
||||
clearInterval(myInterval);
|
||||
// even if the screen is loaded, if we are too fast it will be too fast for the javascript of the page...
|
||||
window.setTimeout(function(){
|
||||
window.document.title="[RiverRobot] Executing Query " + theQuery;
|
||||
console.log("ExecQuery ",theQuery);
|
||||
let theSearchField = document.getElementsByClassName("gwt-SuggestBox EKM0XQC-tb-f")[0];
|
||||
|
||||
let theSearchField = document.getElementsByClassName("gwt-SuggestBox OT335KC-ub-f")[0];
|
||||
theSearchField.value = theQuery;
|
||||
|
||||
let theSearchButton = document.getElementsByClassName("gwt-Button EKM0XQC-e-d")[0];
|
||||
let theNumResultsField = document.getElementsByClassName("gwt-TextBox OT335KC-vb-f")[0];
|
||||
theNumResultsField.value = 99999;
|
||||
|
||||
let theSearchButton = document.getElementsByClassName("gwt-Button OT335KC-e-e")[0];
|
||||
theSearchButton.click();
|
||||
resolve();
|
||||
},5000);
|
||||
},15000); // that's a bit lazy - I just assume it's ready in 15 sec... otherwise I had to poll the search button till it's clickable.
|
||||
} else {
|
||||
window.document.title="[RiverRobot] Waiting for Query field " + theQuery;
|
||||
console.log("Waiting for Query field",theQuery);
|
||||
@@ -152,41 +154,67 @@
|
||||
|
||||
let allQueriesAndNames = [
|
||||
{
|
||||
name: 'PrmMainBo.Save',
|
||||
query: " ! ( class.method = 'Cas.BusinessLogic.Clc.ClcCalculationEngineBo.Activate' ) and ! ( class.method = 'Cas.BusinessLogic.Prm.PrmMainBo.Copy' ) and ( class.method = 'Cas.BusinessLogic.Prm.PrmMainBo.Save' ) and ( instance = 'ACNCASWebSite#LAOProdServer' ) | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmMainBo.Save -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PayMainBo.Save',
|
||||
query: " class.method = 'Cas.BusinessLogic.Pay.PayMainBo.Save' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Pay.PayMainBo.Save -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'ClcCalculationBo.Calculation',
|
||||
query: "class.method = 'Cas.BusinessLogic.Clc.ClcCalculationEngineBo.Calculation' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Clc.ClcCalculationEngineBo.Calculation -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'ClcCalculationEngineBo.UpdateSummaryForPeriod',
|
||||
query: "class.method = 'Cas.BusinessLogic.Clc.ClcCalculationEngineBo.UpdateSummaryForPeriod' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Clc.ClcCalculationEngineBo.UpdateSummaryForPeriod -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
query: "class.method = 'Cas.BusinessLogic.Clc.ClcCalculationEngineBo.UpdateSummaryForPeriod' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Clc.ClcCalculationEngineBo.UpdateSummaryForPeriod -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmTacticView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmTacticView.GetView' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmTacticView.GetView -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmTacticView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmTacticView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmTacticView.AddViewItem',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmTacticView.AddViewItem' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmTacticView.AddViewItem -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmTacticView.AddViewItem' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmTacticView.AddViewItem -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmProductAllView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmProductAllView.GetView' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmProductAllView.GetView -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmProductAllView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmProductAllView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmProductAllView.AddViewItem',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmProductAllView.AddViewItem' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmProductAllView.AddViewItem -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmProductAllView.AddViewItem' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmProductAllView.AddViewItem -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'BpaMyPaymentMassCreationView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Bpa.BpaMyPaymentMassCreationView.GetView' and instance = 'ACNCASWebSite#LAOProdServer' | calls -type class.method -class.method Cas.BusinessLogic.Bpa.BpaMyPaymentMassCreationView.GetView -include_call_count -visualization transactions -limit 10000 -sort_by total_duration"
|
||||
query: "class.method = 'Cas.BusinessLogic.Bpa.BpaMyPaymentMassCreationView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Bpa.BpaMyPaymentMassCreationView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PayMainBo.Save',
|
||||
query: "class.method = 'Cas.BusinessLogic.Pay.PayMainBo.Save' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Pay.PayMainBo.Save -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmMainBo.Copy',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmMainBo.Copy' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmMainBo.Copy -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmTacticProductAllView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmTacticProductAllView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmTacticProductAllView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmMainView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmMainView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmMainView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmMyTacticHistoryView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmMyTacticHistoryView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmMyTacticHistoryView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmFundingSourcesView.GetView',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmFundingSourcesView.GetView' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmFundingSourcesView.GetView -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmMainBo.AddTacticByCopy',
|
||||
query: "class.method = 'Cas.BusinessLogic.Prm.PrmMainBo.AddTacticByCopy' AND server = 'ustca089.kcc.com' | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmMainBo.AddTacticByCopy -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'ClcCalculationBo.Calculation',
|
||||
query: "class.method = 'Cas.BusinessLogic.Clc.ClcCalculationEngineBo.Calculation' AND server = 'ustca089.kcc.com' AND transactiontype = 'accenture_businesslogic' | calls -type class.method -class.method Cas.BusinessLogic.Clc.ClcCalculationEngineBo.Calculation -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
},
|
||||
{
|
||||
name: 'PrmMainBo.Save',
|
||||
query: " ! ( class.method = 'Cas.BusinessLogic.Clc.ClcCalculationEngineBo.Activate' ) and ! ( class.method = 'Cas.BusinessLogic.Prm.PrmMainBo.Copy' ) and ( class.method = 'Cas.BusinessLogic.Prm.PrmMainBo.Save' ) | calls -type class.method -class.method Cas.BusinessLogic.Prm.PrmMainBo.Save -include_call_count -visualization transactions -limit 100000 -sort_by total_duration"
|
||||
}
|
||||
|
||||
|
||||
];
|
||||
|
||||
// Password is encrypted with XOR to preent "accidental" revelation
|
||||
|
||||
Reference in New Issue
Block a user