TickThreading - concurrent entity/tile entity ticks and other optimisations

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord
output logs for errors? no, they seem not to have been created, i shall try again in the morning, and should have a full report when im not too exhausted to think.
 
Yes, currently TT modifies 26 out of 57(?) mods. I did make it also make it very clear at the top of the post that it's experimental, and to make a backup so if something goes wrong I can fix it.

Tjezee, what extra mods are you using? It's likely that some of them need patching to work with TT, so it'd be helpful to know what doesn't work.

Sorry for my delayed response.
You are 100% right for stating it is an experimental release, and I should have read better.

I'm using the Direwolf20 pack
+ Advanced Machines taken from mindcrack pack
+ Logistic Pipes 1.4.6-0.6.9.74 (github//RS485/LogisticsPipes)
+ Traincraft taken from mindcrack pack
+ Twilight forest taken from mindcrack pack
+ CreeperCollateral ( http://tinyurl.com/a5e9bxq )
+ Chargepads 2.3.0.58

Presently ( 22jan ) there are mods in the pack that have updated version. So I manually updated:
- ModularForceFieldSystem V2.2.8.3.5 from 2.1 i believe
- Portalgun 1.4.7v2 (works fine on 1.4.6)
- EE3 pre1f instead of.. e I guess
- Traincraft 3.1.13_30 instead of _10

Hope this helps.
 
Wow, that was a fast fix for the Mystcraft bug! I'll check the latest build tonight (and I'll disable world tick threading as per the wiki this time as I am using Chicken Chunks for better or worse).
 
Wow, that was a fast fix for the Mystcraft bug! I'll check the latest build tonight (and I'll disable world tick threading as per the wiki this time as I am using Chicken Chunks for better or worse).
Just wanted to update to say that v562 appears to be running well with the Direwolf20 pack for me, the Mystcraft issue appears fixed. I'll keep testing.
 
We're having a crash with #560 and MindCrack v7 + MystCraft. I have world threading turned off per the wiki, but it still seems to be some sort of issue with Chicken Chunks.

I get this exception when patching :

01-22 11:36:56 [FINE] [TickThreading] Patching iq with newInitializer(field:g,class:me.nallar.tickthreading.collections.ConcurrentLinkedQueueList)
01-22 11:36:56 [SEVERE] [TickThreading] Error patching iq with newInitializer
java.lang.RuntimeException: iq class is frozen
at javassist.CtClassType.checkModify(CtClassType.java:288)
at javassist.CtBehavior.insertAfter(CtBehavior.java:807)
at javassist.CtBehavior.insertAfter(CtBehavior.java:788)
at me.nallar.tickthreading.patcher.Patches.newInitializer(Patches.java:280)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at me.nallar.tickthreading.patcher.PatchManager$PatchMethodDescriptor.run(PatchManager.java:295)
at me.nallar.tickthreading.patcher.PatchManager$PatchMethodDescriptor.run(PatchManager.java:277)
at me.nallar.tickthreading.patcher.PatchManager.runPatches(PatchManager.java:197)
at me.nallar.tickthreading.patcher.PatchMain.patcher(PatchMain.java:81)
at me.nallar.tickthreading.patcher.PatchMain.main(PatchMain.java:29)

I can run the server and it's stable for a while, but eventually crashes.

TickThreading log: http://pastebin.com/BYvGaZ1n
Server crash log: http://pastebin.com/mN6mVg7f


Edit: Some users are reporting that their ComputerCraft computers/turtles are not running their startup programs until the UI is opened in-game, which isn't the default behavior.
 
We're having a crash with #560 and MindCrack v7 + MystCraft. I have world threading turned off per the wiki, but it still seems to be some sort of issue with Chicken Chunks.

I get this exception when patching :

01-22 11:36:56 [FINE] [TickThreading] Patching iq with newInitializer(field:g,class:me.nallar.tickthreading.collections.ConcurrentLinkedQueueList)
01-22 11:36:56 [SEVERE] [TickThreading] Error patching iq with newInitializer
java.lang.RuntimeException: iq class is frozen
at javassist.CtClassType.checkModify(CtClassType.java:288)
at javassist.CtBehavior.insertAfter(CtBehavior.java:807)
at javassist.CtBehavior.insertAfter(CtBehavior.java:788)
at me.nallar.tickthreading.patcher.Patches.newInitializer(Patches.java:280)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at me.nallar.tickthreading.patcher.PatchManager$PatchMethodDescriptor.run(PatchManager.java:295)
at me.nallar.tickthreading.patcher.PatchManager$PatchMethodDescriptor.run(PatchManager.java:277)
at me.nallar.tickthreading.patcher.PatchManager.runPatches(PatchManager.java:197)
at me.nallar.tickthreading.patcher.PatchMain.patcher(PatchMain.java:81)
at me.nallar.tickthreading.patcher.PatchMain.main(PatchMain.java:29)

