api.violets-purgatory.dev/static/stats/index.html

71 lines
3.5 KiB
HTML
Raw Normal View History

<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" type="text/css" href="../style.css">
<link rel="stylesheet" type="text/css" href="../subpage.css">
2024-06-26 19:18:44 -05:00
2024-06-25 18:35:58 -05:00
<script src="../jquery.js"></script>
<script src="../main.js"></script>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Violet's Purgatory</title>
<meta name="darkreader-lock">
<meta content="Stats - Violet's Purgatory" property="og:title" />
2024-06-26 19:18:44 -05:00
<meta content="This page just does a semi-intensive speed test on the site, and displays related statistics."
property="og:description" />
<meta content="https://api.violets-purgatory.dev/v1/pfp" property="og:image" />
<meta content="#a200ff" data-react-helmet="true" name="theme-color" />
</head>
2024-06-25 19:02:29 -05:00
<body>
{WEATHER_MODIFIER}
2024-06-26 19:18:44 -05:00
{TOPBAR}
<h1>Stats</h1>
<div class="mainDiv">
<p>Welcome to the stats page! This page is now "deprecated"... sorta.<br>
Feel free to read more about it at the bottom of the page.</p>
<main>
<h1>
<hr>Stats
</h1>
<br>
<ul>
<li>Page generation time: {LOAD_TIME}</li>
<li>Pregeneration time: {PREGEN_TIME}ms</li>
2024-06-27 00:55:38 -05:00
<li>Total Pregen time (all pages): {PREGEN_TOTAL}ms</li>
2024-06-26 19:18:44 -05:00
<li>Uptime: {UPTIME}</li>
<li>Last Lanyard update: {LAST_LANYARD}</li>
<li>Last Pregeneration: {LAST_PREGEN}</li>
<li>Server connected to API: {API_CONNECTED}</li>
<li>Javascript Loaded/Enabled: <span id="jsEnabled">false</span></li>
<li>Client connected to API: <span id="apiConnected">false</span></li>
</ul>
</main>
<h2><hr>Why does this page exist?</h2>
<p>Originally, the stats page served the purpose of putting heavy load on the server for testing page generation times. This had a number of problems, though:</p>
<ol>
<li>Anyone could freely use this page and put the server under heavy load, with no limits, including malicious actors.</li>
<li>The page itself failed to serve its original function, as it was not an accurate display of what kind of loads or processing would be caused by a <em>real</em> page on the site, as it did not contain things such as page embeds, and otherwise had a lack of content.</li>
2024-06-26 19:18:44 -05:00
<li>It didn't provide any information the main page did not.</li>
</ol>
<p>The list could probably go on and on, but by now I suspect you begin to get the idea. So, overall, this page is pretty useless :3</p>
<h2><hr>Why does it still exist then?</h2>
<p>Mainly for the aforementioned <a>page embeds</a>. The main page, and others, can embed the stats page on themselves to easily collect statistics! Currently, this is only used on the main page but, the code is still more organized and much more modular than if I had smacked the code into the main page and called it a day.</p>
<h2><hr>The future of the stats page</h2>
<p>I have a few different ideas at the moment, one of them being an actual stats monitor. E.G, I could record stats such as:</p>
<ul>
2024-06-26 19:18:44 -05:00
<li>Programs connected to the api (This would includes sites AND users)</li>
<li>Average CPU, RAM, etc loads</li>
<li>Uptime monitor (Would probably pull from something like Uptime Kuma)</li>
</ul>
2024-06-26 19:18:44 -05:00
<p>But, only time can tell :)</p>
</div>
</body>
</html>