* We were leaving trailing attachmentStorage on pooled kryo instances after some tests. Changed attachment storage logic to make it impossible to leave it behind.
* Some low level tests corrupt the Kryo config, so do not return to pool when this is the case. Also, we discovered that Kryo is caching class name to class resolution. We don't want to do this where attachments are involved. The errors raised highlighted a class missing from the whitelist. Need to write a unit test to test the class loader issue.
* Unit test for attachment class loading with kryo.
* Non-ssl artemis acceptor for RPC connection. (#271)
* New non-ssl acceptor in artemis server for RPC connection.
* Rename artemisAddress with messagingAddress
Rename artemisAddress with messagingAddress so that the node configuration file properties match
the code variable names.
Rename artemisPort to messagingPort in Gradle configuration to match node configuration naming.
* Add rpcPort configuration option for Gradle
* Update docs to reflect changes to RPC port configuration
* Renumber ports in example CorDapp to match numbering used elsewhere
* Restructure upgrade guide
* added config file checks on corda startup to make the upgrade path a bit smoother.
Add Capsule configuration for the webserver JAR, so that the classes-only `webserver.jar` is published as well
as the full fat `corda-webserver.jar`. This is required for running the tutorial/template from IntelliJ.
Convert NodeVaultService states to return Iterable (backed by Sequence) Vs the old way using a List. Worth noting this relieves memory pressure as the number of vault states grows.
* remove toList in ContractUpgradeFlowTest
Basic crypto API to support 5 signature schemes and MetaData-ed signatures.
Supported schemes: (1) RSA_SHA256, (2) ECDSA_SECP256K1_SHA256, (3) ECDSA_SECP256R1_SHA256, (4) EDDSA_ED25519_SHA512, (5) SPHINCS-256_SHA512.
To sign a transaction, a signer should create a MetaData wrapper that contains transaction's merkle root and some extra information, such as signer's public key, timestamp and visibleInputs. Actually, MetaData is utilised to support a practical partial, blind and extra-data attached signature model.
When a MetaData object is signed, the signer sends a TransactionSignature object that contains the signed output and the corresponding MetaData object.
Remarks:
This is an temporary solution for signature algorithmic agility. Further development is required for a robust and extensible Crypto Manager/Provider PKI that will support certificate creation, key generation, signing/verifying, deterministic key derivation, encoding formats, SGX/HSM support, identity and key management, versioning, revocation, asynchronicity, metadata, partial sig. policies etc.
* QueuedObservable could not leak due to hard references. Have made it weak referenced but also had to reference count a hard reference to prevent early GC. Explained in comments.
* Improved comments.
* Fixed typo
* Fixed another typo
* CORDA-265: Implement "ALL" permission for RPC users. Users with this permission in node.conf can use any flow.
* CORDA-265: Ensure that we always close the RPC proxy object after each test.
* CORDA-265: Refactor construction of dummy RPC client into an abstract base class.
* CORDA-265: Document RPC "ALL" permission.
* BFT notary prototype: add a non-validating service.
Each replica now validates the transaction timestamp and returns an individual signature to the BFT client. The client then returns a list of signatures back to the notary service flow.
The validating variant is still incomplete - it requires the ability to suspend flows on arbitrary function calls.
* Exclude old version of Javassist in favour of Hibernate's version.
* Comment why we are excluding javassist:javassist, and add TODO for when junit-quickcheck 0.8 is released.
Make notary flow return a collection of signatures to support the BFT notary. For a single-node or RAFT notary it would just contain a single signature.
* Make the network registration process more verbose
* removed gradle task for building standalone jar for the certificate signing request utility
* Added a flag "--initial-registration" to the corda jar to start the registration
* Initial prototyping with Requery as a persistence replacement for Exposed/Hibernate
Applied changes following PR review by RP
Updated timestamp naming (removed committedTimestamp) and StateStatus (removed AWAITING_CONSENSUS) after discussion with RP.
Removed FungibleState and LinearState schemas (and associated tests) - awaiting Requery uni-directional relationship fix.
Added Transaction propagation such that requery re-uses any existing transaction context.
Made requery default logging configurable (disabled by default)
Nullable fields are now truly nullable (in the Kotlin and DDL sense)
Fix for SimmValuation integration test.
Workarounds applied to resolve Requery issues when sharing Transactional context.
Addressed PR review comments from MH.
Further updates following re-review by RP/MH
Further updates following additional PR review comments by RP
Minor update following additional PR review comments by RP
Optimised makeUpdate state processing code.
Resolved conflicts after rebase.
Additional Unit tests and bug fix for correct spending of multiple contract state types within a single transaction.
Required interface change to states() API to take a setOf (ContractStateClassTypes)
Minor code clean-up.
Re-write NodeVaultService consumed state makeUpdate function using SQL.
* Resolve conflict after rebase from master
* Added missing out modifier to UpgradedContract class
* Added ContractUpgradeFlow.Instigator to whitelist in AbstractNode
* Added test for contract upgrade using RPC
* Add support for contract upgrades
* Add interface for the upgraded contract to implement, which provides functionality for upgrading legacy states.
* Add shared upgrade command and verification code for it.
* Add DummyContractV2 to illustrate what an upgraded contract looks like.
* Add new functions to vault service to support upgrading state objects.
* Add contract upgrade flow
Split CashFlow into independent CashIssueFlow, CashExitFlow and CashPaymentFlow,
so that users can be given access to one but not the other(s).
Signed-off-by: Ross Nicoll <ross.nicoll@r3.com>
Add AnonymousParty superclass of Party in preparation for anonymising parties stored in
contract states.
Signed-off-by: Ross Nicoll <ross.nicoll@r3.com>
* Add webAddress back to NMS as it shifts the port allocation for all subsequent nodes and causes all demos to break.
* Attachment demo: fix node names
* Notary demo: fix certificate paths & ports
* IRS demo: role decider fixed to allocate roles properly. Previously it used to pick current node as the Fixer, causing both nodes to initiate the trade flow, resulting in double spend exceptions..
Make FinalityFlow do more, and be used more consistently.
Add a new waitForLedgerCommit API that is intended to be used at the end of flows, or at any other point where a flow wants to wait for a transaction to finalise (but the finalisation flow is being done by someone else).
Update the docs a bit.
* Prevent node from starting across upgrades (until we support it better).
On first run a version file is created in the node dir, and on subsequent runs the node version is matched against it.
* Move version check from caplet to node.
InMemoryNetworkMapCacheTest was not actually asserting that an expected exception was thrown, which
meant when earlier changes to the service changed the operation it wasn't caught. The service now
overwrites previous node if a new matching node is added, and this updates the test to follow that
design.
Change Party instances to be uniquely identified by the owning key, without taking into account name.
This requires that mock node key generation is reworked so that keys for services and the node itself
are distinct, otherwise the network map service cannot differentiate them.
Signed-off-by: Ross Nicoll <ross.nicoll@r3.com>
Remove TransferRecipient from StateMachineManagerTests to get rid one of the approximately 6 different ways
in which we refer to endpoints, as part of work to simplify this data model.
Signed-off-by: Ross Nicoll <ross.nicoll@r3.com>
* Add logging to avoid node startup "hang" when it attempt to connects to the network map, also can use as a hint telling user Network map might be down or unreachable.
This reveals that building the first RPC client is ludicrously slow (like 1.8 seconds) but subsequent builds are more like 30 msec. This might be interpreter overhead, or it might be due to Artemis/SSL doing lots of piggy lazy initialisation or something. But at any rate it may be worth investigating a bit later.
* Update notary change flow to support encumbrances.
Move encumbrance pointer from ContractState to TransactionState.
* Refactor & add new encumbrance tests
Check that the SMM.add method is being called on the SMM thread and throw if not. Make ServiceHubInternal.startFlow() do a blocking call onto the server thread. Update unit tests.
This resolves an issue whereby the scheduler was starting flows outside of the server thread, which isn't intended.
Initial conversion of Explorer to use IssuerFlow (from BankOfCorda)
Initial conversion of TraderDemo to use IssuerFlow (from BankOfCorda)
Updated TraderDemo to use IssuerFlow (from BankOfCorda)
Fixed TraderDemo integration text (added new BankOfCorda node)
Updated Explorer with changes IssuerRequest params
Explorer now correctly displaying transaction id upon Issue.
Moved IssuerFlow into finance package so can be reused across multiple demos (TraderDemo) and applications (eg Explorer)
Refactored BankOfCorda demo to use Finance package and TestUtil constants
Updated TraderDemo to use IssuerFlow
Updated Explorer to use finance package IssuerFlow.
Advertised BankOfCorda as Issuer for usage by Explorer.
Explorer no longer depends on BankOfCorda demo since IssuerFlow promoted to Finance module
Added IssuerFlow to AbstractNode whitelist.
Explicit declarations of IssuerFlow no longer required.
Added plugin registration of IssuerFlow at bootstrap.
Revert whitelisting of IssuerFlow (plugin configured)
Refactored to use constant BOC definition.
Added gradle RPC security config.
Updated documentation
Fixed incorrect references.
Renamed Issuer banks.
Added new permission set (for Issuer nodes)
Added node nearestCity info
Added new Issuer Event Generator for Issuer nodes only
Associated currency with issuer using ServiceType naming structure.
Added argument flag (-S) to trigger event generator simulation node.
Fixed problem with issuers not resolving from network map.
Updated perms on Issuer rpc proxy nodes.
Fixed minor in cash generateExit identified by Explorer.
Changes applied in prep for AWG demo.
Added IntelliJ run-configurations for launching Explorer demo nodes (with and without simulation)
Updated documentation (and added additional gradle task to launch Explorer nodes in simulation mode).
Fix following rebase.
Addressed review items from PR.
Updated TraderDemo readme.
Updated TraderDemo gradle file to launch Bank of Corda node.
Updated JRE properties.
Updated IssuerModel to incorporate correct JFX Observable handling.
Fixed bug with Exit command not displaying any currency.
Added TODO's for revisiting correct Exception handling strategy.
Optimization for when issuing cash to self.
Minor updates following PR review.
Remove old refs to Royal Mint and Federal Reserve
Increase JDBCHashMap default bucket size. With the current implementation of the Vault, once the number of stored transactions (or UTXO) goes over the max bucket size we end up reloading each transaction from the db and deserializing it, which causes severe performance degradation.
Add unit tests of ScheduledFlow running on simulated network.
Just use existing DumyContract in test
DummyContract requires value equality so that assertEquals over states works as expected.
Remove blank line.
Add TODO on waitQuiescent.
Fix minor build error
"CAPSULE EXCEPTION: Could not find Java installation for requested version [Min. Java version: 1.8.0 JavaVersion: null Min. update version: {}] (JDK required: false). You can override the used Java version with the -Dcapsule.java.home flag. (for stack trace, run with -Dcapsule.log=verbose)"
which isn't awesome either but at least tells the user what to do.