287 Commits

Author SHA1 Message Date
pmmp-admin-bot[bot]
950fb48bcb Merge 'minor-next' into 'major-next'
Automatic merge performed by: https://github.com/pmmp/RestrictedActions/actions/runs/15523860509
2025-06-09 00:03:27 +00:00
Dylan K. Taylor
48b80ecf78
Change crashdump file name format
this has bothered me for ages since it sorts into some absurd order by default due to the name starting with the day of the week.

this way it'll ensure that the files are always alphanumerically ordered, which means the most recent crashdump should always be
at the bottom.
2025-06-08 19:01:11 +01:00
Dylan K. Taylor
c637d852e2
Merge branch 'minor-next' into major-next 2025-02-18 01:26:08 +00:00
Dylan K. Taylor
77be5f8e25
Update PHPStan 2025-02-17 17:51:39 +00:00
Dylan K. Taylor
694aa17cc9
Merge branch 'minor-next' into major-next 2025-02-16 23:18:56 +00:00
Dylan K. Taylor
03e4b53ac4
BedrockDataFiles: added constants for folders as well as files
we probably should have it recurse too, but this is an easy win.
2025-02-16 20:57:16 +00:00
Dylan K. Taylor
02ac512b4e
Merge branch 'minor-next' into major-next 2025-01-08 15:25:12 +00:00
Dylan K. Taylor
28d31c97f8
Server: fixup PHPStan 2.x reported issues 2025-01-07 22:05:01 +00:00
Doge
0dae786a21
feat(Server): add a setter for maxPlayers (#6261) 2024-12-01 20:24:50 +00:00
Dylan K. Taylor
02d181d0c8
Merge branch 'minor-next' into major-next 2024-12-01 15:02:36 +00:00
Dylan T.
61560ec375
Support for collecting timings from threads, and implement async task timings (#6333)
The following callbacks can now be registered in timings, to allow threads to be notified of these events:
- Turning on/off (`TimingsHandler::getToggleCallbacks()->add(...)`)
- Reset (`TimingsHandler::getReloadCallbacks()->add(...)`)
- Collect (`TimingsHandler::getCollectCallbacks()->add(...)`)

Collect callbacks must return `list<Promise>`. The promises must be `resolve()`d with `list<string>` of printed timings records, as returned by `TimingsHandler::printCurrentThreadRecords()`. It's recommended to use 1 promise per thread.

A timings report will be produced once all promises have been resolved.

This system is used internally to collect timings for async tasks (closes #6166).

For timings viewer developers:
Timings format version has been bumped to 3 to accommodate this change. Timings groups should now include a `ThreadId`  at the end of timings group names to ensure that their record IDs are segregated correctly, as they could otherwise conflict between threads. The main thread is not required to specify a thread ID. See pmmp/timings@13cefa6279 for implementation examples.

New PHPStan error is caused by phpstan/phpstan#10924
2024-12-01 14:49:27 +00:00
Dylan K. Taylor
15eaf67a0c
Merge branch 'minor-next' into major-next 2024-11-25 14:36:25 +00:00
Dylan K. Taylor
5325ecee37
Deal with a whole lot of PHPStan suppressed key casting errors
closes #6534
2024-11-25 14:30:58 +00:00
Dylan K. Taylor
12179aa03a
Merge branch 'minor-next' into major-next 2024-05-06 15:42:49 +01:00
Dylan K. Taylor
ed158f8a1b
Server: include uptime in crash restart throttle message
this makes it clearer why the wait duration is chosen instead of it looking random.
2024-04-29 16:36:14 +01:00
Dylan K. Taylor
e781c64540
Merge branch 'minor-next' into major-next 2024-03-14 12:47:18 +00:00
Dylan K. Taylor
efd113bdc8
Integrate pmmp/BedrockProtocol@65b3d0b341 2024-02-26 17:09:09 +00:00
Dylan K. Taylor
644693ffee
Merge branch 'minor-next' into major-next 2024-02-12 11:55:36 +00:00
Dylan K. Taylor
fe06bfcda0
Import alias cleanup courtesy of newest php-cs-fixer 2024-02-07 12:50:37 +00:00
Dylan K. Taylor
6492e7f4a2
1.20.60 support 2024-02-07 12:33:44 +00:00
Dylan K. Taylor
4d337add7c
Merge branch 'minor-next' into major-next 2023-12-14 14:03:09 +00:00
Dylan K. Taylor
bc07778434
Avoid unnecessary CompressBatchPromise allocations for sync-prepared batches
Sync-prepared batches account for the vast majority of outbound packets. Avoiding these useless objects further reduces the overhead of zero-compressed packets, as the creation of these objects is a significant part of the overhead for these cases.

closes #6157
2023-11-17 12:35:42 +00:00
Dylan K. Taylor
519784460f
Merge branch 'stable' into minor-next 2023-11-17 12:04:10 +00:00
Dylan K. Taylor
a25597ca30
Server: updated documentation for prepareBatch() 2023-11-17 12:01:19 +00:00
Dylan K. Taylor
e5c96faa4b
Server: clean up inconsistent getter vs property access usages 2023-11-14 12:59:05 +00:00
Dylan K. Taylor
77590fb63a
Server: fixed prepareBatch() not being marked as internal 2023-11-13 11:12:12 +00:00
Dylan K. Taylor
54694df48c
Merge branch 'minor-next' into major-next 2023-11-01 16:39:55 +00:00
Dylan K. Taylor
9832fe899f
Merge branch 'stable' into minor-next 2023-11-01 16:39:44 +00:00
Dylan K. Taylor
e6e2c54ec9
Fixed various reentrant-unsafe 2D array element unsets (similar to previous commit)
this pattern was used in various places
2023-11-01 16:28:59 +00:00
Dylan K. Taylor
d565be93a8
Merge branch 'minor-next' into major-next 2023-10-24 11:57:30 +01:00
Dylan K. Taylor
8491d3c6c0
Merge branch 'stable' into minor-next 2023-10-24 11:56:51 +01:00
Dylan K. Taylor
932116fa52
Server: re-added @see reference that somehow got deleted
this is useful when clicking through references in the call stack.
2023-10-18 10:23:02 +01:00
Dylan K. Taylor
a4f3476190
Merge branch 'minor-next' into major-next 2023-09-08 11:22:44 +01:00
Dylan K. Taylor
7ce33d9375
Migrate final remaining EnumTrait users to native enums 2023-09-08 10:34:12 +01:00
Dylan K. Taylor
4dc9d696d0
Merge branch 'minor-next' into major-next 2023-09-06 13:03:51 +01:00
Dylan K. Taylor
5a010e8213
Merge branch 'minor-next' into stable 2023-09-06 12:06:15 +01:00
Dylan K. Taylor
b160b87e24
Server: stop discriminating against crashes caused by folder plugins
these are the de facto standard, which means that a lot of crashes aren't getting reported from servers with folder plugins.
2023-09-06 11:34:03 +01:00
Dylan K. Taylor
31d8cc1cb5
Generate and use constants for pocketmine.yml constant names
a couple of usages of properties that no longer exist couldn't be migrated.
in addition, this revealed a couple of dead properties in the default file.

this is not an ideal solution (I'd much rather model the configs using classes and map them) but in the absence of a good and reliable library to do that, this is the next best thing.
2023-08-25 13:23:38 +01:00
Dylan K. Taylor
d1a7c1d453
Constify server.properties references 2023-08-25 12:49:39 +01:00
Dylan K. Taylor
9997b614bc
Merge branch 'minor-next' into major-next 2023-08-01 12:53:53 +01:00
Dylan T
82a5ea9ed3
Allow thread errors and their traces to be properly recorded in crashdumps (#5910)
until now, any thread crash would show as a generic crash since we aren't able to get the trace from the crashed thread directly. This uses some dirty tricks to export a partially serialized stack trace to the main thread, where it can be written into a crashdump.
This enables us to see proper crash information for async tasks in the crash archive (finally!!!) as well as being able to capture RakLib errors properly.
2023-07-26 16:26:03 +01:00
Dylan K. Taylor
89f8f421a6
Server: stop discriminating against folder plugins when generating crashdumps
in PM6, non-development plugins may appear in folder form.
2023-07-26 10:47:39 +01:00
Dylan K. Taylor
3c0e7ae492
Merge branch 'minor-next' into major-next 2023-07-24 12:07:55 +01:00
Dylan K. Taylor
3afe3b7f44
Merge branch 'stable' into minor-next 2023-07-24 12:02:24 +01:00
Dylan K. Taylor
9ef835c82d
Merge remote-tracking branch 'origin/legacy/pm4' into stable 2023-07-21 11:07:32 +01:00
Dylan K. Taylor
9b43ddecbd
Drop usages of Process:kill() with subprocesses parameter
we don't need this any more with console reader improvements, and this was not working correctly anyway.

closes #5234
2023-07-20 17:10:39 +01:00
Dylan K. Taylor
62465fa676
Integrate FolderPluginLoader
the motivation for this is described in #5917

a new version of DevTools will be required, as the current version will cause the server to abort during startup with this change due to duplicated plugin loading.
2023-07-19 18:05:41 +01:00
Dylan K. Taylor
914dd90b3d
Use first-class closures in more places 2023-07-19 13:56:48 +01:00
Dylan K. Taylor
f4dab17a1b
Added deprecation notices 2023-07-01 10:29:14 +01:00
Dylan K. Taylor
4aba9d9725
Absorb pocketmine/classloader into the core code
the only use for this class is to facilitate random runtime plugin loading, and it's not complete even for that purpose.

Since nothing but PM uses pocketmine/classloader anyway, it doesn't make sense to have it outside the core. As with LogPthreads, it's just adding more maintenance work.
2023-05-22 22:52:48 +01:00