Commit Graph

1697 Commits

Author SHA1 Message Date
LankyDan
f4d9ed1660 Add missing change to RunShellCommand that was not included in backport
When backport the `CheckpointDumper` change, the code in `RunShellCommand`
was not changed correctly. This led to shell not listing all available
commands. They were still available to execute but were not visible.
2019-07-18 16:25:59 +01:00
Dan Newton
43dfd636dc CORDA-3083: Backport dumpCheckpoints shell command (#5305)
This is a port of https://github.com/corda/corda/pull/5171 with some further improvements like printing out the contents of all the flows in the sub-flow stack (rather than just the current progress tracker step) and better error handling.
2019-07-18 10:42:14 +01:00
Shams Asari
2b36b6d8cf
CORDA-3092: Exception is logged if flow session message can't be deserialised (#5309) 2019-07-17 18:14:12 +01:00
Chris Rankin
f378f0eba6 BUILD: Try to fix flaky FailNodeOnNotMigratedAttachmentContractsTableNameTests.
* Ensure that this test stops nodes that it starts.
* Also ensure that random ephemeral ports can be reused.
2019-03-22 14:54:50 +01:00
Andrius Dagys
7e4a5413ac CORDA-2109 - Fix a bug that prevents consecutive multiparty contract upgrades (#4131)
The contract upgrade handler assumes that the state to be upgraded is
created by a WireTransaction. This breaks the upgrade process if it was
in fact issued by a ContractUpgradeWireTransactions or a NotaryChangeWireTransaction.
2018-10-30 10:14:03 +00:00
Patrick Kuo
262427fc12 CORDA-2071 - Log file filling with Artemis messages and rolling over quickly (#4034)
* ENT-1850: Improve reporting of connection problems (#3124)

* Add nicer logging for SSL handshake problems

* Just in case let people see the horrid netty exception traces at trace level

(cherry picked from commit 3c005789c0)

* fixup after cherrypick

* Prevent bridge reconnection attempts on targets that present invalid/misconfigured/different certificates to protect nodes from dead identities. (#3225)

(cherry picked from commit 7ff008d4e3)

* fixup after cherrypick

* add extra error handling (copied from master)
2018-10-05 12:58:36 +01:00
Tudor Malene
64fc9009a1 CORDA-1297 - revert column nullability (#4030)
* CORDA-1297 revert column nullability

* CORDA-1297 address code review comments

* CORDA-1297 address code review comments
2018-10-04 16:30:45 +01:00
Michal Kit
dbda50d92e CORDA-2012 - copying all from the network trust store (#3991) 2018-09-27 15:51:24 +01:00
Katarzyna Streich
df343379d2 CORDA-1563, CORDA-2029 - backports to 3.3 (#3990)
* CORDA-1563 : Don't remove own node info - fix (#3219)

* CORDA-2029: Don't remove own node info

Don't remove own node info from cache on network map update.

* ENT-2014 Deletes of NodeInfo can fail to propagate leading to infinite retries (#1101)

* ENT-2014 Deletes of NodeInfo can fail to propagate leading to infinite retries
ENT-1880 Move identity key generation to network registration process

(cherry picked from commit c3ac203)

NOTE: Moved ENT Jira's to OS project
2018-09-26 11:11:32 +01:00
Stefano Franz
a11df32dd6 CORDA-1811 - If a second identity is mistakenly created the node will not start 2018-09-18 17:55:05 +01:00
Florian Friemel
8f2977eac2 CORDA-1572 - Create marker file to track initial registration status. (#3621) (#3883)
[CORDA-1572] Create marker file to track initial registration status.
2018-09-13 13:47:52 +01:00
josecoll
cb4db31b3b CORDA-1892 - CRaSH shell flow start fix for similar flow names. (#3874) (#3928)
* CORDA-1892 CRaSH shell flow start fix for similar flow names. (#3874)

* Added fix and associated unit test.

* Fixed broken unit test + added another test case + used NoOpFlows + use Mock output object to assert correct result output.

* Remove unnecessary additional println.

* Minor cleanup in test code.

* Relax nameFragment matching to cater for fully qualified and simple Flow classname specifications.

* Remove superfluous check.

* Minor fix + added additional Unit Test cases to cover all scenarios.

* Reverted back to original behaviour + extra check to avoid ambiguity for exact match.

* Changes following final PR review comments.

* Revert to non visible latch as no associated integration tests defined in this release.
2018-09-13 13:46:39 +01:00
Tudor Malene
50d3f7b474 CORDA-1976 - Fix flaky test (#3935) 2018-09-13 13:43:59 +01:00
Katelyn Baker
eac9d1b93c
CORDA-1093 - Deleting node info from directory (#3115) (#3921)
* CORDA-1093 Deleting node info from directory

Deleting NodeInfo from additional-node-infos directory should remove it from cache.
2018-09-13 13:43:20 +01:00
josecoll
fadeda73fd CORDA-1858 - Vault query fails to find a state if it extends from cla… (#3868)
* CORDA-1858 - Vault query fails to find a state if it extends from class (#3722)

* Included Contract State parent classes in list of queryable types.

* Added changelog entry.

* Fixed compilation errors post cherry-pick.

* Fixed failing unit tests following cherry-pick.
2018-09-10 10:21:11 +01:00
bpaunescu
a3ec8bf9bd CORDA-1875 - backport tweaks made to RPC client for handling loss of node (#3916)
* CORDA-1875: backport tweaks made to RPC client for handling loss of connection to the node

* CORDA-1875: backport missing code
2018-09-10 10:20:16 +01:00
Patrick Kuo
205d3c3797 CORDA-1604 Node Info file watcher should block and load node info when node startup (#959) (#3333) (#3879)
(cherry picked from commit 2fce979)

(cherry picked from commit 072b4207e0)
2018-09-06 11:13:22 +02:00
Michal Kit
6d43a654ff CORDA-1938 Adding version info to the node info submission request (#3854) (#3885) 2018-09-06 11:12:56 +02:00
Michele Sollecito
0df77d5b64
Backports: CORDA-1663, CORDA-1638, CORDA-1542 (#3881) 2018-09-03 16:15:03 +01:00
josecoll
80c6c46d6f CORDA-1888 - Fix Vault Query composite queries (#3775) (#3869)
* CORDA-1888 Fix Vault Query composite queries  (#3775)

* Reproduce composite query failures.

* Fixes to OR querying and composite queries that use the same QueryCriteria (Linear, Fungible, Custom) more than once.

* Revert debug logging for Hibernate SQL.

* Cleanup and remove redundant joinPredicates global var.

* Fix failing Java Unit test.

* Fix Java compilation error in example-code section of docs.

* Include copy() function for original constructor to maintain backwards API compatibility.

* Fixed compilation errors post cherry-pick.
2018-08-30 16:00:50 +01:00
Katelyn Baker
940bb3bdbd
CORDA-1812 - fix Postgres db bloat issue (#3614) (#3857) 2018-08-30 12:00:09 +01:00
Chris Rankin
d15efcec10 CORDA-1907: Allow Corda's shell to deserialise using generic type information. (#3810) (#3827) 2018-08-22 11:43:41 +01:00
josecoll
e301977b17
Fix loadStates for large page sizes and added unit test. (#3788) 2018-08-16 10:14:17 +01:00
Roman Plášil
ec1e40109d CONTRIBUTION - Configure NetworkMapUpdater executor so that it doesn't block node shutdown (#3530) 2018-08-08 11:30:57 +01:00
Tudor Malene
11d59cf86a CORDA-1847 - Backport hibernate observer fix (#3726)
* CORDA-1847 Backport hibernate observer fix

* CORDA-1847 Fix tests
2018-08-06 11:51:01 +01:00
Katelyn Baker
f44cec5321
CORDA-1789 - Split Doorman / NM config - fix for CORDA-1510 (#3605) 2018-07-17 15:11:31 +01:00
Katelyn Baker
729d1b29a6
CORDA-1790 - Roll back flow transaction on exception (#3597) (#3616)
* CORDA-1790 Roll back flow transaction on exception

* CORDA-1790 Roll back flow transaction on exception

* CORDA-1790 Roll back flow transaction on exception
2018-07-16 17:44:34 +01:00
Michele Sollecito
3da07a1105
Merge pull request #3613 from corda/kat/bakport/corda-1804
CORDA-1499, CORDA-1804  (#3607)
2018-07-16 10:39:30 +01:00
szymonsztuka
fad90eee8b CORDA-1499, CORDA-1804 (#3607)
* Fix a typo in node_attchments_contracts table name. (#3202)

(cherry picked from commit 57d379597b)

* CORDA-1804 Corda node stops when detecting not migrated node_attachments_contracts table name (#3593)

Database table NODE_ATTACHMENTS_CONTRACT_CLASS_NAME in v3.0 was changed to NODE_ATTCHMENTS_CONTRACTS in v3.1 and then finally NODE_ATTACHMENTS_CONTRACTS on current master. Users may omit the upgrade note and run into errors. After the change the node will not start if the new table name is not found and any other older ones is found.

(cherry picked from commit 208ac49da0)

* Fixes after cherry-pick of 208ac49da0.
2018-07-16 10:06:34 +01:00
Katelyn Baker
c73647b4fe
CORDA-1628 - Increase max restart count for notary client flows. (#3357) (#3603)
This will ensure that the notary client flow will retry over a sufficient
period of time for the notary to update its network map.

With a backoff base of 1.8 and 5 retries the last retry will fire after
about 20 min 8 sec of the initial flow start:

0	30
1	54
2	97.2
3	174.96
4	314.928
5	566.8704

Total 1207.9584	= 20.13264 min
2018-07-13 18:13:41 +01:00
Shams Asari
9fc108aa1e CORDA-1709 - The MVP blob inspector, able to inspect network service blobs (#3503)
* Cleanup and improvements to the serialisation format of JacksonSupport (needed for CORDA-1238) (#3102)

Also deprecated all the public members that shouldn't have leaked into the public API.

(cherry picked from commit 3bb95c3)

* CORDA-1238: Updated JacksonSupport to support SerializedBytes, CertPath, X509Certificate and the signature classes (#3145)

SerializedBytes are first converted to the object it represents before being serialised as a pojo.

These changes will be needed to support the the blob inspector when it will output to YAML/JSON.

(cherry picked from commit b031e66)

* Cherry picked part of commit 824adca to port over *only* the JackSupport refactoring.

* CORDA-1238: Moved the blob inspector out of experimental and wired it to JackonSupport (#3224)

The existing output format was not complete and so was deleted to avoid it becoming a tech debt. We can always resurrect it at a later point.

(cherry picked from commit 4e0378d)

* Added back support for parsing OpaqueBytes as UTF-8 strings in JacksonSupport (#3240)

(cherry picked from commit d772bc8)

* Cleaned up blob inspector doc (#3284)

(cherry picked from commit b7fbebb)

* Blobinspector: trace level logging with --verbose (#3313)

(cherry picked from commit 6a2e50b)

* Cherry picked part of commit 3046843 to fix issue with --version

* Fixes to the api file
2018-07-03 19:58:13 +01:00
Katelyn Baker
f86aaa2866
CORDA-1510 - Allow Doorman and NetworkMap to be configured independently (#3494)
* CORDA-1510 - Allow Doorman and NetworkMap to be configured independently  (#3485)

Currently only one compatabilityZoneURL can be specified, however the
two services can be run on as separate servers. Allow nodes to be
configured in this manner

* Fix cherry-pick
2018-07-03 12:57:03 +01:00
Michele Sollecito
b6339a7fc6 CORDA-1575, CORDA-1341 - Fix logfiles for out of process nodes, Ensure API can be called concurrently wrt transactions.(#3312)
* [CORDA-1575]: Out of process nodes started by the driver do not log to file (fix).

* [CORDA-1341]: Ensure API can be called concurrently wrt transactions.

* [CORDA-1575]: Fixed unstable test.
2018-06-07 11:26:19 +01:00
szymonsztuka
588c480bcd CORDA-1499 - Fix a typo in node_attchments_contracts table name. (#3310)
(cherry picked from commit fc54263)
2018-06-06 16:03:25 +01:00
szymonsztuka
cdce596acd CORDA-1266 - When a cash output is identical only the fist output is saved. (#3244) (#3311)
(cherry picked from commit 0a4d981)
2018-06-06 16:02:50 +01:00
Maksymilian Pawlak
33e45eef4a CORDA-1297 - Columns nullability (#3112) -> V3 (#3303)
* [CORDA-1297] Columns nullability (#3112)

JPA/Hibernate entities need to impose the correct NULL/NOT NULL constraints on the database - whatever these correct values actually are.
API change: net.corda.core.schemas.PersistentStateRef fields (index and txId) are now non-nullable. Rationale: The fields were always effectively non-nullable - values were set from non-nullable fields of other objects. The class is used in context of database table Primary Key of for other entities and a database already imposes those columns as non-nullable (even if JPA annotation nullable=false was absent).

(cherry picked from commit 7d69bc6)

* Compilation fix
2018-06-05 15:55:20 +01:00
Katarzyna Streich
f132923b86 CORDA-866, ENT-1933 - Remove stale nodes from Network, Fix NetParam serialization (#3255) (#3128)
*  CORDA-866: Implement removal of stale nodes from network - backport (#3128)

* CORDA-866: Implement removal of stale nodes from network

Backported

* Implement removal of stale nodes from network

Add eventHorizon to NetworkParameters structure. Add republishing of
node info on 1 day intervals - it is treated by network map as heartbeat from node indicating if it's alive or not. Add removal of old node infos on network map signing.

* Add copy method to NetworkParameters data class

Add JvmOverloads annotation to the constructor, because it's data class
exposed in API

* Fix test

* ENT-1933: make NetworkParameters serialization compatible (#3234)

* ENT-1933: make NetworkParameters serialization compatible

* Fixes after cherry-pick
2018-05-31 10:03:51 +01:00
Michele Sollecito
76eaff6d88 Corda-1338 | Corda-1394 (#3205)
* [CORDA-1394]: Node can fail to fully start when a port conflict occurs, without a useful error message (fix).

* [CORDA-1338]: Error with VaultQuery for entity inheriting from CommonSchemaV1.FungibleState (fix).

* [CORDA-1338]: Error with VaultQuery for entity inheriting from CommonSchemaV1.FungibleState (fix).

* Attempting to fix weird recursive types problem.

* Attempting to fix weird recursive types problem.

* Attempting to fix weird recursive types problem.
2018-05-23 17:52:02 +01:00
Shams Asari
2729ada251 CORDA-1405 - Integration test for network parameter updates and improved logging (#2865)
(cherry picked from commit 620ba1e)

Also updated the toString() of NetworkParameters and NetworkMap to be better formatted.
2018-05-22 13:57:15 +01:00
Katelyn Baker
f9e0742d69
CORDA-1455 - Error in process-id deletion process allows multiple instances of same node to be run (fix). (#3118) (#3195) 2018-05-19 12:35:32 +01:00
Katelyn Baker
2d1ceb6cb0
CORDA-1342 - The shell doesn't print the return value of a started flow - fixed. (#3007) (#3197) 2018-05-19 12:35:12 +01:00
Katelyn Baker
35246460e2
Merge pull request #3189 from corda/cherrypick-corda-1397
CORDA-1397 - Fixed incorrect exception handling in `NodeVaultService…
2018-05-18 14:29:02 +01:00
Katelyn Baker
839cd04fdc
Merge pull request #3114 from corda/cherrypick-corda-1317
CORDA-1317 - Add cert role to CSR and doorman issue cert according to the cert role
2018-05-18 14:28:41 +01:00
Michele Sollecito
1700d30bc7 [CORDA-1397]: Fixed incorrect exception handling in NodeVaultService._query(). (#3043) 2018-05-18 12:14:47 +01:00
Katelyn Baker
d63ee71564
CORDA-1344 Fix query paging in scheduled flow tests (#2970) (#3096)
* Fix paging tests, move out of scheduled flow tests and provide java example

* Fix a few issues with docs
2018-05-15 15:57:27 +01:00
Katelyn Baker
c2b733d64c merge failure fix 2018-05-11 18:08:33 +01:00
Patrick Kuo
77a138a04e CORDA-1317 - Add cert role to CSR and doorman issue cert according to the cert role (#2620)
Cherrypick from master

* ENT-1443 Add cert role to CSR and doorman issue cert according to the cert role (#431)

* Doorman and HSM create certificate base on requested cert role specified in the certificate signing request.

(cherry picked from commit 94f7392)

* remove R3 corda code
2018-05-10 17:48:48 +01:00
Katelyn Baker
92048efaa4
CORDA-1414 - node should continue with parameters from file when network map not available (#3061) (#3098)
Fix CORDA-1414

If network map is not available or returns exception on network
parameters reading, node should continue with parameters from file.
2018-05-10 10:59:15 +01:00
Shams Asari
05671af82a CORDA-1385 - Ignore duplicate packages and sub-packages in driver extraCordappPackagesToScan (#3068)
Otherwise duplicate test CorDapps are loaded into the node

(cherry picked from commit 9ffb43f)
2018-05-09 11:57:48 +01:00
Katelyn Baker
9063e24c69
Update jolokia to 1.5.0 (#2617) (#3034)
* Update jolokia to 1.5.0

* adding jolokia update to changelog
2018-05-01 15:29:52 +01:00