Commit Graph

1426 Commits

Author SHA1 Message Date
Andrew Bettison
c1695a67b2 Fix bug in 'keyring list' command
Revealed by recent rhizomeprotocol test improvements.  Was always printing
empty DID and name fields.
(cherry picked from commit 7452c215e2)
2012-09-28 12:16:55 +09:30
Andrew Bettison
c2b515347f Improve testdefs: foreach_instance() function
Cherry picked from commit 87133cb2de, conflicts
in tests/rhizomeprotocol resolved by hand: bundle_received_by() now takes two
args before list of instances.

The 'rhizomeprotocol' tests now use create_single_identity() in fixtures (which
tests the 'keyring list' command).

Use foreach_instance() function in various places, and replace functions that
used to loop over instances with functions that work on the current instance.
2012-09-28 12:15:10 +09:30
Andrew Bettison
5b8194eae0 Refactor test definitions
Cherry picked from commit e994626429, conflicts
in testdefs.sh resolved manually (start_servald_instances() sets DUMMYx
variable).

Move create_rhizome_identities() from testdefs_rhizome.sh to
create_identities() in testdefs.sh

Rename create_identity() in testdefs.sh to create_single_identity(), uses
create_identities() to do its work.
2012-09-28 12:05:22 +09:30
Andrew Bettison
04abc7db0f Fix Solaris compile error and some warnings
The mmap(2) MAP_FILE flag is not defined on Solaris, and is optional or
ignored on Mac OS X and Linux.

Two "unused variable" warnings.

