Commit Graph

284 Commits

Author SHA1 Message Date
Andras Slemmer
d8ae07e771 node-driver: Use anyAddress for RandomFree port allication 2016-09-05 17:29:44 +01:00
Andras Slemmer
9836edd191 Revert reuseaddr 2016-09-05 16:08:58 +01:00
Andras Slemmer
6b37048a14 node-driver: Remove reuseAddress = true as it breaks tests on osx 2016-09-05 15:43:19 +01:00
Shams Asari
97e1a59770 Refactored FiberRequest into cleaner ProtocolIORequest and fixed checkpoint regression 2016-09-05 14:42:54 +01:00
Matthew Nesbit
eb8510e7cc Some integration tests seem to be getting exceptions that suggest the ArtemisMQ session has been closed down already. Looking at the client code it is clear two threads can call stop and interfere with each other. Therefore this fixes the running flag logic. 2016-09-05 14:13:38 +01:00
Andras Slemmer
637a41401d node-driver: Reuse address when polling for port, poll for correct condition\(!\) 2016-09-05 11:04:31 +01:00
Mike Hearn
3854fec17f Testing: Make PortAllocation set SO_REUSEADDR to avoid CI conflicts 2016-09-05 11:22:00 +02:00
Andras Slemmer
ca1b0083ed node: Clean up messy issue in test 2016-09-01 18:15:47 +01:00
Andras Slemmer
dded4c6e8f node: FIx WalletMonitorService tests 2016-09-01 18:15:47 +01:00
Ross Nicoll
4d0b23ab6f Add log4j-web to node
Add log4j-web to node so it stops complaining that it's running in a web environment without that option.
Longer term we may want to split the web parts into their own optional extra for node, but for now I think
this is a sensible solution.
2016-09-01 16:15:15 +01:00
Ross Nicoll
b913b18e02 Merged in rnicoll-simulations (pull request #314)
Move test code from node to test-utils
2016-09-01 15:21:34 +01:00
Ross Nicoll
868b23a923 Move simulations to top level 2016-09-01 11:15:05 +01:00
Ross Nicoll
07f44e9e2a Move test code from node to test-utils 2016-09-01 11:15:05 +01:00
Matthew Nesbit
039229cdfd Remove bouncycastle-jdk14 that is causing problems for one of the member banks.
Only need testCompile scope
2016-09-01 11:04:48 +01:00
Andras Slemmer
86d6ee0110 node: Cash Issue doesn't require notary 2016-09-01 09:36:06 +01:00
Andras Slemmer
cfebccc495 node: Remove TransactionBuildResult.Complete, add pretty printing of ServiceToClientEvent 2016-09-01 09:36:06 +01:00
Ross Nicoll
232db9a1fd Move test utilities into their own package
This moves a lot of the test support code into its own package which is only imported for tests,
so it's not shipped as a part of core Corda. The node currently depends on this support code to
compile, although future work could try to separate this out. This change highlights that parts
of production code is dependent on test elements (i.e. dummy keys), and makes it harder for
such accidental crosses to occur later.

An integration test category is also added as part of this work, to contribute towards COR-345.
2016-08-31 15:40:54 +01:00
Clinton Alexander
5439e0980f Merged in clint-driver-debug-fix (pull request #308)
Fixed driver debug mode.
2016-08-31 11:31:02 +01:00
Clinton Alexander
0c4a80453a Used lists instead of strings for appending to JavaArgs in driver. 2016-08-30 14:01:54 +01:00
Matthew Nesbit
8756b49794 Add switchable HTTPS to Node web server
Explain change of cipher

Include extracted Dev Corda Root certificate so that it can be installed by HTTPS users.
2016-08-30 13:07:40 +01:00
Clinton Alexander
82b416cb88 Fixed driver debug mode. 2016-08-30 12:03:31 +01:00
Ross Nicoll
ad8ffca0b4 Add CommitTransactionProtocol
Add new protocol which manages the entire process of taking a signed transaction ready
for notarisation, through notarisation and onto recording it both locally and informing
remote nodes.

This protocol also optionally can include the ClientToServiceCommand which triggered a transaction
being created, to give the remote nodes context on why a change occurred (i.e. "You are being sent
£100")
2016-08-25 16:30:39 +01:00
Matthew Nesbit
089ba2cb69 Only NetworkMapServer addresses can be publicly manufactured. Use identity publick key as addressing, with only bridges using the HostAndPort information
Fixup after rebase and fix issue with checking previous deployment of bridges

Correct comments on ArtemisMessagingClient constructor

Fixup rates fix demo

Get rid of when statements

Make NetworkMapCache send modify as well as add//remove events. Make inboxes for nodes persistent.

Suppress warnings

Fix message acknowledgement so that it actually consumes messages properly.

Change queueName to SimpleString to stop lots of wasted conversions

Get rid of spurious import

Tidy up and add comments

Update to include comments on PR

Remove unnecessary import
2016-08-25 15:56:50 +01:00
Ross Nicoll
f9880a4990 Pre-filter states passed to generateSpend()
Pre-filter states passed to generateSpend(), so that requests from the UI to spend cash only ever
spend cash with the correct issuer.
2016-08-25 13:20:12 +01:00
Mike Hearn
c8323099bb Minor: cleanup the commercial paper contracts.
There's no need for the notary to be specified in commands. A few other tweaks and additions found whilst refreshing the docsite.
2016-08-25 11:30:25 +02:00
Mike Hearn
3e330a2d36 Merged in mike-fix-walletfiller (pull request #277)
Rewrite the test wallet filler code to not be buggy.
2016-08-23 17:59:19 +02:00
Ross Nicoll
dc2f4055fc Restrict cash exit commands to working on cash held by the issuer
Remove the ability to exit cash not held by the cash issuer; this solves a number of problems:

* Ensuring owner of the cash is aware of the funds being destroyed
* Determining where to send any change resulting from partial exiting of funds
* Auditing the destruction of funds
2016-08-22 17:17:19 +01:00
Clinton Alexander
668fecfea7 Merged in clint-no-notary-error (pull request #283)
Fixed bug when incorrect notary service type is specified.
2016-08-22 16:41:38 +01:00
Mike Hearn
097bb033c4 Rewrite the test wallet filler code to not be buggy. 2016-08-22 16:26:32 +02:00
Andras Slemmer
1a2c712a48 node-driver: Make debugging optional and off by default 2016-08-19 17:05:00 +01:00
Andras Slemmer
9d22d66548 node-driver: Fix some kdocs. Also, full stops! 2016-08-19 17:05:00 +01:00
Andras Slemmer
f4577b743e node-driver: Add startClient, startLocalServer 2016-08-19 17:05:00 +01:00
Andras Slemmer
5f33bedc13 node-driver: Polling doesn't timeout, just prints warning 2016-08-19 17:05:00 +01:00
Andras Slemmer
9cbdf001fb node-driver: Return Futures instead of waiting for full node startup 2016-08-19 17:05:00 +01:00
Clinton Alexander
7b3003ea04 Added TODO for further work 2016-08-19 16:41:49 +01:00
Matthew Nesbit
696b9741dd Remove ClashingThreads exception by tightening up unique id on LinearState to be a secure random value, with constraints that it cannot be duplicated. Also, rename to linearId rather than the confusing thread.
Try providing a helper interface to encourage enforcing LinearState rules

Fixup after rebase

Change to using Clauses for verifying LinearState standard properties

Fix whitespace change

Tidy up ClauseVerifier after PR comments

Change from SecureHash to a TradeIdentifier class

Change TradeIdentifier to UniqueIdentifier
2016-08-19 11:52:16 +01:00
Mike Hearn
6adebd3fa8 Clarify exception handling in the SMM add method a bit. 2016-08-18 18:19:46 +01:00
Mike Hearn
db3aa1491c Upgrade Quasar to 0.7.6 and fix an exception handling bug in SMM that it revealed (if an exception was thrown immediately on protocol startup we let it leak instead of capturing it in the future. 2016-08-17 14:43:45 +01:00
Ross Nicoll
a9ec3c253e Merged in rnicoll-notify-tx (pull request #282)
Add observable for transactions being stored
2016-08-16 14:50:55 +01:00
Clinton Alexander
77f5689468 Renamed variable for clarity. 2016-08-16 13:54:08 +01:00
Clinton Alexander
5d68210355 Driver now correctly resolves quasar path on Windows. 2016-08-16 13:26:38 +01:00
Clinton Alexander
85dce390f4 makeNotaryService now enforces post condition with type system. 2016-08-16 09:21:29 +01:00
Clinton Alexander
a74c491745 Fixed a bug where if NotaryService.Type is used as an advertised service no notary is created and no obvious error occurs. 2016-08-16 09:18:33 +01:00
Andras Slemmer
9d9164980e Merged in andrius-driver-fix (pull request #280)
DriverTest fix: get quasar.jar location from the classpath
2016-08-15 17:31:02 +01:00
Clinton Alexander
c5a6d11976 Merged in clint-node-driver-conf-fix (pull request #275)
Config will error earlier if the reference.conf file is missing.
2016-08-15 15:53:50 +01:00
Mike Hearn
a451000623 Merged in mike-fix-artemis-threading (pull request #276)
Messaging layer improvements
2016-08-12 19:07:54 +02:00
Mike Hearn
3d391ec8c2 Add unit tests for the resolve transactions protocol 2016-08-12 17:14:54 +02:00
Ross Nicoll
a3d37a4d00 Require notary to be explicitely stated on each transaction 2016-08-12 15:51:04 +01:00
Ross Nicoll
17ae349f4d Remove support for timestamp commands 2016-08-12 13:51:34 +01:00
Mike Hearn
cba0427e01 Make ArtemisMessagingClient blocking and require the user to directly enter a message loop. This cleans up a few things and ensures we can't get caught out by messages being arbitrarily re-ordered as they pass through any Artemis thread pools. 2016-08-12 14:06:03 +02:00