Commit Graph

6684 Commits

Author SHA1 Message Date
Shams Asari
51adf9b678
LedgerTransaction no longer a data class to prevent more copy methods and fixed serialisation issue (CORDA-2231) (#4287)
LedgerTransaction is not meant to be created directly from client code, but it being a data class means we will expose new copy methods as new properties are added. The existing copy methods that we've exposed since V3 are deprecated, and equals and hashCode have been updated to be based just on id.

The primary c'tor has been clearly marked as the class' wire format, and so the internal stuff has been moved out. The references property cannot be made nullable and so DeprecatedConstructorForDeserialization is used instead.
2018-11-22 22:53:24 +00:00
Shams Asari
49d1cee6d4
Removed crypto service config (#4284) 2018-11-22 20:30:37 +00:00
Tudor Malene
4c8dabc288
ENT-2506 restore the attachment party signers (#4255)
* ENT-2506 restore the attachment party signers

* ENT-2506 restore the attachment party signers

* ENT-2506 restore the attachment party signers

* ENT-2675 Address code review changes.

* ENT-2675 Address code review changes.
2018-11-22 18:35:30 +00:00
Roger Willis
c41960520c
CORDA-2232: external id to pubkey mapping (#4210)
* First pass
Update test.
Address review comments.
Added docs and kdocs.
Clean-up.

* Addressed review comments.

Changes to docsite.

* First pass at account service.
Added new hibernate schemas and liquibase scripts.
Added indexes to new tables.
Removed mock network.
Removed fresh key for external id from key management service.
Removed some redundant changes.
Rebase to master.

* Clean up.

* Added try/catch block as recommended by Andras.

* Removed accounts test to another branch.
Removed element collections from fungible states and linear states table.
Added a new state_parties table which stores x500 names and public key hashes.
Added a view which can be used to query by external ID.

* Removed try catch block. It's not required as the checkpoint serialiser deals with this.
Re-used existing DB session instead of creating a new session.
Entity manager auto flushes.

* Added java friendly api.

*  This is a combination of 10 commits.
 This is the 1st commit message:

Shortened table name.

 This is the commit message #2:

Minor changes.

 This is the commit message #3:

Common criteria parser now returns a predicate set which is concatenated to the predicate sets of sub-class criteria.

 This is the commit message #4:

Fixed api compatibility issue.
Reverted some changes to reduce size of PR.

 This is the commit message #5:

Multiple states can now be mapped to the same externalId.
Multiple externalIds can now be mapped to the same state.

 This is the commit message #6:

Relaxed upper bound type constraint in some of the vault types.

 This is the commit message #7:

Added comment to test.

 This is the commit message #8:

Changed name of external id to public key join table.
Removed some comments/TODOs.

 This is the commit message #9:

Added docs.
General clean up.

 This is the commit message #10:

Fixed participants query bug and updated unit test.

* Removed unused code.
2018-11-22 14:31:34 +00:00
Michele Sollecito
33ce00e8b1
[CORDA-2244]: Specified unique applicationId for Capsule manifest. (#4283) 2018-11-22 13:53:14 +00:00
Dominic Fox
2c6bce3e5d
CORDA-2099 serialisation rewrite (#4257)
* Type model first draft

* Introduce TypeIdentifier

* Attempting to retrofit fingerprinter with type model

* Complete retrofitting typemodel to fingerprinter

* Ensure component types are resolved correctly

* Fixes and tests

* Move resolveAgainst to TypeIdentifier

* Remote type modelling and reflection

* Convert TypeIdentifiers back into types

* Translate AMQP type strings to type identifiers

* Start replacing DeserializedParameterizedType

* Start roundtripping types through AMQP serialization

* Comments on type modelling fingerprinter

* kdocs and interface reorganisation

* Lots and lots of kdocs, bugfix for cyclic references

* Separate SerializerFactory construction from concrete implementation

* Fewer build methods

* Method naming that doesn't fatally confuse determinisation

* Extract SerializerFactory interface

* Reset to master's version of compiler.xml

* Un-ignore flickering test

* Enums don't have superclasses

* Break out custom serializer registry

* Refactor to separate remote and local serializer factories

* Shrink interfaces

* Further interface narrowing

* Fingerprinting local type model

* LocalSerializerFactory uses LocalTypeInformation

* Resolve wildcards to their upper bounds

* Actually cache custom serializers

* Fix various bugs

* Remove print statements

* There are no cycles in type identifiers

* Drive class carpentry from RemoteTypeInformation

* Refactor and comment

* Comments

* Comments and pretty-printer extraction

* Format long methods with braces

* Serialise composable types using LocalTypeInformation

* Warnings if a type is non-composable

* Rename lookup -> findOrBuild

* Evolution serialisation (no enums yet)

* Eliminate old ObjectSerializer and evolver

* Enum evolution

* Opacity claims types less greedily

* Fix type notation and type erasure bug

* Clean up unused code paths

* Delete unused codepaths

* Move whitelist based type model configuration to own file

* Move opaque type list

* Make all evolution serialisers in one go when schema received

* Minor tweaks

* Commenting and tidying

* Comments

* Rebase against master

* Make flag for controlling evolution behaviour visible

* propertiesOrEmptyMap

* Restore error messages

* Test for CORDA-4107

* PR fixes

* Patch cycles in remote type information after creation

* Fix line breaks in unit test on Windows

* This time for sure

* EvolutionSerializerFactoryTests

* Fix some pretty-printing issues, and a carpenter bug

* PR fixes

* Clarify evolution constructor ordering

* Remote TODO comment, which has been moved to a JIRA story
2018-11-22 11:44:40 +00:00
James Brown
98a495fa84
CORDA-2199 NetworkParameters certificate role (#4278) 2018-11-22 10:49:18 +00:00
Tudor Malene
504f650022
ENT-2763 - Change packageOwnership type (#4273)
* ENT-2763 - Change packageOwnership type

* ENT-2763 - Address code review comment.

* ENT-2673 Address code review comments.

* ENT-2673 Address code review comments.

* ENT-2673 Fix test

* ENT-2673 Address code review comments.
2018-11-21 20:41:56 +00:00
szymonsztuka
014f71d36a
CORDA-2150 testing infrastructure for non downgrade contract version rule - TestDSL creates Jar with manifest file (#4274)
This is preliminary addition to test "Implementation-Version" entry from META-INF/MANIFEST.MF in TestDSL.kt. MockCordappProvider was creating JAR without manifest file. Added the manifest file with the obligatory (by JAR spec) attribute "Manifest-Version", other attributes can be added.
2018-11-21 18:36:30 +00:00
Thomas Schroeter
489e719b54
[CORDA-2243] Notary client should sign over NotarisationRequest serialised with object referencing turned off (#4264)
* Sign later to make sure the notary service constructs the same serialized bytes

* Add non validating notary tests

* Revert "Sign later to make sure the notary service constructs the same serialized bytes"

This reverts commit cefba5c350.

* Dereference SecureHashes before creating the notarisation request signature

* Update comment

* Address comments

* Undo accidental renaming
2018-11-21 16:50:32 +00:00
Dominic Fox
227f5c7e7c
Fix unit test failure due to Windows end-of-line characters (#4271) 2018-11-21 15:56:56 +00:00
Joel Dudley
8f5e62a326
Update testnet-explorer-corda.rst (#4270) 2018-11-21 12:54:58 +00:00
Oliver Knowles
b8ac16fd0f
Fix node configuration doc for network parameter auto-acceptance settings (#4268) 2018-11-21 12:51:21 +00:00
Andrius Dagys
6c69d9ae0a Address util tests: remove invalid test case (#4269)
Local host address can also be public
2018-11-21 12:13:04 +00:00
Joel Dudley
faa9606dea
Combines all contributing info in one place. Clean-up. (#4266) 2018-11-20 18:17:11 +00:00
Viktor Kolomeyko
0fe7f513e2
ENT-2653: Introducing CommonCliConstants (#4265) 2018-11-20 17:15:48 +00:00
Andrius Dagys
f64eae8fdb Add omitted flow async operation test 2018-11-20 14:34:04 +00:00
Tudor Malene
f321c4c0d0
ENT-2675 Improve error message (#4258)
* ENT-2675 Improve error message

* ENT-2675 Improve error message
2018-11-20 14:19:32 +00:00
Michele Sollecito
97c1e5babc
[CORDA-2211]: Added error for older bash versions when attempting to install shell extensions. (#4263) 2018-11-20 14:01:39 +00:00
Konstantinos Chalkias
e14ade58e3
[CORDA-2218] CryptoService signingCertificateStore alias match (#4227) 2018-11-20 13:52:10 +00:00
Stefano Franz
bbd5369e04 Add Docker image as output of build (#4223) 2018-11-20 13:38:44 +00:00
szymonsztuka
8827801ae6
CORDA-1915 Release notes for build system signing CorDapp JARs. (#4185) 2018-11-20 13:53:11 +01:00
Oliver Knowles
373d99435c
CORDA-1965 Auto-accept network parameter changes (#4222)
* add auto acceptance of certain network parameters

* Remove incorrect nullification of newNetworkParameters object within NetworkMapUpdater

* Automatically update network parameters if update accepted and flag day occured

* Comment cleanup

* Add node configuration for auto accepting network parameter changes

* Remove hot swapping of network parameters

* Add docs for auto accept config flag

* Minor change to log line

* Remove unrelated fix that was corrected on master

* Minor name change within NetworkParameters class

* Minor doc rewording

* Fix typo in docs

* Address PR comments

* Add node config option to turn off network param auto-accept on a per param basis

* Address PR comments

* Fix failing Network Map update integration test
2018-11-20 09:50:42 +00:00
Michele Sollecito
2762c34ebe
[CORDA-1877]: Ensured Driver fails to start when Notary tried to bind an already bound port. (#4246) 2018-11-19 18:06:27 +00:00
Michele Sollecito
cb9fc3391f
Merge pull request #4256 from corda/hide_error_codes_for_config_parsing_issues 2018-11-19 16:51:21 +00:00
Michele Sollecito
b9f2401123 Removed errorCode for raw configuration parsing errors. 2018-11-19 16:47:57 +00:00
Dominic Fox
ddf45f4e07
CORDA-2099: define local type model (#4118)
* CORDA-2099 define LocalTypeInformation and related data types and functions

* Enums don't have superclasses

* Separate ACollection from AMap

* Remove spurious import

* Small fixes, slightly improved testing

* Log warnings if types that we expect to be able to serialise are non-composable

* Rename lookup -> findOrBuild

* Pull changes from working branch

* Missing files needed for unit test

* Pull in whitelist-based type model configuration

* Move opaque type list across

* Remote duplicate declaration

* Restore fixes from other PR
2018-11-19 16:07:01 +00:00
Mike Hearn
349d9a5ffe Expose SerializedBytes.from in the API 2018-11-19 14:25:39 +00:00
Tudor Malene
2d043828a0
CORDA-2083 verify transaction in AttachmentsClassloader (#4188)
CORDA-2083 fix tests

CORDA-2083 fix tests

CORDA-2083 fix tests

CORDA-2083 fix tests

CORDA-2083 fix tests

CORDA-2083 fix tests

CORDA-2083 fix tests

CORDA-2083 add support for explicit upgrade transactions

CORDA-2083 cleanup

CORDA-2083 cleanup

CORDA-2083 More cleanup

CORDA-2083 More cleanup

CORDA-2083 Clean up tests

CORDA-2083 Address code review comments

CORDA-2083 Fix merge

CORDA-2083 Fix merge

CORDA-2083 Address code review comments

revert file

CORDA-2083 Fix test

CORDA-2083 Add test

CORDA-2083 cleanup

CORDA-2083 Fix test

CORDA-2083 Address code review comments.

CORDA-2083 Remove unused functions.

CORDA-2083 Address code review comments.

CORDA-2083 Address code review comments.

CORDA-2083 Address code review comments.

CORDA-2083 Address code review comments.

CORDA-2083 Address code review comments.
2018-11-19 13:42:12 +00:00
Mike Hearn
38a4737764 Small tweaks useful for the experimental C++ support. 2018-11-19 12:37:31 +00:00
Mike Hearn
a867e7cb8b Bugfix: make decimal64 amqp type work (nothing uses it today) 2018-11-19 12:37:31 +00:00
Joel Dudley
1658cb0269
Updates running-a-cordapp to point to new samples page. (#4251) 2018-11-19 12:19:05 +00:00
Stefano Franz
828892a3d9
write nodeInfo to additional-node-info folder as well as baseDirectory (#4247)
* write nodeInfo to additional-node-info folder as well as baseDirectory

* fix broken network map tests
2018-11-19 11:26:42 +00:00
Joel Dudley
0c323bce5c
Documents Corda dependencies. Clean-up. (#4196)
* Documents Corda dependencies. Clean-up.

* Review feedback.

* Addresses review feedback.
2018-11-19 11:09:33 +00:00
Dominic Fox
f66944cac5
CORDA-2099 remote type model (#4179)
* CORDA-2099 create remote type model

* Comments

* Test the class-carpenting type loader

* Comment on cache usage

* Pull changes from main serialisation branch

* Add missing file

* Minor tweaks
2018-11-19 11:03:32 +00:00
Anthony Keenan
8ea6f1c7c5
[CORDA-2004]: Update CLI UX guidelines for backwards compatibility (#4248)
* Update CLI UX guidelines for backwards compatibility

* De-lousing

* Spelling mistake
2018-11-18 12:36:21 +00:00
Roger Willis
4c88e26a46
Fixed incorrect diagram. (#4212) 2018-11-18 11:35:56 +00:00
Stefano Franz
8f463c46a9 Add message to uses of require(...) (#4192) 2018-11-16 17:13:55 +00:00
Stefano Franz
51e66af2fd CORDA-2201 add documentation for hiding passwords in node.conf (#4221) 2018-11-16 17:10:53 +00:00
Mike Hearn
4d2d9b8304 Fix a regression in the shell that was preventing it from fuzzy matching against notary names. 2018-11-16 14:37:43 +00:00
Shams Asari
d138914640
Using epoch for the entries in the test CorDapp jars to remove that non-determinism (#4243) 2018-11-16 12:19:29 +00:00
Anthony Keenan
3ea03068b8
Update picocli to latest version (#4241) 2018-11-16 10:10:52 +00:00
Joel Dudley
0e51d11743
Update CONTRIBUTORS.md 2018-11-15 09:49:59 +00:00
Joel Dudley
1d2b99f616
Removes a reference to an outdated JIRA ticket. (#4238) 2018-11-15 09:31:20 +00:00
Konstantinos Chalkias
b8327ddf98
[CORDA-2225] Use platform's non-blocking PRNG when invoking SecureRandom() (#4234) 2018-11-14 18:32:22 +00:00
Andrius Dagys
e1e5d13941
CORDA-2221: Fix clustered notary identity generation (#4230)
- Don't generate a composite key certificate for CFT notaries
- Don't require a composite key certificate for CFT notaries on startup
2018-11-14 18:15:05 +00:00
Hristo Gatsinski
eb9bd10da0 [CORDA-2219] Show message if CorDapp already exists (#4236)
* [CORDA-2219] Show message if CorDapp already exists

* Update definition of `net.corda.core.node.services.Vault$StateMetadata` in `api-current.txt` or else diff tool gets very confused.
2018-11-14 17:50:55 +00:00
Michele Sollecito
4059966ccb
[CORDA-2203]: Demobench ends up with a stuck tab when you unselect notary type for the first node. (fix) (#4235) 2018-11-14 14:42:57 +00:00
Shams Asari
e8b6f5f2f2
CORDA-2005: FinalityFlow has been made into an inlined flow to resolve issue with FinalityHandler (#4050)
FinalityHandler is insecure in that it is open to receive any transaction from any party.

Any CorDapp targeting platform version 4 or above is required use the new c'tors which take in FlowSession objects to the counterpart flow. This flow must subcall ReceiveFinalityFlow to receive and record the finalised transaction.

Old CorDapps (with target platform version < 4) will continue to work as previously. However if there are no old CorDapps loaded then the node will disable FinalityHandler.
2018-11-14 14:16:22 +00:00
Tudor Malene
8e6d4b4b38
Merge pull request #4232 from corda/feature/tudor_constraints
Feature/tudor constraints
2018-11-14 13:33:39 +00:00