Commit Graph

1612 Commits

Author SHA1 Message Date
Maksymilian Pawlak
b87ca85046 Test driver default parameters removal (#2519) (#2525)
* Removed long parameter list in test driver, replaced with DriverParameters object

(cherry picked from commit b91dd43)
2018-02-14 10:24:16 +00:00
Anthony Keenan
90c8b2a12a CORDA-939 - Remove sslConfiguration from public constructor of CordaRPCClient (#2522) (#2529)
* Remove sslConfiguration from public constructor of CordaRPCClient

* Address review comments

* Update api-current.txt

* sslConfiguration doesn't need to be a property

# Conflicts:
#	.ci/api-current.txt
2018-02-13 22:48:14 +00:00
Katelyn Baker
f0e52e1eed
CORDA-1007 - Tweak the way invocation context is integrated to reduce the pain for devs using the old API (#2447) (#2524)
Minor tweaks to the invocation context code.

1) Un-deprecate FlowInitiator, move the deprecation to the field. This
   eliminates large numbers of warnings and means developers are warned
   only once in the place where they obtain one.

2) Add documentation for StateMachineInfo and create a type alias to give
   it a better name in an ABI compatible way.

3) Improve markup on InvocationContext

4) Rename field from just "context" to "invocationContext" (Context is vague)
2018-02-13 13:12:26 +00:00
Joel Dudley
c9ade00de6 No IdentityServiceInternal as public param. Start nodes without params. Simpler MockServices ctors. (#2521)
* Removes IdentityServiceInternal as a public parameter to MockServices.

* Reorders params to put non-default args first. Creates simpler default constructors.

* Adds constructors for creating mock nodes by passing params.
2018-02-13 11:32:04 +00:00
Shams Asari
49f75dab9c CORDA-1006: Undoing the wiring of maxMessageSize as it's not correctly implemented and updating the docs to clarify its status. (#2501)
The network parameter was just fed into Artemis' minLargeMessageSize property which isn't the same thing.
2018-02-13 11:31:39 +00:00
Michele Sollecito
fbb7f8f019 CORDA-990 - Flows Draining Mode (#2507)
* [CORDA-990]: Flows Draining Mode

* Fixed incorrect disconnect login.

* Code review changes.

* Fixed compilation error about MockNetwork...

* Fixed compilation error about MockNetwork...

* Fixed broken compilation.

* Ignoring an unstable test.
2018-02-13 09:34:10 +00:00
Anthony Keenan
e363090f30 CORDA-939 - Don't expose StartedNode and AbstractNode as part of public test api (#2472) (#2505)
* Don't expose StartedNode via Node Driver

* Dont expose StartedNode/Abstract Node via MockNetwork

* Remove internal var from constructor as it doesn't hide from public api and change to internal initialisation method

* Update api

* Rename MockNode to StartedMockNode to avoid confusion
Update documentation
Update api-current.txt

* Fix typo

* Fix test failure

* Modify flow tests to use internal mock network and remove additional internal exposures from StartedMockNode

* Fix api-current

* Change InProcess and OutOfProcess to interfaces

* Explicitly declare MockNetwork parameters
Dont expose StateMachineManager
Move affected tests to use internal mock network

* Fix api-current

* Changes requested via review

* Fix IRS Demo address

* Fix api

* Remove internal attribute from classes in internal package

* Remove accidentally added code

* Move useHttps into NodeHandleInternal

* Remove duplicated code

* Update api-current

* Make webAddress internal on NodeHandle

* Make sure parameters in public api are explicitly specified

* Use correct address in IRS Demo

* Get webaddress from webserver handle

* Update api-current

# Conflicts:
#	.ci/api-current.txt
2018-02-12 13:26:56 +00:00
Andras Slemmer
805178debc CORDA-1003: Fix duplicate detection on cache evict (#2499) 2018-02-12 10:17:34 +00:00
Andras Slemmer
10f3c0bcf9 CORDA-995: r3corda wire compatibility (#2497) 2018-02-12 10:09:47 +00:00
Patrick Kuo
c18bc8758f CORDA-961 Wire up and enforce max transaction size (#2465) (#2493)
* wire up and enforce max transaction size

* fixup after rebase
moved network parameter from AbstractNode to NodeProperties

* removed TODO

* fix broken import

* address PR issues

* remove API breaking change
address PR issue

* added max transaction size to driver and mock network.
address PR issues

* fix failing test

* added TODO

* fix verifier test

* fix spring driver build error

(cherry picked from commit c8cf46c)
2018-02-09 17:24:15 +00:00
Katarzyna Streich
af4aba2bfa First approach to network parameters updates (#2412) (#2487)
* Network parameters updates

Add two RPC methods networkParametersFeed and
acceptNewNetworkParameters. Implementation of client handling of network
parameters update event. Partial implementation of accepting new
parameters and installing them on the node as well as node startup with
updated parameters.

Move reading of network parameters on startup to separate
NetworkParametersReader class. Add tests.

Move NetworkParameters and NotaryInfo classes to core.

* Ignore evolvability test - to be fixed later

* Add documentation on update process
2018-02-09 14:55:19 +00:00
Anthony Keenan
e41408d21e CORDA-939 - Dont expose FlowStateMachine via public API (#2438) (#2476)
* CORDA-939 - Dont expose FlowStateMachine via public API (#2438)

* Create CordaInternal attribute for properties on public classes that are not part of the api and apply to FlowLogic.stateMachine

* Remove startFlow from public test api and replace with startFlowAndReturnFuture

* Update api-current with changed signature

* Change test used in documentation to use public test methods

* Remove the rest of the unneccessary usages of the startFlow test utility

* Remove extra whitespace

* Rename startFlowAndReturnFuture back to startFlow

* Update api

* The annotation doesn't appear unless its marked as on the actual getter and setter

* Updated docs and removed pointless attribute

* Deleted whitespace

# Conflicts:
#	.ci/api-current.txt
#	testing/node-driver/src/main/kotlin/net/corda/testing/node/NodeTestUtils.kt

* Revert api-current to v1 api

* Adding missing line and missing annotations

* Made changes post review

* Minor text change
2018-02-08 14:40:16 +00:00
josecoll
9c2b5f4ced Tolerate duplicates to prevent a PK violation. (#2460) 2018-02-08 11:17:57 +00:00
Katelyn Baker
9b8fe3a1d4
Merge pull request #2470 from corda/fixes/sollecitom/failfast_rpc_settings
Added basic node configuration validation.
2018-02-06 16:32:26 +00:00
sollecitom
7947bb314f CORDA-988 - Added basic node configuration validation. 2018-02-06 14:47:36 +00:00
Patrick Kuo
c6f01dc274 set network registration poll interval via http cache control header (#434) (#2445) (#2471)
* set network registration poll interval via http cache control header from the server side

* default poll interval to 10 seconds if cache header not found

* address PR issues

* address PR issues

(cherry picked from commit dca8699)

(cherry picked from commit 258b562)
2018-02-06 14:35:06 +00:00
Anthony Keenan
7de5b0af61 Remove exposure of internal hibernate configuration from mockservices (#2442) 2018-02-01 11:46:21 +00:00
Matthew Nesbit
ceff50d656
Refactor location of bridge code to allow out of process bridging (#2431)
Fix some issues Andras has seen
2018-01-30 16:29:59 +00:00
Patrick Kuo
685ab4c9b0
Add trace logging to network map client (#2424)
* Add trace logging to network map client

* Add trace logging to network map client

* address PR issue

* address PR issue
2018-01-29 17:44:28 +00:00
Patrick Kuo
28e29c0873
Fix path issue which causes windows build failure. (#2430) 2018-01-29 17:43:48 +00:00
Patrick Kuo
93054a9590
Add cmdline option for network root truststore and password (#2407)
* add cmdline option for network root truststore and password, instead of using node's truststore configuration to avoid confusion.

* revert line auto format

* fix failing integration test

* address PR issue
2018-01-29 13:43:16 +00:00
Rick Parker
e19f51d9ac
CORDA-959 Filter unschedules and remove database activity from inside mutex. (#2426)
* Filter unschedules and remove database activity from inside mutex.

* Race condition fix

* Bug fix
2018-01-26 17:44:42 +00:00
Thomas Schroeter
4257891c98
Revert "Raft Notary: remove snapshotting" (#2423)
This reverts commit cf33be66ff.
2018-01-26 16:23:59 +00:00
Andrius Dagys
e357a88181
Deprecate TimeWindowChecker, make TimeWindowInvalid report exact current time and transaction time window (#2280)
* Make notary service return the current time and the transaction time window
along with the TimeWindowInvalid error.

Deprecate TimeWindowChecker.
Add a static method for validating transaction time window to reduce code duplication.
2018-01-26 09:32:11 +00:00
Matthew Nesbit
0ff9c9e2e3
Move to message based bridge control protocol (#2410)
Tidy up

Remove dead RPCSecurity logic from ArtemisMessageServer

Address PR comments

Address PR comments
2018-01-25 17:53:34 +00:00
Andrzej Cichocki
242d9cf7ad
CORDA-692 Don't include internal packages in API documentation (#2415)
* Use G1 for gradle daemon
2018-01-25 15:26:13 +00:00
Michele Sollecito
9783f11ba8
Exposed RPC SSL settings through Cordformation (#2419) 2018-01-25 14:32:58 +00:00
jamesbr3
5f8af818b1
Merge pull request #2408 from corda/jamesbr-remove-jolokia-war
Remove jolokia war reference from webserver
2018-01-24 21:19:50 +00:00
Shams Asari
0fa6969d5d
Added various X509 utilities to remove some of the existing boilerplate. (#2416) 2018-01-24 18:07:29 +00:00
Mike Hearn
cfb8997f23 Fix build break due to an API change between PR check and merge 2018-01-24 17:14:03 +01:00
Ben Wyeth
d17670c747 Provide an API to register callback on app shutdown (#2402)
Provide an API to register callback on app shutdown.
2018-01-24 16:19:24 +01:00
Michele Sollecito
3c0e006456
Reverted incorrect additional advertised RPC address in NodeInfo (#2417) 2018-01-24 14:42:07 +00:00
Shams Asari
61c7de22d6
Replaced KeyStoreWrapper with X509KeyStore, which is still a wrapper but assumes only X509 certs and has better APIs (#2411) 2018-01-24 07:51:55 +00:00
Joel Dudley
5df50c0e81
Fixes a bug in the deserialisation of UniqueIdentifiers in the CRaSH shell. 2018-01-23 17:28:24 +00:00
Michele Sollecito
142f52fa82
[CORDA:936]: Enable RPC layer to work with SSL 2018-01-23 16:23:37 +00:00
James Brown
8de2c78dd2 Remove jolokia war reference from webserver 2018-01-22 16:21:28 +00:00
Christian Sailer
8d5611853a
CORDA-929 Attachment caching (#2372)
* ENT-1403 Cache node attachments (and attachment content)

* ENT-1403 Make cache sizes configurable

* Update documentation with new config parameters

* Test that non-existence of attachments is not cached

* Remove unneeded defaults in interface

* It turned out we need the defaults on the interface in quite a few tests

* Codereview: typos, size in MB rather than bytes, charset in tests, move concurrencyLevel to a constant

* Codereview: Make the internal config value bytes again, but config file in MB

* Fix example config unit test
2018-01-22 13:41:06 +00:00
Andrzej Cichocki
1fc646cfa8 CORDA-716 Move test-utils and node-driver to stable API section in docs (#2335)
* Move test-utils and node-driver to stable section.

* Move FlowStackSnapshotFactory to testing.services package & update docs

* Move SerializationTestHelpers to testing.core package

* Move TestConstants.kt to core namespace

* Move Expect.kt to core namespace

* Move CoreTestUtils to core.TestUtils - rename class and update imports

* Added some clarification to documents after re-reading them

* Added static imports

* Removing unused import

* Fix merge conflict

* Fixing merge conflict
2018-01-22 11:28:41 +00:00
szymonsztuka
f59560bb06
Database schema changes. (#2389)
Changes compatible with R3.Corda (ENT-794):
1) Added Hibernate corda-wrapper-binary two to to columns.
2) Shorten names of tables in dummy schemas used in tests.
3) Undo removal of compound index of VaultTxnNote (b423fea).
4) Assertions for 2 vault tests don't rely on order of rows.
2018-01-19 17:09:02 +00:00
Mike Hearn
ac7637e2b4 Revert "CORDA-599 RPCSecurityManager is no longer lateinit (#2347)"
This reverts commit 75e74e67a1.
2018-01-19 17:52:59 +01:00
cburlinchon
de4c062529
Node restarted with shutdown executor (#2391)
* Test for node restart
* Executor gets shutdown on stop, make sure we have one on start
* Reset shutdown otherwise AbstractNode.stop never gets called
2018-01-19 10:19:12 +00:00
Katarzyna Streich
af081a7170
Remove primary key constraint on DBHostAndPort (#2318)
Remove primary key constraint on DBHostAndPort

Return always first node if more are matching by address.
2018-01-18 16:23:41 +00:00
Andrzej Cichocki
bbcafca959
Retire DatabaseTransactionManager. (#2385) 2018-01-18 10:11:34 +00:00
josecoll
e699dad076
CORDA-917 Bootstrap nodes without Notary schemas (by default) (#2376)
* Default jolokia version with optional override in CorDapp project gradle file.

* Bootstrap a node without Notary schemas by default.

* Revert unrelated Jolokia code change.

* Revert unrelated Jolokia code change.

* Addressed PR review feedback.
2018-01-18 10:10:06 +00:00
Shams Asari
d19eb4a9d7
Removed useHTTPS from NodeConfiguration as it's not needed by the node. (#2375)
It's still expected to be present in node.conf if the web server needs to use SSL.
2018-01-17 17:47:40 +00:00
Matthew Nesbit
6edf95506b
Rename the inbox (#2360)
Add changelog entry

Address review comments

Alternate solution to service queues

Fixup after merge
2018-01-17 16:06:31 +00:00
Andrzej Cichocki
ea57639a37
CORDA-924 Fix IntegrationTestingTutorial (#2349)
i.e. H2 startup bug. also:
* Fix poor connection pool discipline
* Log cleanup failures instead of replacing foreground failure
2018-01-17 14:23:13 +00:00
Christian Sailer
fca0afe591
CORDA-928 Caching in the NetworkMapCache (#2358)
* CORDA-928 cache query results via `getPeerByLegalName` and `getNodesByIndentityKey` to avoid hitting the DB hard in RPC handling.

* Skip cache invalidation during init() - caches are still null.

* Remove registeredNodes/partyNodes caching of data feed.
Rewrite data feed to be initialised off the DB.
Add start method to trigger readyness/artemis listeners if there are nodes in the DB.

* Invalidate cache last rather than first when updating
2018-01-16 21:15:15 +00:00
Anthony Keenan
1367cd4adb
CORDA-912 Stop exposing internal node user, create user in testing infrastructu… (#2361)
* Stop exposing internal node user, create user in testing infrastructure instead

* Update kdocs
2018-01-15 19:30:33 +00:00
Andrzej Cichocki
75e74e67a1
CORDA-599 RPCSecurityManager is no longer lateinit (#2347) 2018-01-15 19:11:00 +00:00