Commit Graph

519 Commits

Author SHA1 Message Date
Dimos Raptis
8962d930d4 [CORDA-2923] - Make the RPC client reconnect with gracefulReconnect param (#5244)
When set to true the RPC client will:

* automatically reconnect when the connection is broken
* simple RPC calls will block until connection is established
* Observables returned from RPC will automatically resubscribe on reconnect so the client continues to receive events. This doesn't guarantee that events will not be lost during the reconnect.
2019-07-16 11:29:21 +01:00
Rick Parker
306df8e219
CORDA-3053 Validation should pass with systemProperties defined in config (#5276)
* CORDA-3053 Validation should pass with systemProperties defined in config

* CORDA-3053 Fix failing test and add new one
2019-07-05 17:20:57 +01:00
Stefano Franz
88894bc592
add a shared memory port allocator to allow multiple processes to sha… (#5223)
* add a shared memory port allocator to allow multiple processes to share a single allocation pool

* remove dangerous reset function on port allocator

* set forkCount = 2 in node integration test

* only allow one build of a cordapp at any given time for Driver tests

* make all portallocation requests use same starting point

* globally set forks to 6

* tweak forking parameters to allow parallel builds

* tweak unit test parallelism

* 2 workers for integrationTest

* some more tweaks for parallel builds

* some more tweaks for parallel builds

* seems that 49K is not the start of ephemeral ports on all kernels

* tweak parallel settings

* try fix RPC shutdown test in parallel env

* add some logging for RPC shutdown test

* added some logging around PortAllocation tests - try figure out where they are getting stuck

* added some logging around PortAllocation tests - try figure out where they are getting stuck

* fix api-scanner tests

* minimize api changes

* revert to complying with existing API

* add the AtomicInteger for api compatibility reasons

* make sizing script executable

* address review comments pt1

* address review comments pt2

* fix compile errors after review comments

* return to using home dir as temp dir seemed to interact badly with gradle
2019-07-02 18:38:33 +00:00
szymonsztuka
f89008c070 CORDA-2998 fix network builder (#5265)
CORDA-2998 fix network builder
2019-07-02 11:32:48 +01:00
Shams Asari
2e02968c63
ENT-3496: dumpCheckpoints shell command (#5171)
Dumps all the node's checkpoints as JSON into a single zip file in the node's directory. The output contains:

* All the fields for the top-level flow
* The current sub-flow call stack, along with the current progress tracker step for each sub-flow
* The event that suspended the flow, which if it's a send or sendAndReceive will show the payload that was sent
* Low level information on the active sessions with other peers
2019-06-26 15:31:02 +01:00
Shams Asari
4e835d5483
CORDA-2333: Updated the majority of the dependencies that were out of date (#5235)
Some where not touched, including the crypto ones, libraries related to messaging and Kotlin.
2019-06-20 16:19:16 +01:00
LankyDan
afc36615d0 ENT-3496 Address pr comments 2019-06-17 16:04:05 +01:00
Shams Asari
2152961d46
CORDA-2333: Dependency update pass for tests and demos (#5211) 2019-06-13 10:15:13 +01:00
LankyDan
b2148354a5 ENT-3496 Improve test to check for zip and json file existence 2019-06-12 10:31:15 +01:00
LankyDan
31a0c077b8 ENT-3496 Move dumpCheckpoints to the new InternalCordaRPCOps interface
To prevent making `dumpCheckpoints` part of the public API a new
interface, `InternalCordaRPCOps` has been created and the function
has been moved there. `InternalCordaRPCOps` inherits from
`CordaRPCOps`.

`CordaRPCOpsImpl` now implements `InternalCordaRPCOps`.

`RunShellCommand` and `StringToMethodCallParser` required additional
changes due to issues handling inherited functions. This has only been
raised now due to `InternalCordaRPCOps` inheriting from `CordaRPCOps`.

Many classes have had references to `CordaRPCOps` changed to
`InternalCordaRPCOps`.
2019-06-10 16:15:03 +01:00
Ryan Fowler
e1853f50d4 CORDA-2945: Catch IllegalArgumentException to avoid shutdown of NodeExplorer 2019-06-04 10:03:53 +02:00
Tudor Malene
5edd732615 Revert "CORDA-2773: Support for custom Jackson serializers (#5025)" (#5167)
This reverts commit f7bf1b41
2019-05-24 13:40:13 +01:00
Shams Asari
71c316ca5a
CORDA-2954: Upgrade to common-lang3 (#5152)
Utilised Fields.getAllFieldsList where we were doing the equivalent
2019-05-21 17:48:32 +01:00
josecoll
0263650a5f
Revert "Merge pull request #5145 from corda/jdk11-migration-gradle5-upgrade" (#5146)
This reverts commit f46377556c, reversing
changes made to ba675e73b9.
2019-05-20 16:16:49 +01:00
josecoll
38e84d46b4 Include JavaFX plugin (specify dependent JavaFX modules) and apply changes to relevant modules (explorer, demobench, client/jfx). 2019-05-20 15:08:27 +01:00
josecoll
ba675e73b9
CORDA-2893 Upgrade Corda to use Gradle 5.4.1 (Take 2) (#5137)
Upgrade Corda to use Gradle 5.4.1
2019-05-20 14:26:42 +01:00
Chris Rankin
b9f7c1a08a CORDA-2893, ENT-3422: Tweak JUnit 5 configurations to keep vintage engine off compile classpaths. (#5138)
* Tweak JUnit 5 configurations to keep vintage engine off compile classpaths.

* Configure Gradle tests to use JUnit 5.
2019-05-20 11:57:56 +01:00
josecoll
0eab42b63e
Revert "CORDA-2893 Upgrade Corda to use Gradle 5.x (#5063)" (#5135)
This reverts commit 88babefd89.
2019-05-17 11:11:05 +01:00
josecoll
88babefd89
CORDA-2893 Upgrade Corda to use Gradle 5.x (#5063)
* Upgrade gradle wrapper to Gradle 5.0

* Upgrade to use locally deployed version of Capsule plugin (using Gradle 5.0)

* Upgrade to use Corda Gradle Plugins 5.x (inclusive of Gradle 5.0 compatibility fixes)

* Fix compile-time problems resolving log4j packages.

* Update to use Artifactory deployed version of Capsule plugin (using Gradle 5.0)

* Upgrade to use Gradle 4.2.1 (excluding default memory setting change: command line client now starts with 64MB of heap instead of 1GB.)

* Added explicit compile-time dependency on 'de.jensd:fontawesomefx-commons:8.13' (compile-time error in tools:explorer without)

* Update "wrapper" gradleVersion to 5.4.1

* Update Capsule plugin version label to reference R3 forked build.

* Commit all gradle upgrade changes following: ./gradlew wrapper --gradle-version 5.4.1

* Increase maximum heap memory for Test tasks to 1GB, and upgrade build-scan plugin to 2.2.1.

* Increase Test tasks' maximum memory to 1.5GB - what could go wrong?

* Up maxHeapSize to 2g for gradle test runner (global setting).

* Added explicit compile-time dependency on 'de.jensd:fontawesomefx-commons:8.13' (compile-time error in tools:demobench without)

* Added forkEvery for node Unit tests.

* Up :node test task 'forkEvery' to 10.

* TC test execution tuning (:core, :node => forkEvery 10, default JVM heap size)

* TC test execution tuning (bump JVM heap size up to 1g for :node)

* TC test execution tuning (bump JVM heap size up to 1.5g for :node)

* TC test execution tuning (re-instate global JVM heap size of 1Gb)

* TC test execution tuning (re-instate JVM heap size of 2Gb for :node)

* Update Corda Gradle plugins to 5.0.0

* Updated plugin resolution order + renamed artifactory URL to use "software.r3.com"

* Reorder plugin resolution such that mavenlocal() is always queried first.
2019-05-17 10:36:21 +01:00
Dominic Fox
0b63157a4b ENT-3422 Add JUnit 5 dependencies to all projects (#5084)
* ENT-3422 Add JUnit 5 dependencies to all projects

* Remove explicit junit 4 imports where not needed

* Minor PR fixes

* Limit import scope
2019-05-15 16:40:12 +01:00
rui-r3
9e3a0a64ac CORDA-2491: Ability to specify Java package namespace from Cordform (#5075)
Add entry point with generic extra configuration options. Move configuration verification code to avoid circular dependencies.
2019-05-09 17:25:21 +01:00
Tudor Malene
f7bf1b41e0 CORDA-2773: Support for custom Jackson serializers (#5025) 2019-04-26 15:34:41 +01:00
Stefan Iliev
4f382a65a3 CORDA-2632 Handle exceptions when file does not exist. (#4967)
* corda-2632 Added catch clause to handle argument exceptions and display the proper error.

* Created specific exception for when the file is missing instead of the general catch all exception.

* Changes according to code review.
2019-04-25 16:23:11 +00:00
Tudor Malene
4a1f149b49 CORDA-2858: Wire-up Corda components with better RPC reconnect logic (#4933)
Implemented the ReconnectingRPC into the WebServer, Standalone Shell, Explorer and BankOfCordaClientApi
2019-04-15 11:26:53 +01:00
Adel El-Beik
374ae80ab1 ENT-3322: Improved error reporting in interactive shell when an error occurs after a ctor is matched. (#4969)
* ENT-3322: Improved error reporting when an error occurs in type construction, after the ctor has been found.

* ENT-3322: FlowA in this test violated a restriction of StringToMethodCallParser that parameters with the same name but different types cannot be overloaded.
Fixed up FlowA to not have overloaded operation.

* ENT-3322: Simplified code following review comments.

* ENT-3322: Few updates following PR review comments.
2019-04-12 11:13:53 +01:00
Stefan Iliev
e4615f7f47 CORDA-2586 explorer exception handling (#4957)
* Initial version of new(old) dialog that won't print a stacktrace for rpc exceptions.

* Decoupled CordaVersionProvider. Moved common files to common-logging to lower dependencies on the node explorer.

* Removed unused import and duplicate documentation comment.

* Moved error code rewrite policy in the new common/logging module according to PR review.

* Removed extra line.

* Updated log4j configurations with new package name where logging policies will be contained.

* Included common-logging module with cliutils.
2019-04-09 19:14:37 +00:00
cburlinchon
c33ccc1e1b Dont add cliutils to non cli app, remove addition of log4j2 from config/dev 2019-03-22 14:54:17 +01:00
cburlinchon
bc74ba4be4 Add missing cliutils dependency to explorer 2019-03-22 14:54:17 +01:00
Jonathan Locke
eabd056511 ENT-3333: Return error code for invalid cmdline options (#4910)
If an invalid command line option is specified and the parser is unable to parse the input, return an error code to the caller. This is useful in scripting scenarios where it might be important to detect that Corda failed to start due to invalid command line parameters
2019-03-21 11:15:32 +00:00
JamesHR3
a90f394d43 [CORDA-2738] Allow the ProgressTracker to cope with child trackers with the same steps (#4894) 2019-03-18 13:50:29 +00:00
Jonathan Locke
82c45c6f83 CORDA-2506: Better handling of invalid log path (#4895)
Test if we have access to the logging path (baseDirectory/logs) before attempting to write to them. This allows us to shut down gracefully with an easily understandable error message.
Without doing this, the log4j2 will attempt to access the logPath when it first uses the logger in the call() function.
2019-03-15 09:54:53 +00:00
JamesHR3
76dc981b91 [CORDA-2737] Buffer events from observables in ProgressTracker until subscribed to (#4882) 2019-03-13 16:33:29 +00:00
Chris Rankin
ea263b3e54 CORDA-2569: Add "flow kill <ID>" command to Corda's shell. (#4861)
* CORDA-2569: Add "flow kill <ID>" command to Corda's shell.

* Add testing and documentation for RPC killFlow operation.
2019-03-08 16:39:22 +00:00
Chris Rankin
b9e4804388 ENT-3128: Update documentation for Node Explorer. (#4817) 2019-02-27 14:32:39 +00:00
Chris Rankin
04ba77732b ENT-3128: Tidy up DemoBench's "built-in CorDapp" management. (#4814) 2019-02-25 18:11:21 +00:00
Chris Rankin
111acc5d6e CORDA-2671: Remove broken ExplorerSimulator from Node Explorer. (#4811)
* CORDA-2671: Remove broken ExplorerSimulator from Node Explorer.

* CORDA-2671: Document that Node Explorer is included with DemoBench.
2019-02-25 18:11:06 +00:00
Tommy Lillehagen
8fb3d4dc01
CORDA-2669 - Reintroduce pendingFlowsCount (#4806)
* CORDA-2669 - pendingFlowsCount not in public API

Reintroduce `pendingFlowsCount` to public API (as deprecated). Advise
to use the `gracefulShutdown` command in the shell instead.

* CORDA-2669 - Add pendingFlowsCount to api-current.txt
2019-02-23 17:10:32 +00:00
Mike Hearn
1ed5fce6a6 Backwards compat: Put the confidential-identities module back in the node classpath by default. Separating it out into a standalone "app" needs more thought and design work, if we do it at all. 2019-02-18 14:02:36 +01:00
Tommy Lillehagen
4434a005dd
CORDA-2622 - Fix shell extensions (#4774)
* CORDA-2622 - Fix shell extensions

* CORDA-2622 - Only add auto-completion stuff if enabled
2019-02-17 17:16:57 +00:00
Tommy Lillehagen
f781edccd4
CORDA-2623 - Add help screen to Network Builder CLI tool (#4775) 2019-02-17 16:33:08 +00:00
Chris Rankin
7866dde91b
CORDA-2556: Refactor World City database into a library module. (#4718)
* Refactor World City database into a library module.
* Migrate CityDatabaseTest into worldmap module.
2019-02-05 15:29:26 +00:00
Shams Asari
c39c61ecab
CORDA-2467: Moved non-contract things out of finance-contracts and into finance-workflows (#4700)
This includes all of the cash selection logic, JSON support using jackson and a bunch of utilities which are not relevant to contract verification. The exception to this are Interpolator which has been moved to the IRS demo, and PhysicalLocationStructures.kt which is now in explorer.
2019-02-01 17:31:12 +00:00
Tudor Malene
262a7ad1b7
Backport merge fixes added to ENT (#4618)
Fix test and address code review comments.
2019-01-29 13:45:04 +00:00
Viktor Kolomeyko
5744614886
ENT-3001: Make subCommands lazy val (#4668)
This is to prevent initialising it multiple times.
Please see linked Jira to understand how this can cause harm.
2019-01-29 10:48:33 +00:00
Shams Asari
5656d8ee80 CORDA-2510: Added missing confidential-identities CorDapp to DemoBench (#4636) 2019-01-25 17:48:10 +00:00
Katarzyna Streich
e93327bb6a
CORDA-2351 - Fix Demobench readme (#4624)
* CORDA-2351 - Fix Demobench readme

Remove information that BankOfCorda app is automatically loaded. Add
new up-to-date screenshots and information on how to check issuable
currencies on the node.
2019-01-23 13:45:53 +00:00
Stefano Franz
97df10e1f5 print out the underlying error when an RPC call fails (#4605)
make it red.
2019-01-22 10:14:01 +00:00
Shams Asari
c6a7d14f4f
Reducing the size of the CorDapp jars used in tests (#4600)
The helper method enclosedCordapp is a replacement to scanning the current package (which pulls in a lot more into the jar than intended).
2019-01-21 13:54:26 +00:00
JamesHR3
2ec6fe4c0a [CORDA-2441] Fix Stdout progress renderer to swap out correct appender (#4582)
* Fix stdout renderer to swap out correctly named appender.

Also fix two compiler warnings

* Add clearer exception when console appender cannot be found

* Change error displayed when appender not found to warning

* Remove type declaration on separate line
2019-01-15 18:54:08 +00:00
Shams Asari
24a7821dce
CORDA-2434: CordaRPCClient now only has c'tors rather a mix of c'tors and factory methods (#4569) 2019-01-14 16:07:56 +00:00