Commit Graph

157 Commits

Author SHA1 Message Date
Anthony Keenan
c2485858f5
CORDA-1011 Add powershell script to update testing package imports (#2528)
* Add powershell script to update testing package imports

* Make sure script works with java files

* Address review comments
2018-02-16 10:22:41 +00:00
Shams Asari
2864ce1384
ENT-1519: Ensure NodeInfo always has at least one address by checking in the c'tor (#2538)
Further, the look up of the node's own node-info from its database has been tightened to ensure there isn't more than one.

Also fixed some brittle code which was assuming exactly one address rather than at least one.
2018-02-15 14:06:41 +00:00
Clinton
eeb96535ee
Re-added missing changelog entries 2018-02-14 17:04:08 +00:00
Clinton
174ed3c64b
CORDA-556: Added Cordapp Config and a sample (#2469)
* Added per-cordapp configuration 
* Added new API for Cordformation cordapp declarations to support per-cordapp configuration
* Added a cordapp configuration sample
2018-02-14 14:49:59 +00:00
Michele Sollecito
da591363fd
CORDA-990: Flows Draining Mode (#2483)
[CORDA-990]: Flows draining mode.
2018-02-12 16:13:43 +00:00
Anthony Keenan
1487c411b4
CORDA-716 - Update changelog for test package changes and provide upgrade script (#2434)
* Update changelog for test package changes and provide upgrade script

* Upgrade kotlin and java scripts
2018-02-12 15:53:29 +00:00
Joel Dudley
3f3e0e9973
Allows the webserver JAR used by each node in deployNodes to be configured. 2018-02-12 14:00:25 +00:00
Anthony Keenan
7b65b7971a
CORDA-939 - Don't expose StartedNode and AbstractNode as part of public test api (#2472)
* 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
2018-02-12 10:09:59 +00:00
Katelyn Baker
3c4212a3d6
CORDA-992 - Make the finger printer pluggable for serialization factory (#2479)
Facilitates easier testing
2018-02-12 10:07:25 +00:00
Patrick Kuo
c8cf46c657
CORDA-961 Wire up and enforce max transaction size (#2465)
* 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
2018-02-09 14:48:45 +00:00
Anthony Keenan
4a68145f23
CORDA-939 Adding documentation changes requested from v3 release branch PR (#2480)
* Adding documentation changes requested from v3 release branch PR

* Further doc changes as requested
2018-02-08 14:38:15 +00:00
Patrick Kuo
941429d3a7
Remove word restriction in corda x500 name (#2439)
* Remove word restriction in x500 name https://github.com/corda/corda/issues/2326

* remove unused const

* address PR issue

* address PR issue

* address PR issue
2018-01-31 17:05:52 +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
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
142f52fa82
[CORDA:936]: Enable RPC layer to work with SSL 2018-01-23 16:23:37 +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
Tudor Malene
c2bd7403a8
hibernate mapping changes (#2337)
* add foreign key names and move the participants mapping to the subclass so that the table name can be configured

* update api-current file

* fix compilation errors

* PR changes

* PR changes
2018-01-10 11:42:08 +00:00
Ross Nicoll
21f0892deb
CORDA-831: Add roles to X509 certificates (#2180)
* Add roles to X509 certificates so that the identity service can always determine which certificate in a hierarchy is the well known identity
* Rename CLIENT_CA certificate type to NODE_CA
* Rename DOORMAN role to INTERMEDIATE_CA
* Correct issue in CashTests where instead of providing a well known identity to generateSpend(), a confidential identity was passed in and a confidential identity generated from it.
* Enforce role hierarchy in PKI
* Enforce that party certificates must be well known or confidential identities
* Add network map certificate role
2017-12-18 16:23:34 +00:00
Shams Asari
00a5e3db6b CORDA-830 Introducing the network bootstrapper
Copying of the node-info files moved out of Cordform and into NetworkParametersGenerator (which is now called NetworkBootstrapper). This class becomes an external tool to enable deployment of nodes in a test setup on a single filesystem.
2017-12-17 23:49:57 +00:00
Matthew Nesbit
595d41af04
AMQP Bridging between nodes (#2181)
* Able to send hand coded messages to an Artemis node inbox

Get startup race condition fixed. Start cleanup work.

Fixup after rebase

Remove SASL hack for now

Minor tweaks. Enable AMQP mode manually.

Add configuration control

Slight clean up

Stop timeouts that don't work with AMQP

Rename class

Get TLS constants from :node-api

Primitive integration test

Put back commented line

Session per bridge to alow rollback on remote rejects.

Add more tests and handle multiple IP adddresses

Reduce logging

Fixup after rebase

Add a test to verify the remote end AMQP rejection logic works and does cause message replay.

Allow Artemis to duplicate after session rollback

Reduce number of threads

Move legacy bridge related code over to CoreBridgeManager

Shared threadpool for bridges

Add a test to confirm that no side effects when using a shared thread pool.

Address PR comments and remove dead lines

Rebase and add some comments

Remove a couple of blank lines

Ensure AMQP bridges are used in tests

Fixup after removal of testNodeConfiguration

Add a couple of doc comments

Add a couple of doc comments

Make things internal and use CordaFuture

Address some PR comments

Change comment type

* Use Artemis 2.2 to fix AMQP problems. Add explicit test of legacy core bridges, as marking the factory class private had silently broken them.

* Fix change due to using Artemis 2.2
2017-12-15 17:48:33 +00:00
Shams Asari
d5f8258bd1 Updated the changelog to incorporate the new network map design as one story. 2017-12-13 20:37:54 +00:00
igor nitto
5720697b0d
[CORDA-827] Improved unit tests coverage and documentation (#2229)
* Extend unit test on RPCSecurityManager
* Fix corner cases in permission parsing and bug in tryAuthenticate
* Rework docsite page
* Add missing ChangeLog entry
2017-12-13 17:09:09 +00:00
josecoll
4762569200
CORDA-822 - JMX Jolokia instrumentation (#2197)
* JMX Jolokia instrumentation WIP (driverDSL, webserver, cordformation, hibernate statistics, access policy config file hardening)

* Cordformation changes to support jolokia agent instrumentation at JVM startup.

* Minor updates to reflect usage of Jolokia 1.3.7 (which uses slightly different .war naming)

* Use relative path reference in -javaagent to prevent problem with long path names with spaces.

* Fixed incorrect regex pattern and added assertion to test.

* Enable JMX monitoring.

* Reporting of Hibernate JMX statistics is configurable (by default, only switched on in devMode)

* Make Artemis JMX enablement configurable.

* Re-instate banning of java serialization.

* Improve JUnit.

* Fixes following rebase from master.

* Re-instated correct regex for picking up Jolokia agent jar.

* Fixed broken integration test.

* Updated documentation

* Updated following PR review feedback.

* Fixed compilation error caused by change in DriverDSL argument type.

* Fixed compilation error caused by change in DriverDSL argument type.

* Fail fast if jolokia-agent-jvm.jar is not located.

* Applied changes in cordformation following review feedback from CA.
2017-12-08 16:27:12 +00:00
Michele Sollecito
cb1fa2e017
Corda now works with H2 without the need to allow Hibernate to create the database automatically. (#2124)
[CORDA-815]: Corda now instructs Hibernate to either adjust or validate the schema based on `devMode` property.

Also renamed property `database.initDatabase` to `database.createSchemaAutomatically`.

* [CORDA-815]: Renamed database.initDatabase to database.adjustSchemas.

* Code review changes: removed property `database.initDatabase` altogether.

* Code review changes: removed property `database.initDatabase` altogether.

* Code review changes: removed property `database.initDatabase` altogether.

* Code review changes: removed property `database.initDatabase` altogether.
2017-11-28 17:33:02 +00:00
Shams Asari
1705df4d1f Made the database config option typesafe, rather than relying on String properties 2017-11-27 13:51:53 +00:00
Maksymilian Pawlak
e63b6d1386
CORDA-311 Shell via SSH server (#2087)
* SSH server integration
2017-11-20 17:41:38 +00:00
Ross Nicoll
8e7165db41
CORDA-759: Enforce key checks on identity de-anonymisation (#1993)
Previously when de-anonymising a Party instance, the name of the Party was used rather than
the key, meaning a Party could be constructed with a random nonsense key and any name, and be treated as corresponding to the well known identity. This is not a security hole in itself as
in any real scenario a party shouldn't be trusted without having been registered, it creates
a significant risk of a security hole depending on how trusted the anonymous identity is, and
the returned identity is considered.
2017-11-17 18:13:35 +00:00
Shams Asari
2fe41715cc On exit, the driver will automaticallly shutdown any nodes which weren't waited for.
The motivation for this came with the recent change that a default notary is started by the driver, which if ignored will leak the notary process.

Also, waitForAllNodesToFinish() has been replaced by a driver parameter.
2017-11-14 20:20:00 +00:00
Patrick Kuo
64a9946f03
Replace artemis network map with http network map (#1970)
* Network map cache using Network map client instead of artemis. -- WIP

* fix up after rebase

* address PR issues, split network map update test, added todos to remove sleeps

* move jimfs and baseDir to field variable
2017-11-14 11:37:50 +00:00
Maksymilian Pawlak
1a02c9a74f
AttachmentCriteriaQuery class and infrastructure (#2022)
* Attachments metadata support
2017-11-14 10:22:02 +00:00
Shams Asari
e6feca2f03 Added verifySignaturesExcept which takes in a colleciton of PublicKeys 2017-11-07 13:00:16 +00:00
Patrick Kuo
22453204ed
move node info schema to internal package (#1976) 2017-11-03 11:30:29 +00:00
Michele Sollecito
d882f8871e
[CORDA-758]: Permissions are now checked for each RPC method. (#1985)
* Permissions are now checked for each RPC method.

* Fixed NodeMonitorModelTest

* Fixed IRSDemoTest
2017-11-02 15:09:49 +00:00
Mike Hearn
d7e4aa1783 Add more formal support for observer/regulator nodes. This is a simplistic
approach which assumes a dedicated node for observers: states that are
reported to the node will appear in the database and update feeds as
normal. Apps that expect all updates to be relevant to themselves may
need adjusting if they run on an observer node too, but this is likely
to be rare.
2017-10-26 18:05:24 +02:00
Katelyn Baker
cbc4003032 Merge pull request #1905 from corda/kat/feature/addEnterpriseAMQPIdentifier
Corda-725 - Change AMQP identifier
2017-10-20 10:21:19 +01:00
Tomas Tauber
342090db62 Experimental support for PostgreSQL (#1525)
* Cash selection refactoring such that 3d party DB providers are only required to implement Coin Selection SQL logic.

* Re-added debug logging statement.

* Updated to include PR review feedback from VK

* Refactoring following rebase from master.

* Fix broken JUnits following rebase.

* Use JDBC ResultSet getBlob() and added custom serializer to address concern raised by tomtau in PR.

* Fix failing JUnits.

* Experimental support for PostgreSQL: CashSelection done using window functions

* Moved postgresql version information into corda/build.gradle

* Using a PreparedStatement in CashSelectionPostgreSQLImpl

* Changed the PostgreSQL Cash Selection implementation to use the new refactored AbstractCashSelection
2017-10-19 14:17:54 -07:00
Katelyn Baker
e6de0aa406 Review Comments 2017-10-19 16:19:42 +01:00
Katelyn Baker
0b7a39f663 CORDA-725 - update changelog 2017-10-19 12:06:00 +01:00
Konstantinos Chalkias
479ab9a36a [CORDA-694] Commands visibility for Oracles (without sacrificing privacy) (#1835)
new checkCommandVisibility feature for Oracles
2017-10-19 10:21:20 +01:00
Clinton
2680361696 Renamed "plugins" dir to "cordapps" (#1644)
* Renamed plugins dir to cordapps dir while maintaining backwards compatibility with the plugins dir.
Bumped gradle plugins to 2.0.4
2017-10-13 15:01:24 +01:00
Chris Rankin
635ad9ac92 Ensure that the contents of OpaqueBytes cannot be modified. (#1871)
* Ensure that contents of OpaqueBytes cannot be modified.
* Update documentation and restore the signature verification check.
* Update the API definition.
* KDoc fixes.
* Update the changelog for v1.1.
2017-10-13 12:27:42 +01:00
Joel Dudley
de391dc9f0 Adds a length method to calculate a time-window's length. 2017-10-11 16:15:24 +01:00
Rick Parker
3fdc69e541 Fix coin selection with Flow-friendly sleep (#1847) 2017-10-11 14:33:20 +01:00
Matthew Nesbit
f19ff141dd Update code to use AppServiceHub in services and support for services when using MockServices hub. 2017-10-10 17:11:32 +01:00
Alberto Arri
3bee830604 [CORDA-442] Removed the NetworkMap option from Cordform, changed all the examples… (#1827)
[CORDA-442]
Removed the option for Cordformation to specify a networkMap.

All the samples have been migrated to not specify a networkMap.
2017-10-10 15:45:42 +01:00
szymonsztuka
8c9045bd73 deployNodes Gradle task appends properties from an optional file to node.conf (#1444)
* deployNodes Gradle task appends properties from an optional file to node.conf
2017-10-10 15:03:05 +01:00
Clinton
484cf75420 CORDA-686 - Split Cordapp gradle plugin from cordformation (#1817)
Added CorDapp gradle plugin written in Kotlin and bumped the version of gradle plugins to 2.0.0 to reflect that this backwards incompatible change is a part of the on going stabilisation of the Corda gradle plugin suite.
2017-10-09 20:08:08 +01:00
Michele Sollecito
29a101c378 [CORDA-683] Enable receiveAll() from Flows. 2017-10-09 13:46:37 +01:00
Shams Asari
727cd0e55c Cleaned up notary configuration by introducing a notary config option.
extraAdvertisedServiceIds is no longer used for this.
2017-10-07 12:52:37 +01:00
Alberto Arri
cf83328d5d Add filesystem polling to nodes (#1623)
Add the logic in node to poll for new serialized nodes to appear on disk.

Newly discovered nodes are automatically added to the PersistentNetworkMapCache
2017-10-05 14:11:10 +01:00