Server Crash

Discussion in 'Spigot Help' started by iDavid86920, Jul 3, 2018.

  1. Hi, my server is crashing too many times and idk whats happening and i rlly dont know how to analyze the server crash. Can someone please help me?

    Log:

    https://paste.md-5.net/wudocobata.coffee

    Thanks.
     
  2. It seems like WorldEdit is causing this problem. Try updating to the latest version of WorldEdit.
     
    • Useful Useful x 1
  3. Thank you very much for taking the time to respond.

    Today same happened again after a command that a user put the World Edit, so I thought that was that and now I see that you confirm it. I will update the World Edit and in the process I will delete the folder to see if that solves the problem, otherwise I will notify. Thank you again for responding.

    Goodnight.
     
    • Like Like x 1
  4. electronicboy

    IRC Staff

    Your permission plugin caused the crash, fired an event async but marked it as sync and locked up a running task which the main thread was waiting for
     
    • Useful Useful x 1
  5. Why did you tag me if you haven't even purchased my permissions plugin ?!
     
  6. Im a customer in other account, i said you in another conversation i'm @xLeonardoMPx . I have 2 accounts and i use this.
     
    #7 iDavid86920, Jul 10, 2018
    Last edited: Jul 11, 2018
  7. Im @iDavid86920
     
  8. In the most recent version (which I dont think he is using) its just a regular event call. (As I can remember I had it async in one version). So it should be just good now I guess?

    Correct me if Im wrong @electronicboy

    If thats the case then just update.
     
  9. I just made the last update you did today. I will see if the problem does not happen again, if it persists I will notify in this Post.
     
  10. electronicboy

    IRC Staff

    When firing an event, unless you've marked the event as being "async" (See the constructor on event), it will hit a synchronized block inside of the callEvent method, that stack report indicates that the main thread has got that lock, and then the permission plugin also fires an event which is getting stuck behind that lock and waiting for it, because you've called that event async and not marked as it being async, it's stuck behind the lock, which is an issue here because the main thread is waiting for a task to complete which is stuck behind the lock

    Code (Java):

    public void callEvent(Event event) {
        if (event.isAsynchronous()) {
            if (Thread.holdsLock(this)) {
                throw new IllegalStateException(event.getEventName() + " cannot be triggered asynchronously from inside synchronized code.");
            }
            if (server.isPrimaryThread()) {
                throw new IllegalStateException(event.getEventName() + " cannot be triggered asynchronously from primary server thread.");
            }
            fireEvent(event);
        } else {
            synchronized (this) {
                fireEvent(event);
            }
        }
    }
     
     
    • Useful Useful x 1
  11. Thank you so much for the clarification