aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authoronefang2019-08-06 02:28:30 +1000
committeronefang2019-08-06 02:28:30 +1000
commit46ee03817c719d035676e7611487f77863f59c6a (patch)
tree1c6ff9a0c950d09158e178b1e190de52a657e114 /OpenSim
parentBe more inclusive in the monthly online count. (diff)
downloadopensim-SC_OLD-46ee03817c719d035676e7611487f77863f59c6a.zip
opensim-SC_OLD-46ee03817c719d035676e7611487f77863f59c6a.tar.gz
opensim-SC_OLD-46ee03817c719d035676e7611487f77863f59c6a.tar.bz2
opensim-SC_OLD-46ee03817c719d035676e7611487f77863f59c6a.tar.xz
Maybe now we can properly count locals and hypergridders on the web page?
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Server/Handlers/Web/WebServerInConnector.cs11
1 files changed, 4 insertions, 7 deletions
diff --git a/OpenSim/Server/Handlers/Web/WebServerInConnector.cs b/OpenSim/Server/Handlers/Web/WebServerInConnector.cs
index 01c74fe..52ee9ae 100644
--- a/OpenSim/Server/Handlers/Web/WebServerInConnector.cs
+++ b/OpenSim/Server/Handlers/Web/WebServerInConnector.cs
@@ -118,19 +118,16 @@ namespace OpenSim.Server.Handlers.Web
118 118
119 private Hashtable WebRequestHandler(Hashtable request) 119 private Hashtable WebRequestHandler(Hashtable request)
120 { 120 {
121 long locIn = m_Database.GetCount("Presence", "RegionID != '00000000-0000-0000-0000-000000000000'"); // Locals online but not HGing. 121 long locIn = m_Database.GetCount("Presence", "RegionID != '00000000-0000-0000-0000-000000000000'"); // Locals online but not HGing, and HGers in world.
122// long HGin = m_Database.GetCount("hg_traveling_data", "GridExternalName = '" + ssi["uri"] + "'"); // HGers in world, and locals not HGing, sometimes more than once. 122 long HGin = m_Database.GetCount("Presence", "UserID NOT IN (SELECT PrincipalID FROM UserAccounts)"); // HGers in world.
123 long locOut = m_Database.GetCount("hg_traveling_data", "GridExternalName != '" + ssi["uri"] + "'"); // Locals that are HGing. 123 long locOut = m_Database.GetCount("hg_traveling_data", "GridExternalName != '" + ssi["uri"] + "'"); // Locals that are HGing.
124 Hashtable reply = new Hashtable(); 124 Hashtable reply = new Hashtable();
125 ssi["members"] = m_Database.GetCount("UserAccounts").ToString(); 125 ssi["members"] = m_Database.GetCount("UserAccounts").ToString();
126 ssi["sims"] = m_Database.GetCount("regions").ToString(); 126 ssi["sims"] = m_Database.GetCount("regions").ToString();
127 ssi["inworld"] = locIn.ToString(); 127 ssi["inworld"] = (locIn - HGin).ToString();
128 ssi["outworld"] = locOut.ToString(); 128 ssi["outworld"] = locOut.ToString();
129// ssi["hgers"] = HGin.ToString(); 129 ssi["hgers"] = HGin.ToString();
130 ssi["hgers"] = "?";
131 ssi["month"] = m_Database.GetCount("GridUser", "Login > UNIX_TIMESTAMP(FROM_UNIXTIME(UNIX_TIMESTAMP(now()) - 2419200))").ToString(); 130 ssi["month"] = m_Database.GetCount("GridUser", "Login > UNIX_TIMESTAMP(FROM_UNIXTIME(UNIX_TIMESTAMP(now()) - 2419200))").ToString();
132 // SELECT COUNT(UserID) FROM Presence WHERE LastSeen < one month ago 2017-11-28 09:01:51; This is not accurate, and never has been.
133 // SELECT COUNT(UserID) FROM {GridUser} WHERE Login > UNIX_TIMESTAMP(FROM_UNIXTIME(UNIX_TIMESTAMP(now()) - 2419200)
134 131
135 string reqpath = (string) request["uri"]; 132 string reqpath = (string) request["uri"];
136 string[] query = (string[]) request["querystringkeys"]; 133 string[] query = (string[]) request["querystringkeys"];