[Bug]: Integrated Crafting in 1.16.5 causes server to freeze when autocrafting. Cross mod interaction possible.
See original GitHub issueIssue type:
- 🐛 Bug
Short description:
AutoCraft in Integrated Dynamics creates a deadlock on the server side at this line Or this line Also, you can checkout All stacks from the JVM. Something wrong with this, when you try to get from CacheStorage:
private final LoadingCache<PartPos, IIngredientComponentStorage<T, M>> cacheStorage;
...
this.cacheStorage = CacheBuilder.newBuilder()
.build(new CacheLoader<PartPos, IIngredientComponentStorage<T, M>>() {
public IIngredientComponentStorage<T, M> load(PartPos pos) {
IIngredientComponentStorage<T, M> storage = getPositionedStorageUnsafe(pos);
return storage == null ? new IngredientComponentStorageEmpty<>(getComponent()) : storage;
}
});
...
this.cacheStorage.get(pos);
I was able to reproduce it only in the OceanBlock pack.
With this mods in list I can’t reproduce it:
Integrated-Tunnels-Compat 1.8.9
IntegratedTerminals 1.2.11
IntegratedTerminalsCompat 1.2.11
IntegratedDynamics 1.10.6
IntegratedDynamics-Compat 1.10.6
Integrated NBT
IntegratedCrafting 1.0.20
Cyclops Core 1.12.1
CommonCapabilities 2.8.0
Lollipop 3.2.9
Krate 0.1.4
CreativeCore 2.0.0
JEI 7.7.1.128
Forge 36.2.20
CoFH core 1.4.0.6
JEI Integration 7.0.1.15
TrayLauncher 1.0
CodeChicken Lib 4.0.5.438
ConnectedTexturesMod MC1.16.1-1.1.2.6
CraftingTweaks 12.2.1
Steps to reproduce the problem:
I use FTB OceanBlock, I tried to reproduce it with only IntegratedDynamics and Krate and the bug does not occur. Here are the steps to reproduce:
- Setup 2 chests, 1 crafting table.
- Connect chests with tunnels and item interface
- Connect crafting table with crafting interface
- Create recipes for “Krates” (again, it shouldn’t be related only for them, but haven’t tried yet)
- Start auto craft for any of them.
- Sometimes it goes stuck not after the first try, but it could take 1-2-5-10 times before the deadlock.
Expected behavior:
To see the Screen with Crafting Plan, not the server DeadLock
Versions:
- Minecraft:
1.16.5
- Forge:
36.2.20
- CyclopsCore:
CyclopsCore-1.16.5-1.12.1.jar
- IntegratedDynamics:
IntegratedDynamics-1.16.5-1.10.6.jar
- IntegratedCrafting:
IntegratedCrafting-1.16.5-1.0.20.jar
- IntegratedTerminals:
IntegratedTerminals-1.16.5-1.2.11.jar
- IntegratedTunnels:
IntegratedTunnels-1.16.5-1.8.9.jar
Additional information:
https://youtu.be/s4K5ZOwFa6I?t=280 => Relayed from FTBTeam/FTB-Modpack-Issues#520. https://youtu.be/UwVeBYYL2QA?t=150 => Relayed from FTBTeam/FTB-Modpack-Issues#512.
https://gist.github.com/libbkmz/3820ecd8450ffc11d929b23909d5ebbe - Stack trace captured after getting deadlock via jstack PID
.
Original error on #1111 linked from FTBTeam/FTB-Modpack-Issues#346.
The user from the current issue this is being reported from, on FTB Modpack Issues, left this message:
What should I do in the meanwhile? I can help to do something, to speed up it.
Btw, found that Guava's Cache is prone to deadlocks. =\
They can interact in here to help you, or if you have any questions feel free to ask me directly. I can also reproduce the issue upon request, or if you need to pin down a potential problem – I’m available.
Thank you very much for your time!
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (5 by maintainers)
Ok, I’ll probably just disable multithreaded crafting planning by default, it’s causing too many issues that are not easily fixable in MC’s architecture.
@Raidobw2 @libbkmz Could you check if setting
craftingPlannerEnableMultithreading
to false in the Integrated Terminals config solves all your problems? Hopefully, it should not result in too large a performance degradation.If someone confirms that this works well, I’ll make
craftingPlannerEnableMultithreading
default to false.Yeah, looks like it’s working with that setting disabled.