Commit Graph

374 Commits

Author SHA1 Message Date
Dan Newton
750033540a CORDA-2535 - Fixes to IRS demo (#4995)
* CORDA-2535 Move classes from test src to main

For some reason a load of classes were in the test src rather than the
main src even though they were needed during runtime. These have been
moved back into main so they are compiled for use in the demo app.

* CORDA-2535 Fix missing trade id irs-demo home page

Change `deal.ref` to `deal.common.tradeID`

* CORDA-2535 Highlight in irs-demo that `node` module should not be depended on

The demo relies on `node` unless some larger refactoring is made. This
is being kept as it is, but to discourage developers from doing the
same in their CorDapps, a comment has been added to `build.gradle`
explaining why it is there and that developers should not do the same.
2019-05-03 13:47:42 +01:00
Chris Rankin
b5f0004185 BUILD: Tidy up Gradle for irs-demo:web. 2019-03-22 14:56:57 +01:00
Chris Rankin
dc83afb4de CORDA-2672: Tidy up CorDapp deployments in samples. (#4815)
* CORDA-2672: Tidy up CorDapp deployments in samples.

* CORDA-2672: Refactor Attachment Demo.

* Remove Bank of Corda from Trader Demo.

* Configure SLF4J simple loggers, fix comments and documentation.
2019-03-11 16:48:35 +00:00
Mike Hearn
4e98ea3bbf Docs: repair a lot of broken docs pages. 2019-02-21 12:05:07 +01:00
Mike Hearn
96134c8cfa Bugfix: register SwapIdentitiesHandler again. (#4789) 2019-02-19 18:42:32 +00:00
Shams Asari
c39c61ecab
CORDA-2467: Moved non-contract things out of finance-contracts and into finance-workflows (#4700)
This includes all of the cash selection logic, JSON support using jackson and a bunch of utilities which are not relevant to contract verification. The exception to this are Interpolator which has been moved to the IRS demo, and PhysicalLocationStructures.kt which is now in explorer.
2019-02-01 17:31:12 +00:00
Anthony Keenan
84e7cb231d
Minor docs fix (#4675) 2019-01-29 13:10:07 +00:00
Katarzyna Streich
35acbc8107
CORDA-2361: Split samples into contracts and workflows (#4575) 2019-01-23 13:26:33 +00:00
Dimos Raptis
f51cfc34bf
[CORDA-2431] - Reduce memory footprint of classpath scanning (#4576)
* Reduce memory footprint of classpath scanning

* Close scan result in the end
2019-01-15 10:15:40 +00:00
Dimos Raptis
5b34020e59 [CORDA-2390] - Add whitelists and custom serializers from cordapps to serialization … (#4551)
* Add whitelists and custom serializers from cordapps to serialization context

* Remove changes in TransactionBuilder, add caching

* Add whitelists and custom serializers from cordapps to serialization context

* Remove changes in TransactionBuilder, add caching

* Address comments

* Increase node memory for SIMM integration test

* Cache only serialization context

* Increase integ test timeout

* Fix API breakage

* Increase max heap size for web server integ test

* Move classloading utils from separate module to core.internal

* Adjust heap size for more integ tests

* Increase time window for IRS demo transactions

* Fix determinator

* Add parameter in core-deterministic

* Stub out class-loading method for DJVM
2019-01-13 20:15:05 +00:00
Tudor Malene
24d91c5f89
CORDA-2384 - Fix driver classpath (#4472)
* Fix driver classpath

* Fix tests

* Fix classloader bug.

* Fix tests

* Fix tests

* Fix api

* Disable failing irs test.

* Address code review comments

* Remove @Ignore from test

* Remove @Ignore from tests

* Address code review comments.

* Attempt to fix simm valuation test

* Attempt to fix simm valuation test

* Comment failing functionality.
2019-01-03 20:06:35 +00:00
Shams Asari
f590300cdf
CORDA-2345: Updated docs to use the new TestCordapp API, rather than the old scan cordapp packages (#4491)
Also made some improvements to the API, especially for Java users.
2019-01-03 17:57:28 +00:00
Tudor Malene
ee9251bd25
CORDA-2327 add attachments for missing dependencies (#4456)
* CORDA-2327 first draft - add attachments for missing dependencies

* CORDA-2327 draft - fix unit tests

* CORDA-2327 draft - some cleanup.

* CORDA-2327 fix test

* CORDA-2327 fix test

* CORDA-2327 fix test

* CORDA-2327 Address code review comments

* CORDA-2327 fix api

* Address code review comments

* CORDA-2327 Address code review comments

* CORDA-2327 Address code review comments

* Fix merge

* Address code review comments
2019-01-02 16:16:53 +00:00
Anthony Keenan
af75a05502
Fix irs-demo dependency issues (#4438)
* Fix irs-demo dependency issues

* Fixed a problem with the IRS demo test JAR.

* Fixed deployNodes problem and log4j info statement.
2018-12-20 12:31:16 +00:00
szymonsztuka
4aaefb4fe9 CORDA-2331 Split Workflow and contracts of Finance App into separate Cordapps (#4422)
* Split Workflow and contracts of Finance App into separate Cordapps, part 1 - content which is different between OS and ENT is still in contract Cordapp.

* Move CashSelection implementations to workflow module.

* Move CashSelection implmentations to workflow module.

* Move finance module to finance-flows, top level finance module is empty.

* Move finance module to finance-flows, top level finance module is empty.

* Updated build comment.

* Revert publication of combined (contracts and flows) corda-finance.jar (to maintain backwards compatibility with 3rd party cordapps dependent on finance)

* Added backwards compatibility clarification comment.

* Re-instate new cordapp metadata.

* Global rename of `finance-flows` to `finance-workflows` to follow adopted naming conventions.

* Addressed final review comments.

* Rename application to "Corda Finance Demo"

* Generation of original corda-finance jar from new sub-modules.

* Fixed and tested demobench with new split finance contract and workflow jars.

* Renamed finance sub-modules to contracts and workflows.

* Remove Michele!!!

* Minor fix to filtering logic.

* Align CorDapp configuration filename with workflows jar.

* Fix breaks caused by finance module naming changes.

* Final alignment between OS/ENT of finance contract code.
2018-12-19 18:02:51 +00:00
josecoll
9cdda3bd77
CORDA-2149 CorDapp Contract and Workflow version identifiers (#4363)
* Implementation of Contract and Workflow attribute identifiers.

* Fixes following rebase from master.

* Fix broken JUnit test.

* Fix broken JUnit test.

* Fix broken JUnit test.

* Added missing constants.

* Further clean-up.

* Updated documentation.

* Added changelog entry.

* Updated all samples (using new Gradle Plugin 4.0.37 functionality)

* Temporarily resolve gradle plugins from latest published snapshot.

* Temporarily resolve gradle plugins from latest published snapshot.

* Updates following feedback from PR review.

* Move constants into CordappInfo companion object.

* Contract and Workflow attribute `version` to `versionId` (as version is a reserved gradle variable)

* Clarified warning message on incorrect version identifier.

* Align version identifier processing logic with gradle cordapp plugin.

* Updated comment.

* Minor fixes following rebase from master.

* Fixed broken unit test.

* Improved exception reporting.

* Update to use 4.0.37 of Gradle Plugins.

* Added support for combined Contract and Workflow CorDapp info.

* Updated following discussions with Shams + cleanup.

* Updated following Shams PR review.

* Minor API improvements.

* Added missing cordapp info causing deployNodes to fail.
2018-12-14 09:39:23 +00:00
Michele Sollecito
c31da13c70
[CORDA-2213]: IRS Demo is unable to simulate future dates (fix). (#4384)
* [CORDA-2213]: IRS Demo is unable to simulate future dates (fix).

* [CORDA-2213]: IRS Demo is unable to simulate future dates (fix).
2018-12-07 16:59:52 +00:00
Andrius Dagys
838c99c6e4 CORDA-2115: Notary whitelist verification changes (#4293)
* CORDA-2115: Notary whitelist verification changes

- For regular and contract upgrade transactions: check that the notary is in the network parameter whitelist
- For notary change transactions: check the the new notary is in the network parameter whitelist. This enabled support for network merging: the old notary doesn't have to be in the current network's notary whitelist for re-pointing old states to another notary.

These checks are done during transaction construction/verification and also by the non-validating notary.

* Address comments

* Remove stale todo

* Use notary whitelist of current network parameters for platform versoin 3

* Cleanup test

* Move `getHistoricNotary` to `HistoricNetworkParameterStorage` in `core.internal`

* Require `newNotary` to be notary on the network map during notary change
2018-12-04 13:54:24 +00:00
tudor.malene@gmail.com
1e27f0cbe0 Merge remote-tracking branch 'private/master' into feature/tudor_constraints
# Conflicts:
#	core/src/main/kotlin/net/corda/core/transactions/LedgerTransaction.kt
#	core/src/main/kotlin/net/corda/core/transactions/TransactionBuilder.kt
#	core/src/main/kotlin/net/corda/core/utilities/KotlinUtils.kt
#	node/src/test/kotlin/net/corda/node/services/persistence/NodeAttachmentServiceTest.kt
2018-11-14 11:50:19 +00:00
Michele Sollecito
dc62b20c5d
[CORDA-1879]: Ensure Node dies on unrecoverable errors. (#4213) 2018-11-12 15:56:04 +00:00
Anthony Keenan
30fedec343
CORDA-1838: A few misc fixes (#4126)
* Remove unused code

* Make comment readable

* Remove joptsimple from node/shell

* tabs vs whitespace
2018-10-30 14:01:20 +00:00
tudor.malene@gmail.com
29a8c153ed Merge branch 'master' into tudor_merge_os_24_10
# Conflicts:
#	core/src/main/kotlin/net/corda/core/internal/JarSignatureCollector.kt
#	core/src/main/kotlin/net/corda/core/transactions/LedgerTransaction.kt
#	core/src/main/kotlin/net/corda/core/transactions/TransactionBuilder.kt
#	core/src/main/kotlin/net/corda/core/utilities/KotlinUtils.kt
#	core/src/test/kotlin/net/corda/core/contracts/PackageOwnershipVerificationTests.kt
#	core/src/test/kotlin/net/corda/core/internal/JarSignatureCollectorTest.kt
#	node/src/main/kotlin/net/corda/node/internal/cordapp/JarScanningCordappLoader.kt
#	node/src/test/kotlin/net/corda/node/services/persistence/NodeAttachmentServiceTest.kt
#	testing/test-utils/src/main/kotlin/net/corda/testing/dsl/TestDSL.kt
#	testing/test-utils/src/main/kotlin/net/corda/testing/dsl/TransactionDSLInterpreter.kt
#	testing/test-utils/src/main/kotlin/net/corda/testing/internal/MockCordappProvider.kt
2018-10-24 17:09:30 +01:00
Rick Parker
55731ef816
ENT-2431 Tidy up buildNamed and CacheFactory 2018-10-18 10:38:43 +01:00
Florian Friemel
47068e6b7a [CORDA-2077] Use latest gradle plugin version (4.0.32), set target version in core and sample CorDapps (#4038)
* Upgrade gradle plugin; add target version attribute to finance and sample cordapps.
* Remove '-SNAPSHOT' from gradlePluginsVersion.
* Fix naming.
* Update docs.
* Respond to feedback.
* Fix irs demo
* Fix more samples
* Fix more samples
* Fix deployNodes
* Fix deployNodes
* more fixes
* fix simm valuation
* more fixes
* more fixes
* more fixes
* more fixes
* Publication should have *nothing* to do with cordformation and deployNodes.
Remove it! And if this exposes a bug then "so be it".
* Disable CorDapp signing for Cordapp Configuration and Network Verifier.
* Disable CorDapp signing for SIMM Valuation Demo.
* Remove remaining publishing nonsense from samples.
* Workarounds fpr cordapp-configuration, network-verifier and simm-valuation-demo:
JarSigner rejects jars with duplicates inside, so remove them.
* Upgrade to Gradle plugin 4.0.32 and reenable CorDapp signing for samples.
2018-10-15 21:11:52 +01:00
Tudor Malene
f96a59932c ENT-2222 Constraints propagation
ENT-2222 Fix tests

ENT-2222 Fix tests

ENT-2222 Add ledger transaction verification logic

ENT-2222 Fixed IRS test

ENT-2222 Fixed IRS test

ENT-2222 Fixed unit test

ENT-2222 Better kdocs

ENT-2222 Support for reference states

ENT-2222 Fix support for reference states

ENT-2222 Revert wrong change

ENT-2222 Fix Kdoc

ENT-2222 Fix Kdoc

ENT-2222 Better docs

ENT-2222 Address code review comments

ENT-2222 Fix test

ENT-2222 Fix rebase

ENT-2222 Add documentation around constraint propagation

ENT-2222 Add tests for contract propagation

ENT-2222 Add Signature Constraints propagation - first draft

ENT-2222 fix tests

ENT-2222 more tests

ENT-2222 unseal the TransactionVerificationException

ENT-2222 unseal the TransactionVerificationException

ENT-2222 more docs

ENT-2222 address code review comments

ENT-2222 address code review comments

ENT-2222 re-implement transition logic

ENT-2222 better comments and checks

ENT-2222 Fix tests

ENT-2222 merge fixes
2018-09-28 13:38:35 +01:00
szymonsztuka
c23167f08e
ENT-2188 fix H2 insecure default configuration (#3692)
Set the "h2.allowedClasses" system property, require database password when exposing H2 server on non-localhost address, samples start H2 server by default (reintroduces the behaviour before h2Settings.address configuration option was added)
2018-08-01 11:50:42 +01:00
Viktor Kolomeyko
d481c55b82
CORDA-1743: Remove isDebug = true from Node driver to speed-up integration tests execution. (#3535)
* CORDA-1743: Remove `isDebug = true` from Node driver to speed-up integration tests execution.

* CORDA-1743: Undo removal of "isDebug = true" from the test that specifically checks for this condition.

* CORDA-1743: Address input from @shamsasari
2018-07-09 16:37:01 +01:00
Shams Asari
aefd90f062
Minor: ProcessUtilities clean up (#3533) 2018-07-09 12:29:33 +01:00
Shams Asari
244167d3e9
Enabled warnings as errors (#3514) 2018-07-04 17:17:27 +01:00
Chris Rankin
d634cdcbac
Clear some cut-and-paste cruft out of our Gradle files. (#3511) 2018-07-04 15:42:43 +01:00
Michele Sollecito
f68cf6f712
[CORDA-1341]: Ensure API can be called concurrently wrt transactions. (#3235) 2018-05-29 15:25:34 +01:00
bpaunescu
bff419e9af
Corda-1505 catch connection failure exception and re-throw as RPCException (#3203)
* CORDA-1505: catch connection failure exception and rethrow as RPCException

* CORDA-1443: remove incorrect import

* CORDA-1443: fix some failing tests

* CORDA-1505: fix broken CordaRPCClient test

* fix tests

* CORDA-1505: catch connection failure exception and rethrow as RPCException

* CORDA-1443: remove incorrect import

* CORDA-1443: fix some failing tests

* CORDA-1505: fix broken CordaRPCClient test

* fix tests

* CORDA-1505: changed exception handling to RPCException

* CORDA-1505: changed exception handling to RPCException
2018-05-21 18:01:31 +01:00
Andrzej Cichocki
65b782c206
ENT-933 Add spectator and participant profiles of rigorousMock (#3157) 2018-05-16 13:56:41 +01:00
Michele Sollecito
d027b5b8f2
[CORDA-1472]: Crackdown on warnings. (#3136) 2018-05-14 21:15:52 +07:00
Andras Slemmer
ce5fb66260 StateMachine rewrite 2018-04-23 15:36:16 +01:00
Anthony Keenan
ec09188559
[CORDA-1292] Add CordaService testing documentation and improve tests in irs-demo (#2929)
* Add CordaService testing documentation and improve tests in irs-demo

* Addressed review comments
2018-04-06 09:22:58 +01:00
Viktor Kolomeyko
d5317e074c
Remove errorLogPath parameter which is not used anyway. (#2934)
StdErr is always written to working directory if such path specified.
2018-04-05 18:10:47 +01:00
Joel Dudley
7deb802547
Adds link from changelog to upgrade notes. 2018-04-03 18:03:07 +01:00
Viktor Kolomeyko
64871ac024
Fix IRSSimulationTest test (#2821)
* Fix `IRSSimulationTest` test

Since prod class `IRSSimulation` loading `trade.json` as resource, `trade.json` should be located in prod resources folder of a dependant project to be successfully loaded.

Also improve error reporting.

* Change of Json trades samples locations
2018-03-15 14:40:22 +00:00
igor nitto
2cff495553
Remove CordApps JARs from node classpath [CORDA-1135] (#2691) 2018-03-14 16:42:23 +00:00
Michele Sollecito
b580a2ac30
[CORDA-926]: Parsing NodeConfiguration will now fail if unknown properties are present. (#2484) 2018-03-01 14:57:36 +00:00
Anthony Keenan
577033441a
[CORDA-1035] Testing api KDoc Updates (#2584)
* Testing api KDoc Updates

* Update after code review

* Update api-current

* Revert changes to compiler.xml

* Made comment changes from review

* Fixing merge conflict

* Don't expose net.corda.node through test API (first pass)

* Fixing merge conflicts

* Update api-current

* Addressing review commits

* Fix exposure of internal implementation of MessageHandlerRegistration

* Make InProcess expose ServiceHub instead of internal StartedNodeServices

* Move InternalMockMessaginService interface to internal namespace

* Move MOCK_VERSION_INFO to internal namespace to avoid exposing VersionInfo

* Don't expose WritableTransactionStorage via testing api

* Create public VerifierType enum

* Update api-current and modify check-api-changes to check for net.corda.node exposures

* Fix merge conflicts

* Fixing another merge conflict

* Fix accidentally broken unit tests

* Make getInternalServices a property

* Fix failing unit tests

* Add todo to check-api-changes

* Fix rpc sender thread busy looping

* Fix tests

* Fixing tests

* Address mike's comments

* Fixing tests

* Make random port allocation internal

* Update api
2018-02-28 13:26:49 +00:00
Tommy Lillehagen
a542c0185d CORDA-1103 - Fix JAR paths in IRS demo launcher 2018-02-28 11:39:31 +00:00
Tommy Lillehagen
3572ce05fa CORDA-1102 - Fix IRS demo README 2018-02-28 10:03:15 +00:00
Maksymilian Pawlak
b91ef43e0f
Remove the debug helper which should never make it into master (#2633)
* Remove IRS Docker demo helpers
2018-02-26 15:47:04 +00:00
Matthew Nesbit
b8fa44d721
The IRS demo has a clash between web server ports and the regulator node on port 10010. This bumps the ports up by 1 to fix the issue. (#2562) 2018-02-16 18:17:15 +00:00
Maksymilian Pawlak
fa34a16f27
IRS Docker nomenclature fix (#2531)
* We check properties, so why I named them variables?
2018-02-15 12:05:10 +00:00
Maksymilian Pawlak
b91dd43a83
Test driver default parameters removal (#2519)
* Removed long parameter list in test driver, replaced with DriverParameters object
2018-02-13 13:15:05 +00:00
Joel Dudley
ad1be79900
Reorders params to put non-default args first. Creates simpler default constructors. 2018-02-12 17:02:34 +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