The server has not responded for 10 seconds!$$Lambda$5140/341524836.apply(Unknown Source)

Hello! Could someone help me out?
I’ve been having lag spikes and “crashes” (not really a crash just the server not responding and kick all players)

I cannot find the reason for this:

And what can I do? I’m literally getting crazy about that

Could anyone help me? I’ve heard there’s a datapack that fixes my problem? How do I install that?