Spell Queueing locks server

Old bugs stored here for reference.
Locked
User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Spell Queueing locks server

Post by John Adams » Sun Aug 03, 2008 2:16 am

I built Faithful Swing and was testing it out. I didn't see the icon pop available again, so I hit it anyway... the cast bar filled, then locked, now I cannot do any commands in the World. It's still running, just no commands working.
I will try and reproduce it now.
(this was after a world restart and /reload spells)
Last edited by John Adams on Tue Aug 12, 2008 6:05 pm, edited 1 time in total.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Sun Aug 03, 2008 2:51 am

Ok, got the bug I think. Cast the spell, then while it's cooling down, tap it again. Soon as the cooldown finishes, the second (queued) attempt to cast fires off, and locks the World.
I know queuing is likely not working yet, I only discovered it out of habit.
I don't think it has to do with /reload spells.

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Sun Aug 03, 2008 6:13 am

I did setup queued spells and they used to work at one time, but you are right it seems like something is off. More than likely it is a Mutex that is blocking access to the spell and preventing further execution. I'll take a look at it.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Tue Aug 12, 2008 6:19 pm

Definitely, Queueing causes a server to lock solid - no activity, doesn't crash, so it cannot be reset. It's pretty critical, since we cannot rely on players to turn off button queueing in their clients.
However, there is that workaround for us, for now. Go to Options, Controls, Button Queue and disable that sucker. This also might only effect those of us using the new spells, since I don't think this happens with Attack or Sprint (the only spell anyone else gets).

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Thu Aug 14, 2008 5:17 pm

Fixed.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Thu Aug 14, 2008 7:03 pm

Sorry to say, not fixed yet. Just locked the server again. I will give you the spell I am using in your book, you can try it - but the server will be dead until I kill it and restart.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Fri Aug 15, 2008 2:18 pm

Either Scat cannot stop himself from queueing spells (LOL) or the server is locking solid for another reason. The last activity today was a few spell casts seemingly close together, a client disconnect, then a dozen or so more sapswill slaughters by the guards... and I cannot connect.
Says 1 Zone(s) active, 0 Client(s), and has been like that for hours. It's likely the queueing still, but just in case it's not, I wanted to update this post.
Resetting the server.

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Fri Aug 15, 2008 3:09 pm

I don't see how it could be the spell que. I cast Lightning Burst, it landed and I immediately cast it again. When the recast timer hit 0 it recast itself. I did this all several times chain casting it and I never had a problem.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Fri Aug 15, 2008 3:47 pm

I used Faithful Swing on my server, and it did queue and cast when the cooldown expired - however, immediately the cast bar froze and the server was fine'.
I think I gave you Faithful Swing, if it winds up being the spell settings, that's good. Spell ID 10000.

User avatar
Scatman
Retired
Posts: 1688
Joined: Wed Apr 16, 2008 5:44 am
EQ2Emu Server: Scatman's Word
Characters: Scatman
Location: New Jersey

Post by Scatman » Fri Aug 15, 2008 3:54 pm

Yeah I was on it testing my quest out and everything was going well. Killed some mobs, and such. I exited the emulator by clicking the X in the top right hand corner then when I tried to log back on a few minutes later the server was locked! :cry:

LethalEncounter
Team: Zombie
Posts: 2717
Joined: Wed Jul 25, 2007 10:10 pm

Post by LethalEncounter » Sun Aug 17, 2008 2:52 pm

Could you try the same thing you did before to lock the server? I have fixed a couple of lock problems that were causing issues as well as a bug that might have been causing your crash problem. I don't think I ever explained the lock issue, but here it is: Since the lua scripts can be executed at any time and not in an orderly fashion Mutex (mutually exclusive) locks are used to prevent multiple threads from accessing the safe portion of the code at the same time. If for example, one thread was adding to the loop while it was being modified in another thread this could thrown exceptions or corrupt the data so that the exception is thrown later. The locks help prevent this. The problem comes in when I used a particular lock and then I decide to reuse a function from elsewhere that uses the same lock. This will cause the second lock to wait forever for the first lock to release itself. If it happened in the zone thread only that zone would be affected, but since it happened in the spells thread (which is global) is causes the whole server to lock up.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Sun Aug 17, 2008 3:44 pm

Naw, still seems to be an issue - though it is a little better. The server did not entirely lock up - but refused new connections and further actions in the zone could not be executed (ie., could not cast spells, attack, but chatting worked).
When Scatman and I logged out to reset our clients, we could not get back to the server until I restarted it.

User avatar
John Adams
Retired
Posts: 9684
Joined: Thu Jul 26, 2007 6:27 am
EQ2Emu Server: EQ2Emulator Test Center
Characters: John
Location: Arizona
Contact:

Post by John Adams » Mon Aug 18, 2008 7:18 pm

Definite progress made in this bug. I'll let it sit open for a while longer while we dev more spells.
Nice work, LE.

Locked

Who is online

Users browsing this forum: No registered users and 0 guests