KIO::CopyJob: POST request resulting in a second (invalid) GET request

Dawit A. adawit at kde.org
Mon Jul 26 05:45:33 BST 2004


Hi,

I have been trying to solve BR# 79813. Unfortunately the problem is not 
trivial to solve so far as I can see. Perhaps someone can see a way out of 
this without a bad hack or workaround. Anyways, the sequence of events is as 
follows:

1.) A form submit leads to a POST action which then sends you back data.

2.) You elect to save that data to file, but choose an existing file.

3.) The file io-slave attempts to save the data to the requested file and it 
returns a file already exists error message.

4.) The previous job that contained the data returned from the server is then 
discarded (killed) in order to resolve the conflict (file exists).

We can stop at this point. Any action carried out after this point is 
irrelevant since we have already lost our job due to the file io-slave 
calling error and hence the finished() signal being emitted by the io-slave. 
The small testcase provided in comment #3 of the bug report shows the problem 
perfectly. Hmm... I also think this same issue is applicable if the server 
redirects us to do GET the result  from a temporary resource instead of 
returning the data directly. Any clean solutions to solve this problem ?

As a side not the file io-slave can benefit from some optimizations, like 
returning immediately in ::put() if "overwrite" is false and the destination 
already exists...

-- 
Regards,
Dawit A.
"Preach what you practice, practice what you preach"




More information about the kfm-devel mailing list