Commit Graph

1906 Commits

Author SHA1 Message Date
810e6a230e Remove dead and expensive call to key management service 2017-09-06 15:07:26 +01:00
dc0b56432b Change PersistentIdentityService to use AppendOnlyPersistentMap as this has bounded memory and works correctly for the use case of repeated duplicate inserts. 2017-09-06 13:58:25 +01:00
fe17d26bb0 Reshuffle docs on NetworkRegistrationHelper (#1429)
Reshuffle docs on NetworkRegistrationHelper, and in particular note that it can cause the whole
process to exit.
2017-09-06 09:25:45 +01:00
ebc9cacb53 Contract Upgrade API improvements + persistence (#1392)
* All Contract Upgrade functionality performed within a corresponding flow.
Removed RPC API calls for contract upgrade authorisation / de-authorisation.
Added persistence using AppendOnlyPersistentMap.

* Changed to using a PersistentMap to ensure entries can be removed (was causing failing de-authorisation tests).
Fixed all warnings.

* Added mandatory @Suspendable annotations to flows.

* Do not instantiate object unless overridden.

* Updated changelog and CordaDocs.

* Persistence simplification: only store upgrade contract class name (not serialized object)

* Remove nullability from contract_class_name DB column.
2017-09-05 13:23:19 +01:00
5bb9556380 Merge pull request #1414 from corda/mnesbit-persistent-identityservice
Create Persistent Identity Service
2017-09-05 11:54:23 +01:00
b6e8b05dea Raft JMX reporting: initialize after server is created 2017-09-05 12:30:28 +02:00
0831fdfd4f Add basic Raft cluster status metrics 2017-09-05 12:30:28 +02:00
8ef29d4736 Persistent Identity
Fixup tests after rebase

Add unit tests of Persistent Identity. Fix bugs in PersistentMap.

Wrap identity and network map RPC calls in database transaction

Address PR comments
2017-09-05 11:19:54 +01:00
cbf89ba98b Deprecating verifiedTransactions from the public API (#1418) 2017-09-05 10:07:55 +01:00
0e250e9279 Add support for signed attachments (#1369) 2017-09-04 16:19:12 +01:00
b990fedd80 Adds a builder for configuring nodes in the driver for Java interop. 2017-09-04 15:51:46 +01:00
0bbee4a92b CORDA-540: Prevent "node" unit tests hanging in AMQP mode (#1402) 2017-09-04 10:41:01 +01:00
e1363c91cc PersistentNetworkMapCache close database connection (#1398) 2017-09-04 09:41:00 +01:00
83d0095142 Adds a builder for configuring nodes in the driver for Java interop. 2017-09-01 16:45:00 +01:00
a286f7553b Enable RPC start of Flows that return nothing (eg. Void). (#1374)
* Enable RPC start of Flows that return nothing (eg. Void).

* Fix blocking test (caused by not running mockNetwork).
Improve execution times by moving redundant setup() initialisation to only tests that use it.
2017-09-01 15:44:53 +01:00
1528813d5b Don't fail silently when running flow with no progress tracker from shell. 2017-09-01 11:24:16 +01:00
66c35bbffa Demote quasar-core to a runtime dependency, and capsule to "compileOnly". (#1381) 2017-09-01 11:12:04 +01:00
7e3dd4c12c Restructure net.corda.core.crypto package
* Rename KeyFactory to CompositeKeyFactory
* Move expandedCompositeKeys into TestDSL as the only place that uses it
* Move NullKeys out of their own package
* Move remaining crypto classes into superpackage
* Move utility classes out of crypto and into utilities package
2017-09-01 10:55:58 +01:00
17a9f8a7ea Merge pull request #1355 from corda/aslemmer-fix-flaky-retry-test
Fix flaky distributed retry test
2017-09-01 10:55:42 +01:00
83dc1d020d Fixes tests. 2017-09-01 10:50:13 +01:00
62c64ace23 Adding createSignature(filteredTransaction) to serviceHub (#1380) 2017-09-01 10:45:01 +01:00
54e302608f Updates the error message. 2017-09-01 10:07:34 +01:00
9891fb58b0 Address comments 2017-09-01 09:34:29 +01:00
75cd76b09b Fix flaky distributed retry test 2017-09-01 09:34:28 +01:00
ebbca94d67 Show error msg rather than fail silently when running a flow with no progress tracker from the shell. 2017-08-31 22:38:33 +01:00
485c2feb83 CORDA-540: Ensure that registration of a test node was a success prior to performing further testing with it (#1379)
Registration may fail due to low level serialization problems especially when running in AMQP mode
Also some minor improvements for exceptions reporting and test coverage
2017-08-31 18:38:29 +01:00
e1943e2b51 Move ContentSignerBuilder into net.corda.node.utilities
Move `ContentSignerBuilder` into `net.corda.node.utilities` so it's not part of the API visible to CorDapp developers, when it's only needed inside the node itself.
2017-08-31 16:55:40 +01:00
1139c1abf5 Throw a diagnostic exception if your FlowLogic.call method is not marked as @Suspendable.
This catches a bunch of unit tests where it's missing and also resolves an issue I saw Roger hit the other day.
2017-08-31 15:11:09 +02:00
b63df0ea39 Vault Service API final clean-up (#1348)
* Remove notify/notifyAll from public Vault Service API.

* 1st pass - remove ContractUpgrade public API calls from VaultService into self contained ContractUpgradeService.

* Fix compile error caused by cut'n'paste refactoring.
2017-08-31 14:01:10 +01:00
472ecc65c6 NetworkMapCache database backed (#1135)
Work on database backed NetworkMapCache

Make NodeInfo JPA entity.

Enable node startup with it's database network map cache. Fix schema.
Make node not wait for finishing network map service registration if it
successfully loaded data from database.

Add tests for startup without NetworkMapService.

* Rename networkMapRegistrationFuture

Change networkMapRegistrationFuture to nodeReadyFuture, it no longer
indicates the NetworkMapService registration, because we are able to run
network without map service configured.

* Partially integrate database into NetworkMapCache

Full integrtion will come with service removal.

Move MockServiceHubInternal to net.corda.node.testing

* Add workaround to transaction scope race

Temporary workaround to force isolated transaction (otherwise it causes race conditions when processing
network map registration on network map node).

* Remove WorldMapLocation from NodeInfo

Infer the node's location based on X500 name

Add serial number on NodeInfo

For tests of running without NetworkMap, start nodes with nonexistent NetworkMap address

Make clearNetworkMapCache callable via RPC.
2017-08-31 11:00:11 +01:00
9bd4342039 Removed is relevant from LinearState (#1294) 2017-08-30 16:26:34 +01:00
a9f572c366 Move Jackson client support into net.corda.client.jackson package
Move Jackson client support into net.corda.client.jackson package to match naming scheme used elsewhere
2017-08-30 15:11:03 +01:00
2b7ec0542f Refactoring MockServices class - removing Kt Java class (#1350) 2017-08-30 12:10:42 +01:00
00513883a2 Move HibernateConfiguration into net.corda.node.services.persistence 2017-08-30 10:07:56 +01:00
9664954920 Stop hibernate logging massive byte arrays (at debug level) and causing OOM. (#1351) 2017-08-29 17:31:18 +01:00
65a59f680b Update integration tests to handle new transaction constraints 2017-08-29 17:05:13 +01:00
2facab3be3 Split ClockUtils to improve Java compatibility
Split `ClockUtils` into `MutableClock`, and move the extension functions into `NodeSchedulerService` which is the only thing that uses them.
2017-08-29 16:57:29 +01:00
a2a3f51689 Updated vault query api documentation. (#1338)
* Updated vault query api documentation.

* Readability improvement following PR review feedback.
2017-08-29 16:51:42 +01:00
bc5aceddbf Enable anonymisation in two party deal/trade flows 2017-08-29 16:07:09 +01:00
a84cd567d8 Removing Kt suffixed Java class (#1344) 2017-08-29 13:41:17 +01:00
a027e51ca3 Revert linearId (UniqueIdentifier) Vault Query search attribute (#1325)
* Revert `linearId` (UniqueIdentifier) search attribute for developer convenience.

* Introduced secondary LinearStateQueryCriteria constructor as per MN review comments.

* Fix broken test.
2017-08-29 10:27:43 +01:00
8f0ea714b3 Add IdentitySyncFlow
Add IdentitySyncFlow for synchronizing the certificate paths for confidential identities in a transaction with all counterparties of the transaction.
2017-08-25 17:53:31 +01:00
0fb4465c10 Move default session ID into messaging service
Move default session ID into messaging service to clean up the API. This means it no longer shows up in a Java class (ServiceHubInternalKt) as its only member, and is instead scoped into the service that actually uses the value. This does result in a MessagingService.Companion object (as MessagingService is an interface), however this is probably the most sensible solution.
2017-08-25 16:23:05 +01:00
a35d835d38 Enable autorecovery in RAFT Copycat client
Otherwise it doesn't reconnect after network issues
2017-08-25 15:31:35 +01:00
34b7c89b40 Portable database primary keys
Blob/ByteArray I not allowed as primary key in Oracle
2017-08-25 13:22:09 +01:00
a3dbbc173b Vault query criteria default attribute handling. (#1322)
* Performance fix: prevent self joins on VaultStates table (was occurring when Sort specified).

* Enrichment and overriding of Common attributes (eg. Vault.StateStatus and Contract State Types) using composite query criteria.
Remove unnecessary QueryEditor implementation from NodeVaultService.

* Updated documentation and changelog.

* Misc fixes to broken documentation code snippets.

* Incorporating changes from PR review feedback.
2017-08-25 08:38:12 +01:00
bd48bdfd28 remove Exposed library and JDBCHashMap class 2017-08-24 13:28:26 +01:00
5fe365d483 rewrite BftNonValidatingNotarService to use Hibernate 2017-08-24 11:31:41 +01:00
65c5ce65a6 Adapt CollectSignaturesFlow to handle anonymous transactions
Adapt CollectSignaturesFlow to handle anonymous transactions where the keys signing commands on a transaction are not necessarily the well known identity of the participating nodes. Also prepares for any potential move away from nodes having a single primary identity by requiring flows to specify the identities they're using for a transaction.
2017-08-24 11:19:34 +01:00
d0a3aa3fc7 rewrite RaftUniquenessProvider to use Hibernate 2017-08-24 10:01:04 +01:00