Commit Graph

2679 Commits

Author SHA1 Message Date
Kyriakos Tharrouniatis
8ae368ae6d Fix detekt issue 2020-02-18 16:13:12 +00:00
Kyriakos Tharrouniatis
3d0ad702de Move FlowSafeSubscriber and flowSafeSubscribe under their own package 2020-02-18 15:55:19 +00:00
Kyriakos Tharrouniatis
2459530a14 Add timeout to tests 2020-02-18 14:06:16 +00:00
Kyriakos Tharrouniatis
5d1936a7a3 Minor text update 2020-02-18 14:01:43 +00:00
Kyriakos Tharrouniatis
96b46782c1 Move CustomSafeSubscriber outside test methods 2020-02-18 13:57:57 +00:00
Kyriakos Tharrouniatis
6e0ae53156 Introducing Observable.flowSafeSubscribe public API method to subscribe with -non unsubscribing- Rx.Subscribers to Observables. It also replaced FlowSafeSubject 2020-02-18 13:54:49 +00:00
Kyriakos Tharrouniatis
82f6e9b3db Update test comment 2020-02-17 14:03:55 +00:00
Kyriakos Tharrouniatis
bececa153d Minor kdoc update 2020-02-17 14:00:04 +00:00
Kyriakos Tharrouniatis
1319da6b50 Changing exception thrown when accessing VaultService.rawUpdates from within a flow to a CordaRuntimeException 2020-02-17 13:58:53 +00:00
Kyriakos Tharrouniatis
b5682e3a4e Throw exception upon accessing VaultService.rawUpdates from within a flow 2020-02-17 13:50:43 +00:00
Kyriakos Tharrouniatis
3000d58022 Make kdoc more clear 2020-02-17 13:06:30 +00:00
Kyriakos Tharrouniatis
4acdcbd964 Moving SubscribingRawUpdatesFlow from ErrorHandling to VaultObserverExceptionTest 2020-02-17 11:45:19 +00:00
Kyriakos Tharrouniatis
7e370c136b Moving NotarisedTxs from SendStateFlow to VaultObserverExceptionTest inside NodeHandle.getNotarisedTransactionIds 2020-02-17 11:37:56 +00:00
Kyriakos Tharrouniatis
e2df4d383e Update test and add test comment 2020-02-17 11:32:29 +00:00
Kyriakos Tharrouniatis
812b4d5af2 Update test name 2020-02-17 11:11:43 +00:00
Kyriakos Tharrouniatis
58a71d8d07 Add explanatory comment to test 2020-02-17 11:09:09 +00:00
Kyriakos Tharrouniatis
9a27a81670 Update test name 2020-02-17 10:42:27 +00:00
Kyriakos Tharrouniatis
163beefc0f Splitting heartBeat into heartBeatOnNext and heartBeatOnError 2020-02-17 10:34:52 +00:00
Kyriakos Tharrouniatis
f024c7db9e Update messy comment 2020-02-17 00:32:44 +00:00
Kyriakos Tharrouniatis
4f3fc81081 Correcting comment 2020-02-17 00:17:37 +00:00
Kyriakos Tharrouniatis
11d92f90d5 Splitting heartBeat to heartBeat1 and hearBeat2 for more clear asserting 2020-02-17 00:14:01 +00:00
Kyriakos Tharrouniatis
6a89e88999 Replace assertThat with assertEquals 2020-02-16 23:57:19 +00:00
Kyriakos Tharrouniatis
a5f19ea8d2 Update messy comment 2020-02-16 23:48:42 +00:00
Kyriakos Tharrouniatis
8241911e0e Minor text update 2020-02-16 23:42:42 +00:00
Kyriakos Tharrouniatis
2fffef5701 Change PreventSubscriptionsSubject#errorAction to be more specific; to return an Exception 2020-02-16 23:35:29 +00:00
Kyriakos Tharrouniatis
2c0e4396d1 Add comment and update kdoc explaining how to subscribe with SafeSubscriber to FlowSafeSubject 2020-02-16 22:14:56 +00:00
Kyriakos Tharrouniatis
17b94c45e8 Moved FlowSafeSubject under package node.internal as it is only used by NodeVaultService 2020-02-16 21:29:51 +00:00
Kyriakos Tharrouniatis
9a2daeb5c9 Logging flow name instead of flow id at VaultService.rawUpdates subscribing error 2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
0fb49e9ed2 Added test, asserting FlowSafeSubscriber is alive and re-accessed upon flow retry 2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
bc79ce8058 Add fiber's id to log message and exception message 2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
db8457ef3f Improve log message 2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
c8566d2cf9 Correcting log message 2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
4517457e16 Revert "Wrap PublishSubjects with FlowSafeSubjects in all tests that test Observer.tee"
This reverts commit e419af86
2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
97ec3a18b1 Make rawUpdates Rx.Observers not unsubscribe when accessed from CordaServices - Do not allow rawUpdates subscribing from flows 2020-02-14 14:12:34 +00:00
Kyriakos Tharrouniatis
cfcca4ac18 Wrap PublishSubjects with FlowSafeSubjects in all tests that test Observer.tee 2020-02-14 14:00:51 +00:00
Kyriakos Tharrouniatis
e41fb714c1 Introducing not unsubscribing version of Rx.Subscriber 2020-02-14 13:55:44 +00:00
Kyriakos Tharrouniatis
9d2df380ea Throw SQLException or PersistenceException plain, that may come out of an unsafe subscriber 2020-02-14 13:49:50 +00:00
James Higgs
da192bcf0d
[EG-140] Allow system property paths with multiple keys to be specified in node.conf (#5963)
* [EG-140] Allow system property paths with multiple keys to be specified in node.conf

* [EG-140] Split property paths to remove quotes

* [EG-140] Quote system properties in docs

* [EG-140] Rename path to key
2020-02-14 11:18:21 +00:00
Razvan Codreanu
c6ab07d92c
TM-197 Fix failing test caused by regression and ignoring flaky DistributedServiceTests (#5934)
* TM-197 Setting bouncy castle provider in order for the test to pass

* TM-197 setting timeout for all builds at 3 hours

* TM-197 ignoring unstable tests
2020-02-12 14:26:06 +00:00
Denis Rekalov
1705299bde ENT-4918: Support symbolic link for certificates directory during node registration 2020-02-11 13:14:34 +00:00
Stefano Franz
b23af5f0d2
add timeouts to all tests (#5875) 2020-02-11 10:14:05 +00:00
Kyriakos Tharrouniatis
9ca1dd59da
CORDA-3381 Make internalUtilsKt Observer tee not wrap with SafeSubscriber (#5913)
* Make tee not wrap PublishSubjects in SafeSubscribers, otherwise a non Rx exception from an unsafe observer shuts down all other observers under the same PublishSubject

* Throw SQLException or PersistenceException plain, that may come out of an unsafe subscriber

* Revert "Throw SQLException or PersistenceException plain, that may come out of an unsafe subscriber"

This reverts commit c7b8af3fa6.

* Update Detekt baseline
2020-01-31 12:32:59 +00:00
Florian Friemel
cb6ed6042c
Move jimfs dependency from node to test-utils. (#5911) 2020-01-31 10:55:05 +00:00
jmacmahonr3
9511329e3d
[EG-75] Not handled exception when NetworkMap not accessible (#5903)
* Just passing in the exception was printing the entire stacktrace to the log, now we just pring the exception and message

* Updating exception message
2020-01-30 17:26:22 +00:00
Christian Sailer
cac96d81bf Remove unused dependency on IntelliJ forms 2020-01-30 10:48:00 +00:00
Oliver Knowles
286fffd67a
ENT-4368 - Improve error handling when required included config resource cannot be found. Add note in docs encouraging use of required syntax for includes. (#5907) 2020-01-30 10:10:24 +00:00
Ryan Fowler
d16e1126db
CORDA-3542: Use the config values for reconnecting retry interval and max reconnect attempts (#5869) 2020-01-29 13:08:54 +00:00
Nick Dunstone
a4cada4a2e ENT-4474 O/S Changes to support bulk backchain fetching (#5894)
* Ongoing dev multi backchain fetch

* Final dev pre logging message improvements

* Trace messages

* Trace messages

* Code tidy up

* Code review comments

* Code review comments

* Whitespace removed

* Code review changes

* Code reformatting
2020-01-28 09:04:18 +00:00
Ryan Fowler
e8d6701f87 CORDA-3558: Allow initial registration errors to propagate up so the node exits with a failure code (#5899) 2020-01-27 15:23:07 +00:00
Kyriakos Tharrouniatis
7f62046c2f CORDA-3329 Exceptions thrown in raw vault observers can cause critical issues (#5816)
Observers registered on NodeVaultService#rawUpdates, if they throw an exception when called from serviceHub#recordTransactions and if this exception is not handled by the flow hospital, then this leads to the transaction not being recorded in the local vault. This could get the ledger in an out of sync state.

In the specific case this happens within FinalityFlow#notariseAndRecord this leads to the transaction being notarized but not recorded in the local vault nor broadcasted in any counter party. The -failed to be recorded locally- transaction and its output states are not visible to any vault, and its input states not able to consumed by a new transaction, since they are recorded as consumed within the Notary. In this specific case we need not loose, by any means, the current transaction.

We will handle all cases by catching all exceptions thrown from serviceHub#recordTransactions, wrapping them with a HospitalizeFlowException and throwing it instead. The flow will get to the hospital for observation to be retried from previous checkpoint on next node restart.
2020-01-24 18:21:07 +00:00