> On July 10, 2014, 5:08 p.m., David Faure wrote:
> > But why CMD_REPARSECONFIGURATION especially?
> > 
> > If the slave is on hold, will anything else get through? IOW should the 
> > test just be extended with "|| suspended", no test on cmd?

I started out doing just that at first, but that resulted in a rather long 
pause whenever I clicked on a link that resulted in a download dialog. The 
pause seems to be caused by the the job getting suspended and then put on hold 
where the hold portion waits for the ioslave to be returned to klauncher by 
invoking "KToolInvocation::klauncher()->waitForSlave(d->m_pid)". That causes a 
delay because the command to put the ioslave on hold will be queued up due to 
the added "|| suspended" check and will only succeed once the call times after 
some period (I guess 25 secs).

When I thought more about this, I realized that this problem is only likely to 
affect this particular command because the scheduler is the one that controls 
how ioslaves are used and it does the right thing by not to sending commands to 
ioslaves on hold without first putting them back into service. Unfortunately 
CMD_REPARSECONFIGURATION is an exception. Hence, this fix that I am not totally 
sure belongs here. Perhaps the correct thing to do would be to fix the problem 
in the scheduler by putting the ioslave on hold back into service, sending it 
the reparse configuration request, and putting back on hold again? I dunno, but 
it seemed like an overkill by comparison to this patch.

Anyways, this is the reason why I did what I did. I knew it would probably be 
safe to send the reparse configuration request when the ioslave is resumed, but 
I was not sure that was the case for all other commands.


- Dawit


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/119211/#review62085
-----------------------------------------------------------


On July 10, 2014, 12:04 p.m., Dawit Alemayehu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/119211/
> -----------------------------------------------------------
> 
> (Updated July 10, 2014, 12:04 p.m.)
> 
> 
> Review request for kdelibs, David Faure and Thiago Macieira.
> 
> 
> Repository: kdelibs
> 
> 
> Description
> -------
> 
> This patch addresses the issue where attempting to send 
> CMD_REPARSECONFIGURATION to suspended ioslaves results in a freezing of the 
> application that sent the request. This problem can be clearly reproduced by 
> following the steps outlined in the bug report.
> 
> I am not entirely sure whether or not this fix really belongs in 
> kio/connection.cpp, but I could not find a more convenient location to queue 
> the command request to ensure the ioslave receives the reparse configuration 
> command if it is ever reused again.
> 
> 
> Diffs
> -----
> 
>   kio/kio/connection.cpp 99aea0b 
> 
> Diff: https://git.reviewboard.kde.org/r/119211/diff/
> 
> 
> Testing
> -------
> 
> Run the steps given in the bug report before and after the fix.
> 
> 
> Thanks,
> 
> Dawit Alemayehu
> 
>

Reply via email to