Issue #9.
2012-09-28 11:07:34 +09:30
gardners
59a969cfa3 fixed one of the outstanding issues with rhizome direct http push. 2012-09-27 22:01:07 +09:30
Andrew Bettison
14721fab19 Merge branch 'solaris' into rhizomedirect
All test cases pass on Solaris (see issue #16) except the 'jni' tests because
there is no Java compiler available on Solaris, and the new 'rhizomeprotocol'
tests from the rhizomedirect branch, which have always failed.
2012-09-27 17:38:16 +09:30
Andrew Bettison
b91fc4e5b5 Refactor some 'rhizomeprotocol' tests
Replace explicit inline binary data from HttpImport test, so that Git stops
thinking the shell script is a binary file.

Put curl(1) detection into common fixture function.
2012-09-27 17:36:22 +09:30
Andrew Bettison
b44053a480 Issue #16, fix 'dnaprotocol' tests broken on Solaris
Same problem that broke most of the 'dnahelper' test fixtures; the dnahelper
script was using #!/bin/sh, which on Solaris is not Bash.
2012-09-27 16:50:29 +09:30
Andrew Bettison
76401bd31b Improve some Rhizome debug logging code 2012-09-27 15:34:13 +09:30
Andrew Bettison
ca6d8f487d Fix broken 'rhizomeprotocol' tests on Solaris 2012-09-27 15:14:43 +09:30
gardners
9ecf6499f8 now tries to write bundle file to server. server seems to hang.
Getting very close now to rhizome direct http push working, though.
2012-09-26 17:12:48 +09:30
gardners
5c2b61758e now tries to connect to rhizome direct http server to push bundles.
(manifest is written, but file is not.  manifest also seems to be
missing signature block.) #9
2012-09-26 16:47:55 +09:30
gardners
5787dd860b Rhizome direct http forms first part of POST request to push bundles
to far side. #9
2012-09-26 16:01:27 +09:30
gardners
7ef4d942b2 rhizome direct now reads manifest data given a prefix. 2012-09-26 15:15:08 +09:30
gardners
8e4496f397 fixed bug in rhizome_direct_get_manifest() #9 2012-09-26 15:03:15 +09:30
gardners
c23d424d4d more work towards rhizome direct http actually pushing new/updated
bundles to remote party.
2012-09-22 15:21:02 +09:30
gardners
f7ef416091 bug fixes for rhizome direct response handling.
Can now generate a full response buffer instead of only using 9/32
of the space. #9
2012-09-21 15:45:10 +02:00
gardners
ee89f283e0 add initial parsing of rhizome direct response. #9 2012-09-21 14:40:36 +02:00
gardners
a7d42b3c73 added note contemplating about where parsing of rhizome direct
responses should occur. #9
2012-09-21 14:31:14 +02:00
gardners
3caf82ad15 fixed bug in rhizome direct http response formation. #9 2012-09-21 14:27:02 +02:00
gardners
5d881226c1 fixed bug in comparison of IHAVE lists. Now can generate list of
BARs that rhizome direct sync requestor has not seen. #9
2012-09-21 14:10:11 +02:00
gardners
cae11bd444 fixed rhizome direct response generation to allow request and
responses to be of different sizes. #9
2012-09-21 14:04:53 +02:00
gardners
f6bab96846 fixed bug when extracting BID prefix. #9 2012-09-21 13:47:58 +02:00
gardners
f7e75d5347 debugging and abstraction improvements in rhizome direct
synchronisation code. #9
2012-09-21 13:41:27 +02:00
gardners
f0472abf43 added new rhizome direct sources to android build process. 2012-09-14 11:26:40 +02:00
gardners
692eb2cdc9 added BAR list comparison code for Rhizome direct.
Now returns series of "I have [newer]"'s and "Please send me"'s,
consisting of a 1 byte ID (0x01 or 0x02 respectively), followed
by the 64bit BID prefix from the BAR.  As with all of Rhizome
Direct at present, the geo bounding box is ignored for now.
2012-09-14 12:10:14 +08:00
Andrew Bettison
45e3d1d078 Add more debug to Rhizome fetch code
To help investigate issue #16, 'rhizomeprotocol' test case 1 failing on
Solaris.
2012-09-13 14:43:47 +09:30
Andrew Bettison
1f4688db99 #16 Fix 'rhizomeops' tests that fail on Solaris 2012-09-13 14:08:52 +09:30
Andrew Bettison
3f4ee701ec Artefacts created by libtoolize -c -i
Replaces symbolic links created from previous libtoolize -i (without -c) which
of course do not work across all platforms.
2012-09-12 15:21:50 +09:30
gardners
6553050566 rhizome direct enquiry request now gets back enquiry response,
and realises that it needs to process it.  It does not yet
process it. #9
2012-09-11 14:34:58 +09:30
gardners
9a5dbbd14f rhizome direct http transport now asks for response to enquiry when
enquiry received by server.  Generating responses to enquiries not
yet implemented. #9
2012-09-11 13:09:40 +09:30
gardners
bb0be86db3 fixed content-disposition problems. Request now gets accepted.
Need to write code to handle it now, and send cursor fill back
the otherway. #9
2012-09-11 09:34:41 +09:30
gardners
0e04dde28c changed rhizome direct POST URI paths to /rhizome/import and
/rhizome/enquiry.  Also fixed bug with content-length header
line when forming /rhizome/enquiry request.  post multipart
data is still malformed in some way. #9
2012-09-11 09:28:11 +09:30
gardners
e8009ac94a rhizome direct http transport sends request, and receives http
reply (including if error).  Doesn't capture the reply body yet. #9
2012-09-11 09:04:38 +09:30
gardners
e4896cd028 now tries to open connection to rhizome direct server using
http transport.  #9
2012-09-11 06:56:04 +09:30
gardners
4f5f2c2444 work towards http transport working for rhizome direct. #9 2012-09-10 20:22:14 +09:30
gardners
872b88f744 fixed hanging bug. still gets bundles showing up in query
results even though size bin is wrong. That bug doesn't stop
us for now, but should be sorted out.
rhizome_direct_http_dispatch() can now be implemented
(synchronously for now will be fine).
2012-09-10 09:22:44 +09:30
gardners
dd01f7939d further work on rhizome direct dispatching etc.
For some reason finds the same manifest several times (size bin
filtering seems to not be working right).
Also sync doesn't realise it has finished, and so doesn't return
when done.
2012-09-10 09:16:27 +09:30
gardners
d796a482b7 refactored rhizome direct code to separate http transport specific
code from general rhizome direct BAR buffer gathering and processing.
2012-09-09 13:50:09 +09:30
gardners
1d4c865a35 fixed bugs in cursor range pickling. #9 2012-09-09 09:15:52 +09:30
gardners
f0c4bfd7bf fixed cursor range reporting bugs. #9 2012-09-09 09:06:38 +09:30
gardners
27fc7a44d0 rhizome direct cursor operations now include pickled cursor range
in output buffer (but doesn't yet report the range correctly). #9
2012-09-09 08:58:47 +09:30
gardners
0207d8e541 added cursor limit pickling, restoration functions. cursor
functions now try to honour these. Not yet tested. #9
2012-09-09 08:30:38 +09:30
gardners
53228f078e rhizome direct now has a cursor function to iterate through all
bundles in the rhizome database in an appropriate priority order
(currently small before big). #9
2012-09-08 20:26:18 +09:30
gardners
3e4b20f5df rhizome_direct_get_bars() now allows selections to be based on
size of associated data in a bundle, so that we can synchronise
small things first.  Also preliminary work on making a general
cursor-type wrapper function for get_bars() so that it is easy
for any rhizome direct transport driver to iterate over the
known bundles in a rhizome datastore. #9
2012-09-08 20:00:14 +09:30
gardners
b13c23de6a rhizome_direct_get_bars() now sets bid_high correctly. #9 2012-09-08 09:35:58 +09:30
gardners
89b09563a3 Wrote function to get a range of BARs from the Rhizome database
for use in Rhizome Direct synchronisation requests. #9
2012-09-08 07:55:57 +09:30
gardners
446adaa868 Added note regarding new architecture to existing comment. #1 2012-09-08 07:55:32 +09:30
gardners
6d725535f9 starting work on the actual synchronisation code for rhizome direct. 2012-09-07 22:53:16 +09:30
Daniel O'Connor
f8d5b066c0 Create #! line correctly (no need to escape !).
Many more tests pass now.
2012-09-07 15:42:20 +09:30