Skip to content

Commit 377fe92

Browse files
committed
Don't try to render 200 lines per second in the console... 💣
Corrects a math mistake on my end, and makes the console speed configurable again. Now sends 50 messages per second. Console will notify when being throttled, and refreshing the page will clear the queue if necessary.
1 parent d46eac9 commit 377fe92

File tree

4 files changed

+22
-2
lines changed

4 files changed

+22
-2
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ This file is a running track of new features and fixes to each version of the pa
33

44
This project follows [Semantic Versioning](http://semver.org) guidelines.
55

6+
## v0.6.0-pre.7 (Courageous Carniadactylus)
7+
### Fixed
8+
* `[pre.6]` — Addresses misconfigured console queue that was still sending data way to quickly thus causing the console to explode on some devices when large amounts of data were sent.
9+
610
## v0.6.0-pre.6 (Courageous Carniadactylus)
711
### Fixed
812
* `[pre.5]` — Console based server rebuild tool now actually rebuilds the servers with the correct information.

app/Http/Controllers/Server/ServerController.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,10 @@ public function getIndex(Request $request, $uuid)
6262
'saveFile' => route('server.files.save', $server->uuidShort),
6363
'csrfToken' => csrf_token(),
6464
],
65+
'config' => [
66+
'console_count' => config('pterodactyl.console.count'),
67+
'console_freq' => config('pterodactyl.console.freq'),
68+
],
6569
]);
6670

6771
return view('server.index', [

config/pterodactyl.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,18 @@
5555
'high' => env('QUEUE_HIGH', 'high'),
5656
],
5757

58+
/*
59+
|--------------------------------------------------------------------------
60+
| Console Configuration
61+
|--------------------------------------------------------------------------
62+
|
63+
| Configure the speed at which data is rendered to the console.
64+
*/
65+
'console' => [
66+
'count' => env('CONSOLE_PUSH_COUNT', 10),
67+
'frequency' => env('CONSOLE_PUSH_FREQ', 200),
68+
],
69+
5870
/*
5971
|--------------------------------------------------------------------------
6072
| Task Timers

public/themes/pterodactyl/js/frontend/console.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
// SOFTWARE.
2020

2121
var Console = (function () {
22-
var CONSOLE_PUSH_COUNT = 50;
23-
var CONSOLE_PUSH_FREQ = 200;
22+
var CONSOLE_PUSH_COUNT = Pterodactyl.config.console_count;
23+
var CONSOLE_PUSH_FREQ = Pterodactyl.config.console_freq;
2424

2525
var terminalQueue;
2626
var terminal;

0 commit comments

Comments
 (0)