Open GoogleCodeExporter opened 8 years ago
I seem to have added this comment to the wrong issue, so I'm copying it to this
issue.
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 6:08
Original issue reported on code.google.com by
stephen....@gmail.com
on 12 Jul 2010 at 1:15