You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Many Folia APIs were ported to Paper in #9360 . However, Server#isOnGlobalTickThread was not ported. This makes some uses of the Folia API nontransferrable to Paper.
Describe the solution you'd like.
I would like for a isOnGlobalTickThread method to be added to Paper. However, there is one caveat: the location of the method. Rather than port Server#isOnGlobalTickThread equivalently, the method might instead be placed in the global scheduler API.
Here's why. I suspect that PaperMC maintainers consider Folia APIs, when ported to Paper, should be clearly separate from standard scheduling APIs, based on this remark:
Docs might need slight adjustment first to tell people they should only really use the schedulers when also targetting Folia #9360
Thus, adding Server#isOnGlobalTickThread directly to Paper might cause some confusion vis-a-vis standard scheduling methods such as Server#IsPrimaryThread. Users might wonder why both exist in tandem. Perhaps, therefore, the isOnGlobalTickThread method belongs in the global scheduler API, not org.bukkit.Server. In other words, the method GlobalRegionScheduler#isOnGlobalTickThread should be added to Paper. I personally agree with this opinion, since isOnGlobalTickThread is specifically related to the concept of the global region.
It would make sense therefore, also, for Folia to add a GlobalRegionScheduler#isOnGlobalTickThread. I believe this method was added to Server following the precedent of isPrimaryThread; however, there too I question the location of the method, although it is legacy, and cannot easily be changed.
Describe alternatives you've considered.
Move Server#isOnGlobalTickThread directly to Paper, in the Server class. This may lead to confusion for API users not acquainted with Folia nor having any need of being acquainted with Folia.
This discussion was converted from issue #9459 on April 28, 2024 17:48.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Is your feature request related to a problem?
Many Folia APIs were ported to Paper in #9360 . However,
Server#isOnGlobalTickThread
was not ported. This makes some uses of the Folia API nontransferrable to Paper.Describe the solution you'd like.
I would like for a
isOnGlobalTickThread
method to be added to Paper. However, there is one caveat: the location of the method. Rather than portServer#isOnGlobalTickThread
equivalently, the method might instead be placed in the global scheduler API.Here's why. I suspect that PaperMC maintainers consider Folia APIs, when ported to Paper, should be clearly separate from standard scheduling APIs, based on this remark:
Thus, adding
Server#isOnGlobalTickThread
directly to Paper might cause some confusion vis-a-vis standard scheduling methods such asServer#IsPrimaryThread
. Users might wonder why both exist in tandem. Perhaps, therefore, theisOnGlobalTickThread
method belongs in the global scheduler API, not org.bukkit.Server. In other words, the methodGlobalRegionScheduler#isOnGlobalTickThread
should be added to Paper. I personally agree with this opinion, sinceisOnGlobalTickThread
is specifically related to the concept of the global region.It would make sense therefore, also, for Folia to add a
GlobalRegionScheduler#isOnGlobalTickThread
. I believe this method was added toServer
following the precedent ofisPrimaryThread
; however, there too I question the location of the method, although it is legacy, and cannot easily be changed.Describe alternatives you've considered.
Move
Server#isOnGlobalTickThread
directly to Paper, in theServer
class. This may lead to confusion for API users not acquainted with Folia nor having any need of being acquainted with Folia.Do nothing.
Other
No response
Beta Was this translation helpful? Give feedback.
All reactions