Commit Graph

2298 Commits

Author SHA1 Message Date
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
Stefan Iliev
d1e7850dd1 CORDA-2176 - test that logging is not broken. (#5224)
* Initial commit with a test that can detect a logger that isn't initialised with by lazy that gets called during startup.

* Test improvement. Test fix for api stability.

* Added explanatory comment for the test.

* Changes according to PR review. Added empty file check to make test more robust.
2019-06-25 14:35:39 +01:00
Shams Asari
99bc614b7c Merge remote-tracking branch 'origin/feature/CID-878-non_party_flow_sessions' into shams-merge-cid-878 2019-06-21 16:46:41 +01:00
Shams Asari
76eec9aa8b
CORDA-3033: Introducing Destination interface for initiating flows with (#5242)
Party and AnonymousParty have been retrofitted to implement this interface and are currently the only supported types. A new FlowLogic.initiateFlow(Destination) method overload to easily support the addition of new destination types in future versions.
2019-06-21 16:39:56 +01:00
Christian Sailer
0cd57c81bc Test the scheduler picking up a persisted scheduled state without shutting down/restart the db. (#5236) 2019-06-21 15:16:10 +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
Shams Asari
843c3a0190
All uses of CheckpointStorage.getAllCheckpoints() close the stream after use (#5230) 2019-06-19 09:45:38 +01:00
Shams Asari
f0f05df9f4 Merge branch 'master' into feature/CID-878-non_party_flow_sessions
# Conflicts:
#	core/src/test/kotlin/net/corda/core/flows/CollectSignaturesFlowTests.kt
2019-06-18 13:14:55 +01:00
Stefano Franz
f9c034aa7c CORDA-3000: Allow AbstractParty to initiate flow (#5219) 2019-06-18 13:13:09 +01:00
LankyDan
e3db3a386e ENT-3496 Address pr comments 2019-06-17 16:43:05 +01:00
LankyDan
afc36615d0 ENT-3496 Address pr comments 2019-06-17 16:04:05 +01:00
LankyDan
245a14d499 ENT-3496 Add suspendedTimestamp and secondsSpentWaiting to checkpoint dump 2019-06-11 16:22:17 +01:00
Stefan Iliev
3b73e60605 CORDA-2774 Fix for liquibase changelog warnings. (#5199) 2019-06-11 15:33:05 +01:00
LankyDan
143499f6fd ENT-3496 Add the checkpointed flow's simple name to the json file name 2019-06-11 09:38:48 +01:00
LankyDan
330b5a1d3c ENT-3496 Fix compile error in ThreadContextAdjustingRpcOpsProxyTest 2019-06-11 09:06:44 +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
LankyDan
d8395baf62 ENT-3496 Create log directory to place dumps if it does not already exist 2019-06-10 15:10:34 +01:00
bpaunescu
726798cce8 ENT-3642: move the crypto service builder method to node-api (#5198)
* ENT-3642: move the crypto service builder method to node-api

* ENT-3642: add arg for different crypto services

* ENT-3642: add arg for cryptoservice config

* ENT-3642: add null check for BCC requirement

* ENT-3642: remove double-bang operator

* ENT-3642: cryptoservice factory method moved to its own class, improve API

* ENT-3642: remove import
2019-06-07 09:10:42 +01:00
josecoll
603da3eeff
CORDA-2984 Re-instate CordaCaplet tests and move CordaCaplet code into :node:cap… (#5197)
* Re-instate CordaCaplet tests and move CordaCaplet code into :node:capsule module.

* Clean-up verbose IntelliJ refactoring.

* Updated buildCordaJAR task references to resolve CordaCaplet from :node:capsule project.

* Incorporating feedback from PR review.
2019-06-07 08:55:19 +01:00
LankyDan
684e9cdf58 ENT-3496 Store dump in logs directory and only one dump at a time
Store the flow dump zip in the logs directory.

Only allow one dump to be created at a time. This is protected by
using a `AtomicInteger` lock and checking for the zip's existence.
2019-06-06 15:35:15 +01:00
Rick Parker
0c0101948b
CORDA-2981 Disable slow consumers for RPC since it doesn't work. (#5194)
* CORDA-2981 Disable slow consumers for RPC since it doesn't work.
2019-06-05 11:47:38 +01:00
josecoll
8678bad88d
CORDA-2970 Revert usage of Gradle JUnit 5 Platform Runner (#5173)
* Revert usage of Gradle 5 useJUnitPlatform() which causes significant test execution performance degradation.

* Remove completely top-level Java CordaCaplet unit tests causing consistent TC failure on Azure VMs:

 java.security.NoSuchAlgorithmException: no such algorithm: NONEwithEdDSA for provider BC
2019-06-05 10:17:02 +01:00
szymonsztuka
937e467aac CORDA-2971 - added tests for initialiseSchema configuration option (#5153) 2019-06-04 11:37:32 +00:00
Roger Willis
1fc7405c7f
Fix for CORDA-2972. (#5185) 2019-06-04 11:21:56 +01:00
Tudor Malene
f8d8de7555 CORDA-2975 Remove version uniqueness check - fix tests 2019-06-03 14:41:10 +02:00
Tudor Malene
77ab33d5b0 CORDA-2975 Remove version uniqueness check 2019-06-03 14:41:10 +02:00
Stefan Iliev
3b7f0aff92 ENT-3484 - Added periodic log.warn message to remind that the node has been set into draining mode. (#5151)
* Added periodic message logged from a timer which is switched on and off by the node drain events.

* Timer also spawns on start() to ensure that if a node is shutdown in draining mode and started with it, it will continue logging messages.
2019-06-03 13:49:29 +03:00
Shams Asari
a70bd6ffa0 Clean up 2019-05-24 17:50:17 +01:00
Shams Asari
5619debf18 ENT-3496: dumpCheckpoints RPC
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-05-24 17:28:36 +01:00
Rick Parker
d6ac4e2393
CORDA-2838 Set Artemis memory config. (#5011)
* CORDA-2838 Set Artemis memory config.

* CORDA-2838 Cannot have page size larger than max size.

* CORDA-2838 Use real slow consumers.  Need to see if the old config settings can work with a global limit to avoid this.
2019-05-23 14:30:11 +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
a7966e6176 Fix attempt to access boot classpath from runtimeMXBean (in JDK9+) 2019-05-20 15:09:36 +01:00
josecoll
4603305a35 Move Java unit test into kotlin package to prevent ASM compilation/classloading error (REVISIT)
* What went wrong:
Caused by: org.gradle.api.GradleException: failed to read class file /Users/josecoll/IdeaProjects/corda-jdk11/node/build/classes/java/test/net/corda/node/services/events/FlowLogicRefFromJavaTest$JavaNoArgFlowLogic.class
2019-05-20 15:08:27 +01:00
josecoll
cce16c8522 Remove usage of private JDK class "sun.misc.Signal" (REVISIT) 2019-05-20 15:08:27 +01:00
josecoll
804f8dc17b Update Java Version checking. 2019-05-20 15:08:27 +01:00
josecoll
4db2447e0b Fixed JUnit to not use a deprecated/removed JDK package "com.sun.xml.internal.messaging.saaj". 2019-05-20 15:08:27 +01:00
josecoll
c8eb13efe2 Fix JUnit by adjusting assertion to reflect improved uncompressed byte size. 2019-05-20 15:08:27 +01:00
josecoll
2a2fb6f82a Change checkJavaVersion() startup check to support JDK 11. 2019-05-20 15:08:27 +01:00
josecoll
ac56f302eb TEMP disable use of "sun.security, sun.misc.Unsafe" in serializer lists (re-instate with module add-exports directive) 2019-05-20 15:08:27 +01:00
josecoll
b8fb617ee1 TEMP disable use of "sun.misc.VMSupport" (re-instate with module add-exports directive) 2019-05-20 15:08:27 +01:00
josecoll
579a95b849 Remove illegal imports: sun.security, sun.reflect. 2019-05-20 15:08:27 +01:00
Viktor Kolomeyko
355604457f CORDA-2935: Align timeouts for CRL retrieval and TLS handshake (#5125) 2019-05-15 09:19:51 +01:00
JamesHR3
d8a790b3ce [CORDA-2866] Adjust RPC test case to prevent failures on non-H2 databases (#5114) 2019-05-10 11:13:12 +01:00
JamesHR3
b4e96778bf [CORDA-2517] Whitelist attachments signed by keys that already sign existing trusted attachments (#5068)
This allows a different signed version of the same CorDapp to be automatically trusted.

This reverts "[CORDA-2575] Allow users to whitelist attachments by public key config (#5035)"
2019-05-07 12:55:27 +01:00
JamesHR3
c533792f3f [CORDA-2866] Prevent node startup if legal identity key is lost but node key isn't (#5090) 2019-05-07 11:49:29 +01:00
Dan Newton
268f6db430 CORDA-825 Test jdbc session and entity manager in corda service constructors (#5088) 2019-05-02 16:34:44 +01:00
Tudor Malene
4c31e8c1fe Increase the wait time for events as it can take longer on some environments (#5085) 2019-05-02 11:03:52 +01:00
Dan Newton
c163365229 CORDA-2280 Move assumeFalse in SignatureConstraintVersioningTests (#5076)
A test was failing due to `assumeFalse` (to stop a test running on windows)
being inside of a `assertThatExceptionOfType` block. The exception it
threw was consumed by the block instead of junit.
2019-04-30 16:08:10 +01:00
Dan Newton
6662d205f8 CORDA-2280 Automatic propagation of whitelisted to Signature Constraints (#5053)
If a single whitelisted constraint is being used by input states and the version of the cordapp changes + is signed, then the constraint will transition to a signature constraint.
2019-04-29 17:37:57 +01:00