Closed GoogleCodeExporter closed 9 years ago
Original comment by caprea
on 12 Mar 2010 at 8:01
Original comment by caprea
on 13 Mar 2010 at 12:21
This problem is occurring for importing any type of data (images, morphologies,
objs ).
If it helps diagnosing the problem at all, the last time I was able to
successfully
import a file was this past Wednesday.
Original comment by piperfl...@gmail.com
on 13 Mar 2010 at 12:24
I've identified the cause of the issue and a temporary solution, but I have a
suspicion that my work-around may cause some unforseen problems (like duplicated
Tangibles)
The cause:
Recent changes to the server were made to make the server differentiate between
POST
and PUT methods (previously it treated them the same) So that it could support
returning different errors/status responses. To make it respond like a more
standard
HTTP server. The put method works but the post method is unfinished.
Work-around: Change the 'POST' methods used in importing tangibles to be 'PUT'
instead. client.put() instead of client.post()
Solution: Finish code on POST in server, prerequisite of discussing HTTP
contract
Alternate solution: Revert the server code for lDataContentResource' to the code
prior to Wednesday.
Original comment by caprea
on 13 Mar 2010 at 12:32
Original comment by stephen....@gmail.com
on 12 Jul 2010 at 12:39
I again tested PUT successfully using ...util.ServerTestImport.java.
See the code for the details. Note some data is hard coded. This does not lend
itself to a build-time unit test because it modifies the database and set of
data files.
Basically this program PUTs a simple text file.
The test program returns this response info:
Status code: 201
Response : http://data.wholebraincatalog.org/datawrappers/generic/jbz42
dw location: http://data.wholebraincatalog.org/content/000TestImport.txt, sha1:
26d82f1931cbdbd83c2a6871b2cecd5cbcc8c26b
I examine the data files directory and the file is in place after the test
whereas before the test it was not.
I run http://drlittle.ucsd.edu:8182/datawrappers/generic/jbz42 from a browser
and get this response:
<ns2:DataWrapper Hjid="1152"
id="http://data.wholebraincatalog.org/datawrappers/generic/jbz42"
xmlns:ns9="http://morphml.org/channelml/schema"
xmlns:ns8="http://morphml.org/neuroml/schema"
xmlns:ns7="http://morphml.org/networkml/schema"
xmlns:ns6="http://morphml.org/biophysics/schema"
xmlns:ns5="http://morphml.org/morphml/schema"
xmlns:ns4="http://morphml.org/metadata/schema"
xmlns:ns3="http://wholebrainproject.org/wbc/generated/annotation"
xmlns:ns10="http://wholebrainproject.org/wbc/generated/datawrapper"
xmlns:ns2="http://wholebrainproject.org/wbc/generated">
<location>http://data.wholebraincatalog.org/content/000TestImport.txt</location>
<sha1>26d82f1931cbdbd83c2a6871b2cecd5cbcc8c26b</sha1>
<type>unknown</type>
</ns2:DataWrapper>
which confirms the new data wrapper.
I run http://drlittle.ucsd.edu:8182/content/000TestImport.txt from a browser
and get this result:
This is a test file.
which confirms the imported file is in place and its content can be returned.
Note the SHA-1 is computed and stored in the data wrapper as well.
Original comment by davlit0...@gmail.com
on 12 Jul 2010 at 5:56
Original comment by stephen....@gmail.com
on 12 Jan 2011 at 10:39
Closing a whole raft of issues because they are not relevant to the web version
any more
Original comment by stephen....@gmail.com
on 7 Mar 2011 at 10:31
Original issue reported on code.google.com by
caprea
on 12 Mar 2010 at 8:01