[Solved] BuildTools is laggy for my code?

Discussion in 'Spigot Plugin Development' started by AgentleaderAlex, Jul 5, 2015.

  1. When I first switched over to BuildTools, it fixed a few bugs. But the down-side was that people could tp to their base or so, and just drop a whole ton of frames and they eventually crash or MC is frozen. It's only in certain places this happens. I believe it's my code because when I disabled my plugin, it doesn't drop frames going to a certain place. I also noticed that this kind of thing does not happen when I attempt to use the Spigot 1.8 snapshot instead.

    Any clues on what type of coding would affect this? I'm not really allowed to post my code at the moment.

    My server is close to release and I really want this problem fixed and using BuildTools instead of the (glitchy) snapshot.

     
    #1 AgentleaderAlex, Jul 5, 2015
    Last edited: Jul 6, 2015
  2. What does your code do?
     
  3. All my code is is extra features to a factions server, like /perk.
     
  4. Does it spawn entities or use anything other than the Bukkit/Spigot API?
     
  5. It spawns entities but only by command, and nothing automatic. And it uses the following APIs: Factions, MassiveCore, Essentials, PermissionsEx, and Votifier.
     
  6. Are there any players misusing this command? Do you have a client-side crash report (since you said that sometimes the client crashes)? What is in common (if anything) about the areas where the issue occurs?
     
  7. The players do not have access to the commands to spawn entities, nor does anyone who has access use it. The most I know of a client-side crash is a ReadTimeoutException. The areas are material heavy bases.
     
  8. Can you get a timings report from during the crashes?
     
  9. I just realized, lava is a problem that's causing lag. When I face lava, it may or may not freeze. But if it does, it does.
     
  10. What about those timings?
     
  11. All I can say is above 15 seconds. I can not really tell, simply because at times it's not rendering the blocks.
     
  12. It looks like Factions is actually what is causing the lag. Perhaps try removing factions temporarily and determining if the problem still occurs.
     
  13. A 2.8 second sample isn't ideal, but it looks like there's some problem with ticking items. Are you modifying Spigot's source at all, using an item modifying plugins, or using some weird Spigot fork? If no to all of the above, redownload build tools, recompile, and use the new build.

    Wat. Factions is only using 6ish%. While that's not good, that's not even close to the 80% being used by item entities. I see that ticking each item is taking an extremely long time, but I'm unaware of how Factions could be causing that.
     
  14. I don't believe it's factions as because when I disabled it, nothing really happened. I noticed something was bleeding constantly, and I have no idea what it is, and it keeps bleeding forever. I tried killing it and everything, but it's invisible and intangible?

    //Edit: I'm thinking it's false bleeding, don't ask me.
    My custom coded plugin caught some extra numbers. Here's my it caught:
    [​IMG]
    [​IMG]
     
    #16 AgentleaderAlex, Jul 6, 2015
    Last edited: Jul 6, 2015
  15. I'm referring to Faction - entityTick.

    Try adding ClearLagg.
     
  16. Get an entity clear up plugin, and turn down the activation radius's in the spigot.yml.
     
  17. I coded a custom one already, look at my editted post for the pictures
     
  18. Dropped items < Entities
    They're not the same thing, make sure you're clearing up all entities apart from armor stands, players, picture frames, etc.