I can run the server and it's stable for a while, but eventually crashes.

TickThreading log: http://pastebin.com/BYvGaZ1n
Server crash log: http://pastebin.com/mN6mVg7f


Edit: Some users are reporting that their ComputerCraft computers/turtles are not running their startup programs until the UI is opened in-game, which isn't the default behavior.
Fixed in latest. I'll look into the CC issue later.
 
I'm having problems patching. I've ran as sudo, changed the temp dir before -cp, and still this same error:

Code:
01-23 12:05:02 [SEVERE] [TickThreading] Failed to save patched classes
java.io.IOException: Couldn't rename /run/shm/ftb/mods/RedPowerMechanical-2.0pr6.zip -> /tmp/RedPowerMechanical-2.0pr6.zip6521437968790568644.tmp
    at me.nallar.tickthreading.patcher.ClassRegistry.save(ClassRegistry.java:229)
    at me.nallar.tickthreading.patcher.PatchManager.runPatches(PatchManager.java:214)
    at me.nallar.tickthreading.patcher.PatchMain.patcher(PatchMain.java:79)
    at me.nallar.tickthreading.patcher.PatchMain.main(PatchMain.java:27)
01-23 12:05:02 [SEVERE] [TickThreading] Make sure the user you are running the patcher as has access to the temporary directory.
01-23 12:05:02 [INFO] [TickThreading] Done. Press enter to exit.

I'm sure it's something simple I'm overlooking.
 
I'm having problems patching. I've ran as sudo, changed the temp dir before -cp, and still this same error:

Code:
01-23 12:05:02 [SEVERE] [TickThreading] Failed to save patched classes
java.io.IOException: Couldn't rename /run/shm/ftb/mods/RedPowerMechanical-2.0pr6.zip -> /tmp/RedPowerMechanical-2.0pr6.zip6521437968790568644.tmp
    at me.nallar.tickthreading.patcher.ClassRegistry.save(ClassRegistry.java:229)
    at me.nallar.tickthreading.patcher.PatchManager.runPatches(PatchManager.java:214)
    at me.nallar.tickthreading.patcher.PatchMain.patcher(PatchMain.java:79)
    at me.nallar.tickthreading.patcher.PatchMain.main(PatchMain.java:27)
01-23 12:05:02 [SEVERE] [TickThreading] Make sure the user you are running the patcher as has access to the temporary directory.
01-23 12:05:02 [INFO] [TickThreading] Done. Press enter to exit.

I'm sure it's something simple I'm overlooking.
Try running it as an admin. It might not have permission to access certain files/folders.
 
I'm on Linux and as I said I sudo'd it.
Set java to use another temporary directory with -Djava.io.tmpdir=/path

I've also included an explanation of how to do that in the error message, unfortunately it isn't yet in the stable-ish build.
 
Set java to use another temporary directory with -Djava.io.tmpdir=/path

I've also included an explanation of how to do that in the error message, unfortunately it isn't yet in the stable-ish build.
I've done that too, before the -cp. I've tried running the very latest builds and the recommended. With and without sudo, in /tmp or in my home directory. No luck.

Is this just patching the mindcrack.jar? Might be less of a headache if I do it locally and upload.
 
Fixed in latest. I'll look into the CC issue later.

Looks good, I checked this fix with a backup copy of my server and it seems resolved, or at least it hasn't crashed after ~3 hours.
I will need to wait for a CC fix or workaround before running it on the live server again, as Bad Things happen when Computers/Turtles don't start up properly.
 
I've done that too, before the -cp. I've tried running the very latest builds and the recommended. With and without sudo, in /tmp or in my home directory. No luck.

Is this just patching the mindcrack.jar? Might be less of a headache if I do it locally and upload.
mindcrack.jar and many mods.

You definitely changed it in PATCHME.sh? :s
 
mindcrack.jar and many mods.

You definitely changed it in PATCHME.sh? :s
Yes, also needed to chmod +x to run it (then ran with/without sudo and to /tmp and my home dir - no combination worked).

I'll patch on my desktop for now and upload the server jar and mods folder. If you have any other ideas, let me know.
 
Yes, also needed to chmod +x to run it (then ran with/without sudo and to /tmp and my home dir - no combination worked).

I'll patch on my desktop for now and upload the server jar and mods folder. If you have any other ideas, let me know.
Do you have anything with an exclusive lock on "/run/shm/ftb/mods/RedPowerMechanical-2.0pr6.zip"?

Did the error show the new temporary path when you set it?
 
The error does reflect the new path (when using the dev builds of course) if I change the temp.

I have read/write on everything in that folder.
 
Ah, there we go. I had a few open already. Maybe it was from the first failed patch and I just compounded the issue?