Commit Graph

320 Commits

Author SHA1 Message Date
Shams Asari
62b26bcd89 Moved Currency stuff in ContractsDSL out of core and into finance 2017-08-15 18:08:02 +01:00
Viktor Kolomeyko
88308a70c7 - Remove usages of deprecated methods
- Fix typos
- Fix other Kotlin warnings
2017-08-15 16:45:44 +01:00
Joel Dudley
ccdab6af4d For convenience, creates RPC snapshot methods for feeds. 2017-08-15 16:18:15 +01:00
Andrius Dagys
43adbfd66c Remove junit-quickcheck and redundant generators 2017-08-15 11:12:02 +01:00
Andrius Dagys
f69273027c Verifier test: make sure only correct transactions are generated 2017-08-15 11:12:02 +01:00
Rick Parker
2f08425c43 Refactor KryoAMQPSerializer to go through generic APIs to access AMQP serialization (#1225) 2017-08-14 17:24:04 +01:00
Rick Parker
31df43bd76 Some preparation work for AMQP serialization integration & a refactor fix (#1214) 2017-08-11 13:23:00 +01:00
Ross Nicoll
d86cb1ac64 Remove deprecated partyFromName() function 2017-08-10 13:25:53 +01:00
Andrius Dagys
9103b3b962 Fix jackson serialization of transaction types. By default it attempts to serialize
any property (any getter), which causes issues on the SignedTransaction, since it
attempts to resolve both a regular and a notary change transaction from the serialized bytes.
2017-08-10 10:57:06 +01:00
Rick Parker
28610868c4 Remove Kryo from core module completely, including gradle dependencies (#1161) 2017-08-09 14:53:46 +01:00
Andrzej Cichocki
3a3ead2dfe Remove ListenableFuture from core/main (#1030) 2017-08-07 14:31:24 +01:00
josecoll
64ba8d3a88 Updated samples and demos to use new Vault Query service. (#924)
* Updated all sample code to use new Vault Query service APIs.

* Fix broken Unit test.

* Added missing transaction boundary.

* Fix broken ScheduledFlow test (caused by assertion on non-ordered collection)

* Remove redundant negative test (as new Vault Query no longer returns iterators).

* Whitespace formatting fixed following PR review from SA.

* Force query to specify a PAGE SIZE equivalent to total states to be exited (RP review comment).

* Use single (and fail fast) instead of first - when only expecting a single result.

* Demonstrate paging and sorting; failfast on single expected result.

* Enhancement: added Sorting by CommonStateAttribute (StateRef txnId and index)

* Fix: incorrect total states count.

* Fixed incorrect total states counting.

* Remove redundant filter (UNCONSUMED).

* Updated tutorial code and associated documentation (building transactions).

* Updated all vaultAndUpdates to vault[Track|Query]By.

* Temporary disable failing Vault Query tests (awaiting pagination PR fix).

* Rebase from master to pick up pagination changes/fix.

* Fixed criteria filter on track.

* Cleanup redundant print output.

* Refactor to extract common function for Vault Query paging and sorting.

* Identified problem in SimmValuation demo failing test caused by query by single participant in participants list (not yet supported in VaultQuery criteria).

* Minor fixes following rebase from master.

* Minor updates following rebase.

* Removed redundant import.

* Fixed type casting error.

* Minor fixes following rebase from master.

* VQ Fix - applied in other PR.

* Removed duplication after rebase and minor fix to failing smoke test.
2017-08-03 11:47:15 +01:00
Shams Asari
4312dc0771 Resolved all non-deprecation warnings 2017-08-02 12:17:52 +01:00
Rick Parker
f2df05a15b Missed default on driver (#1093) 2017-08-01 09:39:02 +01:00
Shams Asari
4a600121cc Removed deprecated methods in DataFeed and deprecated feed-based methods in CordaRPCOps 2017-07-31 15:11:00 +01:00
Mike Hearn
b546bec064 Make the RPC observations pool use daemon threads. 2017-07-26 18:30:59 +02:00
Mike Hearn
a9a50ce8f3 Add generics to Vault.Update 2017-07-26 18:30:59 +02:00
Mike Hearn
dcda0b078e JavaFX: Add a few more utility functions for working with DataFeeds and the JavaFX UI thread. 2017-07-26 18:30:59 +02:00
Matthew Nesbit
b4ca0cdde9 Remove getCashBalances first part
More removal of getCashBalances

Get rid of duplicated code

Move onto new getCashBalance extension methods

Move onto new getCashBalance extension methods

Correct balance query code

Address PR request comments

Address PR request comments

Address PR request comments
2017-07-26 15:00:03 +01:00
Shams Asari
407b467f67 Moved the majority of the contents of Utils.kt into either InternalUtils.kt or KotlinUtils.kt.
What remains is being dealt with in another PR.
2017-07-24 19:25:56 +01:00
Shams Asari
a485bbada8 Moved ThreadBox into core.internal 2017-07-21 18:01:29 +01:00
Rick Parker
fe9db6f1f7 Remove links to Kryo from serialization "clients" (#1079) 2017-07-21 14:23:05 +01:00
Shams Asari
070f0c040e Moved a bunch of stuff which shouldn't be public out of core.utilities and into core.internal 2017-07-19 14:09:03 +01:00
Clinton
0ccfae252f POMs generated by publishing are now correct. (#1055)
* POMs generated by publishing are now correct. The publish extension now requires an explicit call to configure the publishing instead of waiting until after evaluation. This prevents evaluation order issues with the artifact renaming code that causes the POM to have the original, incorrect, artifact names.

* Fixed new test compile issues caused by removal of some dependencies in test utils that caused webserver code to be automatically included in any project also compiling test utils.
2017-07-18 12:34:56 +01:00
Shams Asari
561a329064 Moved the various extension methods for creating Durations from Utils.kt to KotlinUtils.kt 2017-07-18 10:26:53 +01:00
josecoll
65ce5fec4b Fixed Vault Query over RPC using custom attributes. (#1066)
* Implemented Kryo custom serializers for Field and KProperty types.

* Adjusted KPropertySerializer to use kotlin member properties upon read() due to failing RPC tests.
Added additional Kotlin and Java tests (CordaRPCClient, StandaaloneCordaRPCClient)
Annotated schemas to be CordaSerializable (required when referencing as KProperty in custom queries).
Cleanup some outstanding compiler warnings.

* Added client RPC Java integration and smoke tests to build.

* Clean up compiler warnings in Java tests.

* Fixed incorrect assertion expectation.

* Backed out Field and KProperty custom serializers.

* Backed out Field and KProperty custom serializers.

* Store VaultQueryCustom custom column references as name and class (from Java Field and Kotlin KProperty1 types respectively).
Custom serialization of Field and KProperty type no longer required.

* Removed blank lines as per RP review comments.
2017-07-17 18:20:02 +01:00
Shams Asari
195189070a Moved the Path extension methods that were in Utils.kt into the internal package 2017-07-17 16:01:19 +01:00
Mike Hearn
2cbdb719c6 Minor: move some test functions for making zips out of the global namespace. 2017-07-14 18:21:33 +01:00
Matthew Nesbit
e919d23d1f Fix a couple of tests that fail after the broadcast phase of finality flow has returned.
Remove redundant namespace on symbol
2017-07-14 10:15:28 +01:00
josecoll
d6deeb2bd6 Fixed failing SmokeTests using Vault Query (#1032)
* Fixed failing SmokeTest caused by incorrect default count filter.

* Fixed incorrect spend value for expected assertion.

* Remove deprecated test (unintentionally merged after rebase from master)
2017-07-12 18:11:04 +01:00
Patrick Kuo
78ecff7933 Added composite key provider for storing composite keys in keystore (#1006)
* Add unit tests around decoding composite keys

(cherry picked from commit 9ccdd8e)

* Start writing a Composite signature scheme

(cherry picked from commit 72ac3a5)

* Composite key serialisation

* refactoring

* * Address PR issues

* * Address PR issues

* * Address PR issues

* * Address PR issues

* fix up after rebase
2017-07-12 12:13:29 +01:00
josecoll
5f7b8f6ec3 Vault Query Pagination simplification (#997)
* Pagination improvements (fail-fast on too many results without pagination specification)
* Fix incorrectly returned results count.
* Performance optimisation: only return totalStatesAvailable count on Pagination specification.
* Changed DEFAULT_PAGE_NUMBER to 1 (eg. page numbering starts from 1)
* Changed MAX_PAGE_SIZE to Int.MAX_VALUE
* Fixed compiler WARNINGs in Unit tests.
* Fixed minimum page size check (1).
* Updated API-RST docs with behavioural notes.
* Updated documentation (RST and API);
2017-07-12 09:53:15 +01:00
Shams Asari
7caee508ec Refactored ErrorOr into Try, with Success and Failure data sub-classes, and moved it into core.utilities 2017-07-11 12:10:38 +01:00
Andrzej Cichocki
d2869e4f45 Refactor then/success/failure (#984)
to make ListenableFuture replacement less fiddly.
2017-07-07 15:50:50 +01:00
Andrzej Cichocki
cefa14507a Retire HostAndPort (#962)
* Don't attempt to parse a resolved InetSocketAddress toString
* A mock node isn't reachable via an address
2017-07-07 15:11:07 +01:00
Shams Asari
7822118835 Moved random63BitValue() to CryptoUtils 2017-07-07 12:19:55 +01:00
Shams Asari
8f1529b863 Moved ByteArrays.kt to core.utilities 2017-07-06 17:58:18 +01:00
Shams Asari
2973755bc8 Moved TestConstants.kt from core into test-utils 2017-07-05 11:54:43 +01:00
Clinton Alexander
b4e7d7ca1b Can now publish to artifactory. 2017-07-03 18:12:56 +01:00
Clinton
c1088038b7 Cordapps now contain their own dependencies (#915)
* Cordapps now contain all explicitly specified dependencies (and sub
dependencies).

* Removed some useless compile dependencies for trader demo.

* Dependent Cordapps are excluded from the build.
:Removed unnecessary dependencies of demos.

* Cleaned up exclusion rules for cordapp dependencies.
2017-06-30 14:18:46 +01:00
Shams Asari
a08f701dc5 Removed the StorageService and puts its components directly into the service hub 2017-06-30 09:37:29 +01:00
Ross Nicoll
698fe7846a Correct usage of notary legal and service identities
StandaloneCordaRPClientTest attempted to use a notary legal identity as service identity, which fails as
the service is separate. This separates the two usages correctly.
2017-06-28 18:36:22 +01:00
Ross Nicoll
1a4965c294 Change CashIssueFlow to use anonymous identity
* Add functions for:
    * Retrieving nodes via their legal identity
    * Filtering a set of public keys down to those the node has corresponding private keys for
* Modify contract upgrade flows to handle identifying participants after an anomymisation step
* Correct terminology: "party who" -> "party which"
* Modify CashIssueFlow and CashPaymentFlow to optionally use an anonymous identity for the recipient.
2017-06-28 13:47:50 +01:00
Andrzej Cichocki
0aadc037ef Make logging available in IntelliJ between gradle clean and assemble (#929)
* Enforce absence of node from client rpc smokeTest classpath
2017-06-28 09:54:09 +01:00
josecoll
1866f6ff7f Align CordaRPCOps Vault Query API's for Java/Kotlin with VaultQuery service equivalents. (#914)
Added Kotlin extension functions for ease of use in simplest case.
Added missing Java contractType class (previously was forced cast of ContractState::class)

Fixed generic typing.

Addressed items raised in SA PR review.

Removed 2 blank lines.

Fixed generics typing.

Updates RST doc and grouped API helpers accordingly.
2017-06-23 14:35:55 +01:00
Andrius Dagys
aaf7de0d02 RPC server: buffer response messages until the client queue is fully set up.
The issue arises when the server restarts, and the client is sometimes
not able to recreate its queue in time, so the server is unable to send
back a response message and just drops it, causing the client to hang.
2017-06-22 11:26:04 +01:00
josecoll
f8ad5c9d10 Vault Query Service JPA implementation (#840)
* Vault Query Service API implementation using JPA Hibernate

Added queryBy(QueryCriteria) Vault API and Junit tests.

Minor cosmetic API changes following rebase.

Fixes following rebase from master

Upgraded to requery 1.3.1

WIP - removed 'latestOnly' from LinearStateQueryCriteria

WIP - CommercialSchemas V2, V3, V4 testing

WIP - sort out generics handling.

WIP - most general queries completed.

WIP - join queries, contractStateType derivation

WIP - refactoring Requery

WIP - refactored VaultService to extract a VaultQueryService interface (and associated Requery implementation).

WIP - HibernateVaultQuery implementation

WIP - Re-structured all Schema definitions (requery/jpa) and make Hibernate Config reusable.

WIP - Multi-version schema testing, hibernate query testing.

WIP - Custom Criteria and Fungible Criteria impl & testing.

WIP - Kotlin Comparable Generics error

WIP - Party queries all working now

WIP - All VaultQueryTests now working (refactored for AND / OR composition)

WIP - added schema registration in CordaPluginRegistry to enable custom vault queries on arbitrary schemas.

WIP - added new default Sort NULL order to be NONE + added lots more tests for Logical Operator testing.

Mostly identity fixes following rebase from master.

Exception handling and public API cleanup in prep for PR.

Additional tests for Logical Operators; additional tests for NULLS sort ordering; additional logging;

Additional parser to handle Nullable attribute values; added Unary and Collection logical expression handlers

Lots of cleanup: participants; trackBy interfaces; additional fungible tests; parser cleanup and improved support for Java

Removed all traces of Requery implementation.

Further minor cleanup and Junit test fix.

Final identity and schema related identity clean-up.

Revert unrelated changes.

PR review updates: blank lines, isRelevant.

Fixed wiring of updatesPublisher for dynamic trackBy queries.

PR review changes: multi-versioned schema samples and associated dummy contracts moved to test packages.

Fixed problem with sorted queries (not specifying any filterable criteria).

PR review: minor updates to address RP comments.

Typesafe custom query criteria

Cleanup: remove redundant tests.

Further clean-up and make all Java test work successfully.

Remove debugging print statements.

Rebased from master - changes required due to DealState module change.

fixed broken assertion caused by DealState ordering change (different package)

Fixed transaction demarcation issue causing "java.lang.IllegalStateException: Was not expecting to find existing database transaction on current strand"

trackBy() now filters on ContractType and StateStatus (CONSUMED, UNCONSUMED, ALL)

Added tests to exercise RPCOps trackBy and queryBy (RPC smoke test and CordaRPCOps)

Added additional @CordaSerializable annotations.

Updated documentation and referenced sample code.

Added deprecation annotations.

Re-added missing deprecation annotation.

Hibernate debug logging is now configurable and disabled by default.

Introduced common Sort attributes based on the node schemas.

Completely removed NULL_HANDLING sort parameter as this is not supported in JPA.

Revisited and fixed usage of @CordaSerializable.

* Minor fix following rebase from master.

* Remove blank line as per RP PR feedback request.

* Minor Java documentation and example clean-up.

* Disable BFT Notary Service tests.
2017-06-22 10:35:49 +01:00
Katarzyna Streich
ab1b7eb551 Move all changes unrelated to flow view in explorer to open source. 2017-06-20 18:01:49 +02:00
Andras Slemmer
4dc06ed25b Merge pull request #703 from corda/aslemmer-in-process-driver-nodes-performance-tests
driver, node: Allow in-process starting of nodes, add a couple of node performance tests
2017-06-20 14:57:54 +01:00
Katarzyna Streich
20403d806a Cleanup of the explorer code related to internal flow view work. (#832)
Cleanup of the explorer code related to internal flow view work.
Changes in simulation, widgets, minor visual.
2017-06-20 10:45:42 +01:00
Andras Slemmer
70717cf33f driver, node: Allow in-process starting of nodes, add a couple of node performance tests 2017-06-19 13:45:48 +01:00
Matthew Nesbit
6933c8fda3 Move all advanced finance types into finance module.
Fixup after rebase

Also pull in the interpolator code, which is used for financial calculations.

Fix up rebase
2017-06-16 11:19:24 +01:00
Clinton
a6853be035 Merge pull request #834 from corda/clint-irswebfix
IRS web demo now shows fixings + general IRS fixes
2017-06-15 17:49:43 +01:00
Shams Asari
b52d3706eb Moved Driver.kt to net.corda.testing.driver in the test-utils module 2017-06-14 15:12:39 +01:00
Mike Hearn
475044597d Address review comments. 2017-06-13 16:19:55 +02:00
Mike Hearn
ccf43a8e17 Support fuzzy matching for identities.
Matching can be done with case insensitive substrings in the identity service, RPC and shell. In future cleverer matching should be possible, e.g. using Lucene or RDBMS free text search features.
2017-06-13 16:19:55 +02:00
Clinton Alexander
fffcfff269 Added correct json support fields to allow deserialisation of IRS data via Jackson. 2017-06-12 20:56:07 +01:00
Clinton Alexander
5fdd57ec48 WIP - squash me. 2017-06-08 18:29:26 +01:00
Andrzej Cichocki
bc4aed92dc Retry occasionally-failing test until we upgrade Artemis (#816) 2017-06-08 17:08:56 +01:00
Andrzej Cichocki
65fe7d6b81 Test that reliably fails with Artemis 2.1.0 (#797) 2017-06-07 16:49:57 +01:00
Shams Asari
afa3efb308 Fixes relating to testing flows and services.
Fixed issue where Corda services installed in unit tests were not being marked as serialise as singleton. Also the driver now automatically picks up the scanning annotations. This required moving the NodeFactory used in smoke tests into a separate module.
2017-06-06 15:22:43 +01:00
Clinton
08cbcac40c Corda publications and JARs now have cord or corda at the start. (#749)
Core corda publications and JARs now have cord or corda at the start (excluding gradle plugins). Removed an unnecessary dependency on test-utils in node-schemas to prevent an evaluation order bug in gradle.
2017-06-06 15:05:47 +01:00
Chris Rankin
20b806cb62 Make RPC client reaper threads into daemons so that they don't block JVM shutdown. (#781) 2017-06-01 17:57:38 +01:00
Chris Rankin
0fd897527a Extend smoke test to cover opening attachments. (#760) 2017-05-30 14:55:58 +01:00
Ross Nicoll
a8d4dccea4 Infrastructure for confidential identities
* De-anonymise parties in AbstractStateReplacementFlow flows
* Convert transaction key negotiation to a subflow instead of utility functions
* Add serialization support for CertPath
* Restructure cash flows so that a counterparty flow can be added later
2017-05-26 10:00:57 +01:00
Mike Hearn
e141fc1549 Minor: suppress some warnings and wrap an exception in the Jackson code. 2017-05-19 16:45:22 +02:00
Mike Hearn
3636f137b0 Minor: add a unit test for the StringToMethodParser code as used with c'tors. 2017-05-19 16:45:22 +02:00
Chris Rankin
edf269dbe5 Wrap any checked exception inside an unchecked RPCException. (#700) 2017-05-18 14:11:22 +01:00
Ross Nicoll
c13a99a2f9 Replaces keys and parties in states with AbstractParty
Switch to using AbstractParty as the standard identifier for parties in
states, so that full parties can be used during construction of
transactions and anonymised parties when the transaction is being added
to the ledger.
2017-05-16 12:07:14 +01:00
Andrzej Cichocki
d3bb040355 Refactoring related to BFT notary demo (#680)
* Fix: Add missing @StartableByRPC to fix the Raft notary demo
* Make loadConfig take a Config object, for cordformation Node
* Unduplicate User.toMap
* Unduplicate WHITESPACE regex, choose possessive form
* Use slash to make a Path
* Remove Companion where redundant
* Remove unused code
2017-05-16 11:30:50 +01:00
Andras Slemmer
63d5aa03e9 Merge pull request #665 from corda/aslemmer-cleanup-rpc-resources-on-startup-failure
RPC: call close() on startup failure, add thread leak tests
2017-05-15 19:18:37 +01:00
Andras Slemmer
f445590cff Address #665, add more leak tests 2017-05-15 15:20:00 +01:00
Chris Rankin
e995eac5d0 Update smoke tests to run correctly on Windows. (#684) 2017-05-15 13:48:40 +01:00
Andras Slemmer
b192a86a30 Address comments #665 2017-05-15 13:18:45 +01:00
Andras Slemmer
8a17406246 Address comments #665 2017-05-15 13:18:45 +01:00
Andras Slemmer
7c3a566197 RPC: call close() on startup failure, add thread leak tests 2017-05-15 13:18:45 +01:00
Andras Slemmer
abe568a7c8 Merge pull request #672 from corda/aslemmer-fix-rpc-docs
Fix RPC documentation
2017-05-12 13:09:33 +01:00
Chris Rankin
1c87d4f9c5 Add simple smoke tests for CordaRPCClient. (#667) 2017-05-12 10:27:41 +01:00
Andrzej Cichocki
1df29ab06f Make webserver reconnect to rebooted node. (#662) 2017-05-12 10:27:27 +01:00
Andras Slemmer
ee121473d1 Fix RPC documentation 2017-05-11 17:44:45 +01:00
Ross Nicoll
e4a0bc6e11 Move party classes into identity package
Move AbstractParty, AnonymousParty and Party into a new net.corda.core.identity package,
as they're not really cryptography tools, and in preparation for further code coming in
for identity.

Optimize imports on many files to clean up the resulting refactor.
2017-05-11 11:25:59 +01:00
Shams Asari
e75732af91 Making sure non-serialisable objects in FlowException do not interfere with the flow session (#651)
Also TransactionVerificationException no longer has reference to non-serialisable LedgerTransaction
2017-05-10 11:07:28 +01:00
Andras Slemmer
3a2afcdbb2 #592: Address more comments 2017-05-05 17:10:52 +01:00
Andras Slemmer
34517f653a #592: Address more comments 2017-05-05 17:10:52 +01:00
Andras Slemmer
de88ad4f40 RPC muxing, multithreading, RPC driver, performance tests 2017-05-05 17:10:52 +01:00
Ross Nicoll
25dbac0f07 Change party to hold an X.500 name
Change the legal name of parties to be an X500 name. This ensures that we aren't converting between
common names and X500 names in various places, eliminating substantial scope for error in the conversion
process. As a result, all node names must now be full X500 names, which has impact on most configurations.
2017-05-05 16:13:29 +01:00
Ross Nicoll
b64e7f51f6 Enforce X.500 distinguished names in configuration 2017-05-05 16:13:29 +01:00
Konstantinos Chalkias
d8fa75654f Support for multi-sig schemes. ECC (K1/R1) and EdDSA are fully supported. (#599)
Support for multi-sig scheme. ECC (K1/R1) and EdDSA are fully supported.
2017-05-04 18:19:00 +01:00
Matthew Nesbit
7e3b9a8934 Fix duplicate content root problems in IntelliJ 2017-04-26 10:37:16 +02:00
Mike Hearn
922a760a09 Shell: more aggressive catch/rethrow of errors during command line parse. Avoids stack traces being dumped to the console when an unknown party name is provided. 2017-04-25 19:43:26 +02:00
Katarzyna Streich
c1b7b1cb75 Add information on who started flow on a node. (#549)
* Add information on who started flow on a node with name where possible.
Add sealed class holding information on different ways of starting a flow: RPC, peer, shell, scheduled.

* Remove invokeFlowAsync from ServiceHub, move it to ServiceHubInternal.
We shouldn't be able to start new state machines from inside flows.
2017-04-24 17:05:51 +01:00
Ross Nicoll
684d1089f0 Introduce full legal names for test parties
Use full names for test parties, ahead of complete X.500 name support.
2017-04-24 15:18:21 +01:00
Chris Rankin
d2d7cbc9ec CORDA-299: Remove progress Observable from FlowHandle, unless explicitly requested. (#513)
* Remove progress Observable from FlowHandle, unless explicitly requested.
* Refactor FlowHandle creation into FlowStateMachine.
* Prevent server-side queue subscription for dummy Observable.
* Refactor so that RPC client does not receive any unused progress Observables. This is the simplest way of ensuring we have no dangling "hot" Observables when the RPC client closes.
* Test flow has correct handle.
* Resolve some compiler warnings.
* Document how starting a flow does not involve progress tracking by default.
* Update changelog and release notes for RPC API.
* Rename new RPC API to startTrackedFlow().
* Remove optimisation because of its affect on the client-side.
* Update documentation.
2017-04-19 20:11:51 +01:00
Ross Nicoll
d35bd74596 Standardise identities used in tests, demos, etc.
Standaridise the identity names of Alice, Bob and Charlie, notary, map service, etc. in order
to ensure consistency across the code base and reduce number of places that have to be changed
to introduce proper X.500 names.

Move Alice, Bob & Charlie identities into the utilities package so they can be used in demos
2017-04-12 11:40:48 +01:00
kasiastreich
36d5d0d7b2 Refactor of CompositeKeys to implement PublicKey interface. (#433)
* Make CompositeKey implement PublicKey

The initial implementation of composite keys as their own distinct class separate from PublicKey
means that the keys cannot be used on standard classes such as Certificate. This work is a beginning
to modifying CompositeKey to being a PublicKey implementation, although significant further work
is required to integrate this properly with the standard Java APIs, especially around verifying
signatures using the new key type.

* First stage of making CompositeKey implement PublicKey interface. Revert to using PublicKey everywhere we expect a key.

* Move algorithm and format into companion object (#432)

Move algorithm and format into companion object so that they can be referenced from other
classes (i.e. the upcoming signature class).

* Add simple invariants to construction of CompositeKey.
Builder emits CompositeKeys in simplified normalised form. Forbid keys with single child node, force ordering on children and forbid duplicates on the same level. It's not full semantical normalisation.

* Make constructor of CompositeKey private, move NodeWeight inside the class.
Add utility function for Kryo deserialization to read list with length constraints.
2017-04-12 11:13:20 +01:00
Mike Hearn
c80b3b787c Minor: work around a type inference bug in Kotlin 2017-04-11 15:53:05 +02:00
Mike Hearn
cf4363dc2e Minor: more helpful warning when an observable is leaked. 2017-04-11 15:53:05 +02:00
Mike Hearn
0c0c5521c0 Minor: address more formatting issues spotted by Shams 2017-04-11 15:53:05 +02:00
Mike Hearn
c097229935 Minor: run code cleanup inspections 2017-04-11 15:53:05 +02:00
Mike Hearn
6f200562b3 Minor: auto-format of module: client 2017-04-11 15:53:05 +02:00