Commit Graph

1078 Commits

Author SHA1 Message Date
Shams Asari
457f95f188 Removed the network map service type as it's no longer needed.
The absence or presence of the networkMapService config is what determines if a node is the network map or not.
2017-10-03 11:32:37 +01:00
Clinton
fee156cc4a Added a contract constraints section to the key concepts doc. (#1704)
Documentation for contract constraints.

Added to index.

Review fixes round 1.

More review fixes.

Review fixes.

Explained package contents.

review fixes.

Addressed RGB's final review comments.

Updated source code type to 'java'
2017-10-02 17:54:31 +01:00
Rick Parker
9a16011448 * Move CompositeSignaturesWithKeys into net.corda.core.crypto package.
* Rename and move CordaPluginRegistry to reflect its real purpose now.
* Docs: docsite improvements
* Remove discussion of webserver from 'writing a cordapp' page.
* Fixup some flow docs.
* Add a couple more package descriptions.
* Review comments - always apply default whitelist and no longer load it via ServiceLoader
* Added wording about renaming services resource file
2017-10-02 16:03:07 +01:00
Joel Dudley
ef9b54327a Checking out the latest milestone will no longer be required. 2017-10-02 15:01:19 +01:00
Joel Dudley
f961412396 Fixes a formatting issue. 2017-10-02 09:09:16 +01:00
Joel Dudley
2a1a9c9d20 Updates hello world tutorials for v1.0. 2017-10-02 09:08:59 +01:00
Joel Dudley
4641d3c4dd Moves code sections in tutorials to code files. 2017-10-01 23:33:15 +01:00
Joel Dudley
e9ec8f9650 Fixes docsite dead links. 2017-09-29 17:42:49 +01:00
Clinton
de88f3ecba Contract constraints documentation (#1703)
* Added a contract constraints section to the key concepts doc.

* Documentation for contract constraints.

* Added to index.

* Review fixes round 1.

* More review fixes.

* Review fixes.

* Explained package contents.

* review fixes.

* Addressed RGB's final review comments.

* Updated source code type to 'java'
2017-09-29 16:29:09 +01:00
Viktor Kolomeyko
c2b0ed6ed5 CORDA-650: Eliminate unnecessary dependency on "graphstream" library (#1732)
This library has one usage in ClientRPC example and:
* Uses Scala 2.10 - which is quite dated
* Has a transitive dependency on JUnit
2017-09-29 13:43:42 +01:00
Katelyn Baker
ddee4b94e2 CORDA-594 - SIMM Demo doc update (#1723)
* CORDA-594 - SIMM Demo doc update

For V1 write a series of JSON / curl commands a user can follow to run
the demo

* Review Comments

* Updated the rationale behind as to why SIMM was introduced.

* typo
2017-09-29 12:27:48 +01:00
Alberto Arri
5e5f9d7790 add message warning windows users they might need to manually kill explorer demo nodes started by gradle (#1717) 2017-09-28 16:44:05 +01:00
Katelyn Baker
5ed755d3fe CORDA-653 - Serialised enums should respect whitelist (#1692) 2017-09-27 18:02:35 +01:00
Konstantinos Chalkias
c8fc1b624b Updating docs w.r.t. new FilteredTransaction and TransactionSignature (#1678) 2017-09-27 15:51:44 +01:00
Andras Slemmer
72cff032e6 FlowSession docs (#1660) 2017-09-27 15:33:09 +01:00
josecoll
512de2690d Added changelog entry. (#1691) 2017-09-27 15:29:00 +01:00
Rick Parker
0c910640bb Misc documentation fixes (#1690) 2017-09-27 15:14:39 +01:00
Andras Slemmer
2054827528 Merge pull request #1650 from corda/aslemmer-rpc-delay-arg-deserialisation
Delay RPC arguments deserialisation to allow routing of errors
2017-09-27 13:47:19 +01:00
Andrius Dagys
7a55855afb Fix validating notary flow to handle notary change transactions properly.
Add a notary change test for checking longer chains involving both regular and notary change transactions.
2017-09-27 13:44:57 +01:00
josecoll
241f843555 Unification of VaultQuery And VaultService APIs (into single VaultService interface) to simplify node bootstrapping and usability. (#1677) 2017-09-27 13:33:23 +01:00
Clinton
24ff7efd5f Cordapps now have a name field (#1645)
* Cordapps now have a name field.
2017-09-26 17:15:11 +01:00
Michele Sollecito
63168c0299 [CORDA-481]: GH 965: Java 8 lambdas don't work properly in checkpointing (#1619) 2017-09-26 13:22:59 +01:00
Alberto Arri
246ab26d30 Properly escape backslashes in windows paths (#1556)
* fix some backslashes in the windows paths in the docs


This reverts commit 4532bca580.
2017-09-26 12:54:28 +01:00
Andras Slemmer
9d115a2111 Delay RPC arguments deserialisation to allow routing of errors 2017-09-26 11:18:11 +01:00
Shams Asari
4df8b427d2 Removed SSLConfiguration parameter from CordaRPCClient, thus removing SSL support.
The current use of SSL RPC relies on access to the node's keystore file, and further to that some uses where using the NODE_USER to login on the p2p port.
2017-09-26 10:41:43 +01:00
Ross Nicoll
da82a0be40 CORDA-499: Dokka cleanup (#1575)
* Make functions in CompositeSignature static
* Make contract IDs constant
* Remove use of "e.g." which Dokka will take as end of the first sentence
* Move example onto function that it actually works with
* Change comment which refers to comment above it, without any linkage, to directly describe the function
* Move implementation notes out of Dokka comment
* Change contract IDs to constants in companion objects
2017-09-26 10:26:44 +01:00
Joel Dudley
afc0bbe7ec Adds ToC and internal links. 2017-09-25 18:55:36 +01:00
Mike Hearn
7cc23f007d Docs: add a note to the api index page about version 1.0 and which modules will have a stable API. 2017-09-25 18:38:52 +02:00
Mike Hearn
3386fadec3 Docs: move coding style from "Release process" section to "Other" 2017-09-25 18:38:52 +02:00
Rick Parker
d9715e970e CORDA-205: Supported core types documentation (#1621)
* Outline what is supported in AMQP serialization

* Object graph cycles

* Review feedback.

* Review feedback.

* Review feedback
2017-09-25 17:30:19 +01:00
Clinton
532bbb5cca Contract constraints (#1518)
* Contract constraints and attachment loading

Fix compiler warnings.

Fixed IdentitySyncFlowTests in confidential-identities.

Fixes.

Fix AttachmentClassLoaderTests.

Added a TODO.

Renamed cordapp service.

Fix compilation error in java code.

Fix RaftNotaryServiceTests

Fix AttachmentLoadingTest

Fix DistributedServiceTests and LargeTransactionTests.

Add cordapp packages to Verifier tests.

Refactor DummyContractBackdoor back out of internal package.

Resolve compiler warnings.

Consolidate excluding `isolated` project at top-level.

Fix contract attachment serialisation for remote verifier.

Fix integration tests for client:rpc.

Contract constraints and attachment loading

Fix compiler warnings.

Fixed IdentitySyncFlowTests in confidential-identities.

Fixes.

Fix AttachmentClassLoaderTests.

Added a TODO.

Renamed cordapp service.

Fix compilation error in java code.

Fix example compilation.

Fix RaftNotaryServiceTests

Fix AttachmentLoadingTest

Fix DistributedServiceTests and LargeTransactionTests.

Add cordapp packages to Verifier tests.

Refactor DummyContractBackdoor back out of internal package.

Resolve compiler warnings.

Consolidate excluding `isolated` project at top-level.

Fix integration tests for client:rpc.

Fixed issues with node driver and differing ZIPs.

Review changes.

Refactor GeneratedAttachment into node-api module.

Merge branch 'clint/hash-constraint' of https://github.com/corda/corda into clint/hash-constraint

Fixed compile error following rebase.

wip - test to check that app code isn't loaded from attachments sent over the wire.

Use Kotlin copyTo() rather than Apache's IOUtils.

Fixes

more fixes.

Removing unconstrained output.

More fixes.

Fixed another test.

Added missing plugin definition in net.corda.core.node.CordaPluginRegistry: net.corda.finance.contracts.isolated.IsolatedPlugin

Re-added missing magic string used in unit test.

Remove unused FlowSession variable.

* Review fixes.

* More review fixes.

* Moved Cordapp implementation to an internal package.

* More JVMOverloads.
2017-09-25 17:05:18 +01:00
szymonsztuka
2a7da1eb47 fix create-iou URL (#1633) 2017-09-25 17:01:14 +01:00
josecoll
7b59f80bb3 Vault Query API parameter rename to aid clarity (#1627)
* Vault Query API `contractType` renamed to `contractStateType` for clarity.

* Vault Query API `contractType` renamed to `contractStateType` for clarity.

* Vault Query Criteria attribute `CONTRACT_TYPE` renamed to `CONTRACT_STATE_TYPE` for clarity.

* All references to `contractType` renamed to `contractStateType` for clarity.
2017-09-25 16:02:32 +01:00
Joel Dudley
39bc25e74d Updates tx API page and makes corresponding cookbook changes. (#1624)
* Updates tx API page and makes corresponding cookbook changes.

* Addresses review comments.

* Addresses review comments.

* Addresses review comments.
2017-09-25 16:01:53 +01:00
Joel Dudley
54ad89e094 Removes hard-coded M12 references. (#1628) 2017-09-25 15:55:19 +01:00
Ross Nicoll
6649c0394b Start cleaning up release notes & changelog for 1.0 (#1613) 2017-09-22 17:37:12 +01:00
Viktor Kolomeyko
f43702fe3d CORDA-611: Improve documentation for Node Explorer (#1615)
Also align the name for run configuration for Node Explorer GUI
2017-09-22 17:36:03 +01:00
Joel Dudley
095d94f2c7 Updates key types page. (#1616)
* Updates key types page.

* Adds ToC.

* Addresses review feedback.
2017-09-22 17:11:22 +01:00
Joel Dudley
477dc42921 Andr3ej tutorial doc (#1593)
Updated documentation: Tutorial
2017-09-22 16:51:32 +01:00
Joel Dudley
ce8ea5cb50 Joel api contracts (#1611)
Updated documentation: API contracts
2017-09-22 16:51:14 +01:00
Shams Asari
21cb1bf6f3 Moved the RPC classes in node-api that are needed in client-rpc. (#1610)
Everything that now remains in node-api isn't needed as public API for app developers so we can mark this module as non-public and subject to change.
2017-09-22 16:03:24 +01:00
Joel Dudley
fc38e4160a Joel states api (#1605)
* Updates the states API page.

* Minor fixes.

* Further fixes.

* Adds ToC

* Addresses review feedback.
2017-09-22 15:14:16 +01:00
Shams Asari
11be5dd417 Cleaned up ContractUpgradeFlow API (#1591) 2017-09-22 10:17:01 +01:00
Shams Asari
a11577840c Moved ServiceInfo and ServiceType into internal package (#1599) 2017-09-22 10:15:03 +01:00
Joel Dudley
29e648d11c Removes references to clauses from the docs. (#1595) 2017-09-21 18:10:10 +01:00
Matthew Nesbit
c108637df6 Remove unused certificate method from IdentityService. (#1582)
Put wellKnownParty in methods that return a Party which is one.

Fixup rebase
2017-09-21 15:31:42 +01:00
Katarzyna Streich
d72d887224 Fix BankOfCorda demo after services removal (#1584)
* Fix BankOfCorda demo after services removal

* Add CashConfigDataFlow permission to BankOfCorda

* Address comments

* Add permission
2017-09-21 14:50:20 +01:00
Ross Nicoll
b0e9183850 CORDA-499: Dokka cleanup for 1.0 (#1579)
* Clean up Dokka comments on CordaRPCOps

* Remove use of "e.g." which Dokka will take as end of the first sentence
* Move example onto function that it actually works with
* Change comment which refers to comment above it, without any linkage, to directly describe the function
* Move implementation notes out of Dokka comment

* Make functions in CompositeSignature static

* Make contract IDs constant

* Correct contract ID in CashTestsJava
2017-09-21 14:46:36 +01:00
Viktor Kolomeyko
7e977c4118 Minor changes to code documentation (#1585) 2017-09-21 14:43:10 +01:00
Andras Slemmer
33421bdd44 CORDA-577: FlowSession porting (#1530)
* Throw exception if a flow is initiated twice for the same Party

* Chunk of porting

* Need ReceiveTransactionFlow

(cherry picked from commit 774383e)

* Notaries compile

* TwoPartyTrade

* SimmFlow & StateRevisionFlow

(cherry picked from commit da602b1)

* TwoPArtyDealFlow regulator send

* installCoreFlow

* IRSTradeFlow
UpdateBusinessDayFlow
RatesFixFlow
NodeInterestRates

(cherry picked from commit 6c8d314)

* Added recordTransaction parameter to ReceiveTransactionFlow

* Some Tests, Flows

* Fixed typo in record tx param

* more things

* Fix CollectSignatures

* FlowFrameworkTests

(cherry picked from commit 2c50bc3)

* Fix TwoPartyTradeFlow

* CustomVaultQuery

(cherry picked from commit 48f88e8)

* FlowsInJavaTest

* WorkflowTransactionBuildTutorial

* PersistentNetworkMapCacheTest

* FlowCookBookJava

(cherry picked from commit 9b48114)

* Fix RatesFixFlow

* Fix TwoPartyDealFlow to get signature of initiating side

* Integration tests

(cherry picked from commit dbcd965)

* CordappSmokeTest

(cherry picked from commit d19cbd6)

* Inlined FinalityFlow

* Updated uses of FinalityFlow

* ContractUpgradeFlowTest passes

* CollectSignaturesFlow refactor

(cherry picked from commit 5e7b1a7)

* Check that we are not the recipient of cash

* Fix Simm demo

* WorkflowTransactionBuildTutorialTest

* Fix CashPaymentFlowTests

* ScheduledFlowTests

* FlowFrameworkTests

* Add cordappPackagesToScan Driver param

* FinalityFlowTests

* Fix LoaderTestFlow

* NodeMonitorModelTest

* BankOfCordaRPCClientTest

* rename to extraCordappPackagesToScan

* Fixed broken merge

* BankOfCordaHttpAPITest

* Fix CollectSignaturesFlow

* Fix annotation on DummyFlow to stop warning

* Fix TraderDemoTest

* Review feedback

* Doc improvements and minor changes

* Address some PR comments

* Looping regulators into the FinalityFlow broadcast rather than sending separately in TwoPartyDealFlow.

* Add Uninitiated FlowState

* Add test for double initiateFlow exception

* Some more s&r victims

* FlowSession utilities (#1562)

* Merge fix

* CollectSignatureFlow can handle several signing keys

* Actually handle several signing keys

* update kdoc

* Correct SignTransactionFlow error message

* Create deprecated flows package

* Add internal deprecated flows

* Reverted FinalityFlow to auto-broadcast all tx participants

* Move the deprecated packages into another PR
2017-09-21 12:12:25 +01:00
Maksymilian Pawlak
767aaadcce Removal of non-used webserver (#1572) 2017-09-21 11:20:42 +01:00
Andrius Dagys
0314e650a4 Clean up API for selecting notaries (#1573)
* Remove getAnyNotary() from network map API.
Change notaryIdentities() signature to return a Party instead of PartyAndCertificate.
Some API doc updates.

* Minor API doc formatting and typo fix

* Update changelog

* Address comments

* Address comments
2017-09-21 10:28:18 +01:00
Katelyn Baker
c93b0284ef CORDA-593 - Strip web front end from the SIMM demo (#1574)
* CORDA-593 - Strip web front end from simm-demo

Also, pre cutting V1 remove the documentation references to SIMM, the
plan being once V1 is cut we can spend a little time thinking about how
we want to prevent the SIMM back end as a useful, teachable, demo

* CORDA-593

Fix the integration tests
2017-09-21 09:05:32 +01:00
Katarzyna Streich
002c6c4687 Remove notaryIdentityKey from ServiceHub (#1541)
* Remove notaryIdentityKey from ServiceHub

It was redundant, as we have notary field on a transaction. Notaries can
use this field to check if the transaction was meant for them and then
use that information while choosing a key to sign a transaction.

* Move notaryIdentityKey to NotaryService

* Address comments

* Fixes after rebase
2017-09-20 17:47:45 +01:00
Joel Dudley
806d1b9b82 Removes repo link in tut to lower maint. overhead. (#1567) 2017-09-20 14:52:33 +01:00
Katarzyna Streich
fd57cf1c0c Remove advertised services from NodeInfo (#1521)
* Remove advertisedServices from NodeInfo.

Introduce notaryIdentities in NetworkMapCache, that will be filled in
later from NetworkParameters. Clean up NetworkMapCache API. Expose
notaryIdentities through RPC. For now we assume as temporary solution
that notaries in NetworkMap have to contain "notary" in name.

* Further clean up of NetworkMapCache API

Remve partyNodes. Introduce getAllNodeInfos function

* Remove notaryIdentity from ServiceHub

* Address Shams review comments

* Address Andrius review comments

* Add comments, cleanup

* Fixes

* Address comments

* Yet another commit with comments addressed

* Move ServiceType and ServiceInfo to node-api

Add changelog entry. Address rest of comments.

* Minor comments
2017-09-20 13:19:57 +01:00
Konstantinos Chalkias
6887947a4d CORDA-521: Backwards compatible Transactions using sub-Merkle trees (#1481)
* tx backwards compatibility + rebase

* SHA256d definition
2017-09-20 13:11:58 +01:00
Shams Asari
838e753164 Moved PhysicalLocationStructures into finance (#1557) 2017-09-19 17:36:26 +01:00
Shams Asari
8e0b8477af Changed FlowLogic.ourIdentity to return Party and added FlowLogic.ourIdentityAndCert which returns PartyAndCertificate. (#1537)
Updated code base to make use of these instead of chooseIdentity(). Also improved the serialisation of fiber checkpoints so that it doesn't store the entire cert parth of this identity.
2017-09-18 15:28:23 +01:00
Shams Asari
4c40c764c3 Cleaned up NodeInfo API (#1535) 2017-09-18 13:09:29 +01:00
Alberto Arri
4336a78495 fix .rst, enumerations must have a blank line at the end (#1526) 2017-09-15 15:07:15 +01:00
Katarzyna Streich
495e870b74 NodeInfo remove main identity (#1284)
* Remove node's main identitiy from NodeInfo.

Preparation for getting rid of services + supporting multiple identities
on the node.
NodeInfo keeps multiple identities as a list. For now the first one is treated as a special one.
Introduced function chooseIdentity in CoreTestUtils as a preparation for proper handling of multiple identities in the future.
Remove legalIdentityKey from ServiceHub, add extension function - chooseIdentity on ServiceHub.
Add `me` field on FlowStateMachineImplemetation, flows should know what the calling identity is.
Remove SERVICES_PREFIX in artemis messaging layer.

* Address minor comments.

* Fixes after rebase.

Remove chooseIdentity from ServiceHub

* Rename me to ourIdentity on FlowLogic

* Fixes after rebase

* Address Ross comments, fixes

* Fix after rebase

* Fix services certificate paths

Apply Patrick's patch.
2017-09-15 14:39:34 +01:00
Joel Dudley
4eacaaf283 Allow use of test utils in flow cookbook. (#1511)
* Allow use of test utils in flow cookbook.

* Shift how testCompile project is set.
2017-09-15 09:02:52 +01:00
Shams Asari
573987d929 Removed X509CertificateHolder from public API, using java.security.X509Certificate instead (#1510) 2017-09-14 15:48:33 +01:00
Katelyn Baker
094187cfa1 Merge pull request #1473 from corda/feature/kat/carpentEnum
CORDA-539 - Add enum support to the carpenter
2017-09-14 12:58:27 +01:00
Shams Asari
8f0c0c784b Removed PluginServiceHub 2017-09-14 09:30:37 +01:00
Clinton
b102900c90 Automatically load contract attachments into the attachment store (#1500)
Attachments for contracts are now loaded into the attachment store by the cordapp provider.
2017-09-13 18:43:37 +01:00
Andrzej Cichocki
cfd6739d23 Introduce StartedNode (#1491) 2017-09-13 17:34:52 +01:00
Shams Asari
ed0aede1f1 In preparation for the removal of advertised services, @CordaService no longer expects a static "type" field for the ServiceType.
Instead @CordaServices will use the main identity of the node.
2017-09-13 15:53:50 +01:00
Michele Sollecito
ea61e6e9d5 [CORDA-461] Remove deprecated APIs. (#1480)
https://r3-cev.atlassian.net/browse/CORDA-461
2017-09-13 15:39:39 +01:00
josecoll
5504493c8d Improved support for testing custom schemas using a MockNetwork. (#1450)
* Improved support for testing custom schemas using a MockNetwork.

* Removed `requiredSchemas` from CordaPluginREgistry configuration
Custom schema registration now uses classpath scanning (CorDapps) and explicit registration (tests) following same mechanisms as flow registration.

* Updated following PR review feedback.

* Helper function to return Kotlin object instance fixed and moved to core InternalUtils class.

* Fixed auto-scanning Unit test to assert correct registration of custom schema.

* cleanup comment.

* Changes following rebase from master.
2017-09-13 12:06:24 +01:00
Andrzej Cichocki
93101f7c7d Restore ContractState and TransactionState to docs. (#1495) 2017-09-13 11:49:05 +01:00
Katelyn Baker
c48a37a080 CORDA-539 - Add enum support to the carpenter
If the serializer is going to support enumerated types then the class
carpenter also has to

Refactor the Carpenter schema and fields to add an enum type, add code
in the carpenter to generate enum's and of course add tests
2017-09-13 09:52:00 +01:00
Michele Sollecito
15aa4036b6 CORDA-599: Fix IRS demo (#1460)
* [CORDA-559]: Fixed incorrectly referenced deal notional amounts in views.

* [CORDA-559]: Fixed missing parties in IRS demo deal view.

* [CORDA-559]: Fixed failing creation of deals in IRS demo.

* [CORDA-559]: Added to changelog.

* [CORDA-559]: Fixed the broken integration test in IRS demo.
2017-09-13 09:42:16 +01:00
Clinton
8415a01a47 Cordform common is now a part of the gradle plugin suite (#1474)
Cordform common is now a full gradle plugin and all related gradle hacks are removed.
2017-09-12 19:18:09 +01:00
Ross Nicoll
de3468f8a7 Replace X500Name with CordaX500Name (#1447)
Replace X500Name with CordaX500Name, which enforces the specific constraints Corda expects on legal/service identity names.
2017-09-12 01:03:10 +01:00
Clinton
bc6628a072 ContractState now references contract by class name (#1407)
* ContractState's contract type has been moved to TransactionState and is now a string representing the class name of the contract class to allow classloading of arbitrary contracts from custom classloaders.

* Upgraded isolated JAR to new version.
2017-09-11 16:44:18 +01:00
Michele Sollecito
df31e52665 [CORDA-303]: Add some tests that stop and start a node and check state is persistent. (#1449)
* [CORDA-303]: Add some tests that stop and start a node and check state is persistent.

* [CORDA-303]: Updated change log and added Javadocs.

* [CORDA-303]: Cleaned up test.

* [CORDA-303]: Removed blank lines after class or function declarations.

* [CORDA-303]: Wrapped multiple invocations in `with` construct.
2017-09-08 09:24:22 +01:00
Andrzej Cichocki
879b1a6393 Tutorial runExampleClientRPC is now runExampleClientRPCKotlin. (#1446) 2017-09-07 15:00:03 +01:00
Patrick Kuo
57412d4498 Enforce X500Name format defined in design doc (#1427)
* Standardise X500Name format - WIP

* address PR issues

* failing test fix and replace X500Name with getX500Name

* gradle plugin fix

* Added country code validation
2017-09-07 14:47:42 +01:00
Viktor Kolomeyko
50c51493c3 CORDA-540: AMQP-forge "example-code" (#1439) 2017-09-07 11:17:55 +01:00
Ross Nicoll
8d261faac0 Correct outInputState -> ourInputState (#1435) 2017-09-06 17:50:21 +01:00
Andrzej Cichocki
579abda044 Group test scope modules in testing dir (#1419) 2017-09-05 18:27:26 +01:00
Clinton Alexander
3ccddf91ea Addressed release comments. 2017-09-05 17:38:53 +01:00
Clinton Alexander
ccf231440f Added a page to explain testing. 2017-09-05 17:21:07 +01:00
josecoll
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
Maksymilian Pawlak
377ca95387 Fix steps references. Small text fixes. 2017-09-05 13:11:58 +01:00
joeldudleyr3
17f7e39183 Makes set-up instructions clearer. Addresses a zsh-related bug. 2017-09-05 12:33:52 +02:00
Varun Mathur
81d83d707f fix typo in notary docs 2017-09-05 12:32:28 +02:00
Ross Nicoll
8076983e2e Add missing finance CorDapp depdendency to example code (#1413)
The example code uses cash flows and contracts, but doesn't depend on the finance CorDapp. This happens to work at the moment but should be corrected anyway.
2017-09-05 10:22:34 +01:00
mkit
cbf89ba98b Deprecating verifiedTransactions from the public API (#1418) 2017-09-05 10:07:55 +01:00
Andrzej Cichocki
15f741f315 Spinoff driver into own project with demorun (#1401) 2017-09-05 09:50:51 +01:00
Joel Dudley
b990fedd80 Adds a builder for configuring nodes in the driver for Java interop. 2017-09-04 15:51:46 +01:00
Søren Sjørup
314a88e13a Update using-a-notary.rst 2017-09-04 11:52:20 +02:00
Konstantinos Chalkias
39e44382be Helper SignedTransaction.buildFilteredTransaction(filtering) (#1394) 2017-09-01 19:26:00 +01:00
joeldudleyr3
83d0095142 Adds a builder for configuring nodes in the driver for Java interop. 2017-09-01 16:45:00 +01:00
joeldudleyr3
76b46e4e4e Addresses review feedback. 2017-09-01 14:50:29 +01:00
joeldudleyr3
d1ee84044d Renames AuthenticatedObject to CommandWithParties for clarity. 2017-09-01 14:10:35 +01:00
Konstantinos Chalkias
62c64ace23 Adding createSignature(filteredTransaction) to serviceHub (#1380) 2017-09-01 10:45:01 +01:00
Konstantinos Chalkias
8d29c78073 changelog additions, mainly for crypto and finance related tasks 2017-08-31 16:56:24 +01:00
szymonsztuka
bbebea234d remove reference to repository with JetBrains/Exposed library 2017-08-31 13:42:08 +01:00
Rick Parker
35dec9abdc Make addToWhitelist vararg for compactness. (#1361) 2017-08-31 13:24:45 +01:00
Katarzyna Streich
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
Joel Dudley
3e5fa9ee6a Update api-flows.rst. 2017-08-31 10:09:31 +01:00
Patrick Kuo
9bd4342039 Removed is relevant from LinearState (#1294) 2017-08-30 16:26:34 +01:00
Joel Dudley
e50052aeb1 Update getting-set-up.rst. 2017-08-30 13:20:11 +01:00
Joel Dudley
d2a2e2c419 Update tut-two-party-introduction.rst. 2017-08-30 11:18:28 +01:00
josecoll
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
mkit
a84cd567d8 Removing Kt suffixed Java class (#1344) 2017-08-29 13:41:17 +01:00
Joel Dudley
701c4f3c60 Updates the transaction API page and cookbook. 2017-08-25 17:15:39 +01:00
josecoll
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
Clinton Alexander
ac26b7d1c6 Fixed issues detecting tests caused by changes to directory structures in gradle. 2017-08-24 16:46:54 +01:00
josecoll
458d2e32c0 Pluggable cash selection using H2 as default implementation. (#1300)
* Pluggable cash selection using H2 as default implementation.

* Refactor to use own CashSelection service loader and associated isCompatible() check.

* Determine Cash Selection algorithm to use based on JDBC Driver loaded.
Lazily load JDBC Driver metadata and class implementation.

* Rebased and adjusted package naming to include `finance`

* Rebased and adjusted package naming to include `finance`

* Added some documentation.
Minor fixes and changes following PR review.

* Return cashSelectionAlgo.
Throw exception rather than setting in atomically referenced object.
2017-08-22 18:09:23 +01:00
mkit
dce17ed272 Fixing trader demo docs. After recent refactoring they've become out of sync. (#1298) 2017-08-22 17:42:07 +01:00
Matthew Nesbit
c86e78599f Rename finance module to own package
Fixup after rebase

Correct bad merges

Fixup docs

Fix integration test

Correct doc references to finance
2017-08-22 13:25:31 +01:00
Konstantinos Chalkias
1a4d908b63 Remove grouping from FungibleAsset (Issue and Move) (#1185)
Clean-up FungibleAsset - remove Command grouping and get rid of IssueCommand as no nonce is required anymore.
2017-08-21 16:14:04 +01:00
josecoll
a2ede0fc73 Requery removal (#1276)
* Removed Requery object relational mapping usage (and associated schemas including node-schemas module)

* Fixed issues with NodeAttachmentService tests.
Cannot use JPA custom converters with Primary Key fields.
Hibernate entities require explicit call to flush() to persist to disk.

* Removed redundant requery converters (equivalents not even required in Hibernate).

* Removed remaining gradle requery dependency definitions.

* Fixed broken tests.

* Fixes for failing NodeVaultService tests:
- Dynamic SQL updates (in soft locking code)
- Explicit request by session to participate in transaction (causing "TransactionRequiredException" Executing an update/delete query)
- Explicit flush() required to persist to disk

* Updated changelog.
Fixed compiler warning.

* Fixed WHERE clause AND/OR condition.
Enforced immediate data visibility through transaction commit.

* Final fixes to address failing tests.

* Deferred all hibernate session/txn management to DatabaseTransactionManager.

* Fixed transaction boundaries in failing Cash tests.

* Fixes to address failing tests (transaction boundaries, merge detached object, config clean-up).

* Final adjustment to transaction boundaries in JUnit tests.

* Refactored AttachmentSchemaV1 into NodeAttachmentService itself and referenced from NodeServicesV1.

* Refactored HSQL UPDATE statements to use CriteriaUpdate API.

* Updated all criteria API getters to reference attribute names by type.

* Remove redundant VaultSchema entity name (required when previously using HSQL UPDATE syntax)

* Fix compiler warnings.

* Minor changes following rebase from master.

* Fixed suppress warning type.
2017-08-21 10:42:59 +01:00
Matthew Nesbit
8ec33d67e4 Remove finance dependencies
Re-enable code now DealState PR is in.

Add plugable JSON serialisation

Add docs for new plugin api.

Move parseCurrency back to core to prevent dependency issues with crash shell parsing.

Use :finance module as a proper CorDapp

Move parseCurrency back onto Amount companion.

Fix smoke tests

Fixup after merge.
2017-08-18 14:27:49 +01:00
Andrzej Cichocki
2829faa01f Retire legalContractReference (#1188)
* Add LegalProseReference annotation
* Migrate code from autogenerated javascript to TypeScript source
* Add instructions to rebuild the web resources
* Make installWeb more reproducible
2017-08-18 13:30:39 +01:00
Mike Hearn
d22cdac2dd Move some extension methods for summing to new locations.
This improves the Java API and makes it more idiomatic. The methods
were not moved to be static methods of the relevant types in all cases
due to a bad interaction with a Kotlin auto-completion bug, and because
static methods on interfaces are new in Java 8 and Kotlin is not yet
emitting Java 8 bytecode.

Also, introduce a packages.md file so packages can be documented.
2017-08-18 12:39:12 +02:00
Joel Dudley
734b48bad1 Fixes indentation of note box. 2017-08-17 17:26:10 +01:00
Joel Dudley
4eb58b874a Additional fixes to the tutorial. 2017-08-17 12:02:44 +01:00
josecoll
48e8aa55fa Vault identity cleanup (#1194)
* Removed notary_key (and all references) from vault schema.
Fixed incorrect NOTARY usage in certain tests (cash consumption)

* Fixed broken test.

* Replace CommonSchemaV1.Party in all VaultSchema tables (and associated queries) with string'ified X500Name's only.

* Fix broken tests.

* Completely remove CommonSchemaV1.Party and all references (in favour of X500Name's)

* Updated all schema attribute identity references to use AbstractParty.

* Updated all schema attribute identity references to use AbstractParty.

* Standarised attribute naming for parties (removed 'Name')

* Updated deprecate identity API references following rebase.

* Configurable IdentityService as a lambda in JUnit tests.

* Additional WARNING logging to enable troubleshooting of identity lookup failures.

* Final identity updates to sample schemas.
Cleaned up several compiler warnings.
2017-08-17 09:30:27 +01:00
Joel Dudley
435dcf6af4 Fixes the hello, world tutorial. 2017-08-16 08:36:00 +01:00
Ross Nicoll
b76d036843 Change CashIssueFlow to always issue to ourselves
Change CashIssueFlow to always issue to ourselves, and require the cash is then moved in a separate payment
operation. This more closely models actual operation inside banks, and is a step towards making all move-like
operations go through a uniform verification process.
2017-08-15 22:32:30 +01:00
Ross Nicoll
89476904fc Remove IssuerFlow
* Remove IssuerFlow as it is dangerous and its presence in the finance module risks accidental use in non-test code. As written it will issue arbitary amounts of currency on request from any node on the network, with no validation barring that the currency type is valid.
* Unify interface to CashIssueFlow to match the previous IssuerFlow
2017-08-15 22:32:30 +01:00
Shams Asari
62b26bcd89 Moved Currency stuff in ContractsDSL out of core and into finance 2017-08-15 18:08:02 +01:00
Joel Dudley
ccdab6af4d For convenience, creates RPC snapshot methods for feeds. 2017-08-15 16:18:15 +01:00
Clinton
9149900938 Fixed a warning caused by an incorrect configuration. (#1227) 2017-08-15 12:29:04 +01:00
Joel Dudley
4c351ca803 Updates cheatsheet to reflect API changes up to M14. 2017-08-15 11:35:11 +01:00
al-r3
6ee40a4436 added map it.data 2017-08-15 11:20:54 +01:00
Matthew Nesbit
e546b554fc Remove DealState dependency inside Vault. Use the linearId.externalId for all ref data uses.
Rename as per PR comments

Correct a comment
2017-08-15 09:25:44 +01:00
Ross Nicoll
8f8a5ff774 Remove deprecated code
*Remove dummy public keys in preference for EdDSA keys generated from fixed entropy sources, as a more accurate reflection of real uses. Also eliminates a serialization format issue with dummy keys which would have to be resolved otherwise.
* Remove deprecated 'by' keyword from contracts DSL
* Remove deprecated parts of CordaPluginRegistry
2017-08-15 01:17:36 +01:00
Ross Nicoll
62576b12b3 Simplify identity registration API
* Merge identity registration of well known and confidential identities
* Move verification logic into PartyAndCertificate from IdentityService
* Add note about why PartyAndCertificate exists
2017-08-15 00:17:21 +01:00
Joel Dudley
532deffca0 Update to include M14. 2017-08-14 23:11:51 +01:00
Joel Dudley
55a4264652 Error in folder name 2017-08-14 13:31:15 +01:00
Alberto Arri
486bd68713 Merge branch 'master' into arri_fix_tutorial_contract 2017-08-14 09:14:02 +01:00
Shams Asari
008301c4e8 Introduced FlowLogic.getFlowContext which provides the flow version and app name of the other side. 2017-08-11 18:01:16 +01:00
Ross Nicoll
f0c7d7665a Remove deprecated signing functions
* Remove TransactionBuilder.signWith()
* Remove TransactionBuilder.addSignatureUnchecked()
* Rename signInitialTransaction to toSignedTransaction
* Remove checkAndAddSignature()
* Require all unit tests sign transactions via services
2017-08-11 17:37:50 +01:00
Alberto Arri
f4ddf6eada Fixed another wrong signature for withNewOwner 2017-08-11 14:30:48 +01:00
Alberto Arri
86784d36b7 Changed type from PublicKey -> AbstractParty to match fun declaration 2017-08-11 14:22:39 +01:00
Ross Nicoll
f9552a0d3e Correct exceptions thrown from checkSignaturesAreValid()
checkSignaturesAreValid() calls TransactionSignature.verify(), which throws InvalidKeyException but
checkSignaturesAreValid() did not indicate it could throw InvalidKeyException.
2017-08-11 13:40:39 +01:00
Alberto Arri
14afb04fa0 revert old committed change 2017-08-11 10:28:52 +01:00
Ross Nicoll
4602739e93 Issue commercial paper from the Bank of Corda node (#1196)
* Remove hard coded commercial paper issuer from trader demo
* Issue commercial paper from the Bank of Corda node, as per previous hard-coded issuer name
* Issue cash from the Bank of Corda node rather than in response to the buyer node requesting issuance
2017-08-11 10:20:27 +01:00
Ross Nicoll
0977ffca54 Sync changelog and release notes from M14 (#1213) 2017-08-10 17:39:14 +01:00
josecoll
54cf46952c JPA Hibernate AbstractParty converter (#1205)
* Added JPA AbstractParty converter (using IdentityService to resolve anonymous parties).

* Use partyFromX500Name. Add meaningful exception messages.

* AutoApply the JPA AbstractParty converter.

* Entity attribute still needs the Convert annotation.

* Fix incorrect registration of custom attribute converter.

* Deal with non-resolvable anonymous parties (eg. store as null and ignore)

* Updates following PR review feedback.

* Added documentation.

* Added entry to changelog.

* Added code documentation as per RN PR feedback request.

* Updates required following rebase from master.

* Renamed converter for clarity.
2017-08-10 17:17:12 +01:00
Alberto Arri
2c4dd87d41 Minor: made the code in IOUState match the description of the changes underneath. 2017-08-10 16:54:19 +01:00
Alberto Arri
1856b5905e Minor: made the code in IOUState match the description of the changes underneath. 2017-08-10 15:02:09 +01:00
Matthew Nesbit
f4f2d35375 Make a generic generate spend. Tests pass.
Fixup after rebase

Fixup after rebase

Make node have only test compile dependency against finance module.

Use original query code.

Fixup after rebase

Update docs

Edit docs

Add to changelog

Follow recommendations from PR

Follow recommendations from PR

Make a re-usable helper function to create MockServices with database for tests

Tweak a few comments

Don't include tryLockFungibleStateForSpending in soft lock docs.

Respond to PR comments

Fix whitespace error

Fix compile error

Fixup after rebase
2017-08-10 13:29:08 +01:00
josecoll
7cdcc48173 Specify correct use of Hibernate SQL statement debug output (and set in our log4j2-test.xml). (#1181) 2017-08-09 15:59:46 +01:00
Konstantinos Chalkias
bd0944e799 TransactionSignature MetaData support (#1040)
Support signature metadata
2017-08-07 16:21:52 +01:00
Andrzej Cichocki
3a3ead2dfe Remove ListenableFuture from core/main (#1030) 2017-08-07 14:31:24 +01:00
Joel Dudley
a4fb32ceab Update versions. 2017-08-04 18:06:32 +01:00
josecoll
bef8630fe0 Improvements to Vault Query Service soft locked state querying (#1174)
* Improvements to Vault Query Service soft locked state querying (removed old mechanism from VaultService).

* Fixed rst document formatting.

* Added additional soft locking criteria mode: all unlocked plus those locked as specified by lockId(s).

* Addressed comments from PR feedback.
2017-08-04 17:23:31 +01:00
josecoll
67361188e5 Vault Query fix: query by multiple issuer party names. (#1170)
* Fixed query by multiple issuer party names.

* Changes following feedback from PR review.
Added changelog entry.
2017-08-04 16:22:21 +01:00
Patrick Kuo
56fda1e5b5 Replace data vending service with SendTransactionFlow (#964)
* WIP - Removed data Vending services, fixed all flow test

* * separated out extra data, extra data are sent after the SendTransactionFlow if required
* New SendProposalFlow for sending TradeProposal, which contains StateAndRef.
* WIP

* * removed TradeProposal interface.
* changed SendProposalFlow to SendStateAndRefFlow, same for receive side.
* fixup after rebase.

* * undo changes in .idea folder

* * remove unintended changes

* * Addressed PR issues

* * doc changes

* * addressed pr issues
* moved ResolveTransactionsFlow to internal
* changed FlowLogic<Unit> to FlowLogic<Void?> for java use case

* * addressed PR issues
* renamed DataVendingFlow in TestUtill to TestDataVendingFlow to avoid name confusion, and moved it to core/test

* * removed reference to ResolveTransactionsFlow
2017-08-04 11:26:31 +01:00
josecoll
014387162d Expose a JDBC connection (session) via the ServiceHub for generic JDB… (#1000)
* Expose a JDBC connection (session) via the ServiceHub for generic JDBC usage.

* Updated documentation.

* Fix failing JUnit following rebase from master.

* JDBC session Tutorial WIP

* Fix broken JUnits following update to consumeCash() using observable event update as return.

* Fixed broken JUnits.

* Refactoring createSession() into new CordaPersistence class following rebase from master.

* Updated fully working example.

* Minor updates following feedback from MH.

* Fixed compiler error following rebase.

* Fixes following rebase from master.

* Further updates and clarifications to documentation.
2017-08-04 09:26:27 +01:00
josecoll
818cbce789 Removed all deprecated Vault Service query code. (#1167) 2017-08-03 17:45:53 +01:00
Clinton
2060a81636 Merge pull request #1155 from RangerOfFire/fix/docs_api_link
Docs: Stop the API pages being orphaned without a menu
2017-08-03 14:40:10 +01:00
josecoll
64ba8d3a88 Updated samples and demos to use new Vault Query service. (#924)
* Updated all sample code to use new Vault Query service APIs.

* Fix broken Unit test.

* Added missing transaction boundary.

* Fix broken ScheduledFlow test (caused by assertion on non-ordered collection)

* Remove redundant negative test (as new Vault Query no longer returns iterators).

* Whitespace formatting fixed following PR review from SA.

* Force query to specify a PAGE SIZE equivalent to total states to be exited (RP review comment).

* Use single (and fail fast) instead of first - when only expecting a single result.

* Demonstrate paging and sorting; failfast on single expected result.

* Enhancement: added Sorting by CommonStateAttribute (StateRef txnId and index)

* Fix: incorrect total states count.

* Fixed incorrect total states counting.

* Remove redundant filter (UNCONSUMED).

* Updated tutorial code and associated documentation (building transactions).

* Updated all vaultAndUpdates to vault[Track|Query]By.

* Temporary disable failing Vault Query tests (awaiting pagination PR fix).

* Rebase from master to pick up pagination changes/fix.

* Fixed criteria filter on track.

* Cleanup redundant print output.

* Refactor to extract common function for Vault Query paging and sorting.

* Identified problem in SimmValuation demo failing test caused by query by single participant in participants list (not yet supported in VaultQuery criteria).

* Minor fixes following rebase from master.

* Minor updates following rebase.

* Removed redundant import.

* Fixed type casting error.

* Minor fixes following rebase from master.

* VQ Fix - applied in other PR.

* Removed duplication after rebase and minor fix to failing smoke test.
2017-08-03 11:47:15 +01:00
Shams Asari
4312dc0771 Resolved all non-deprecation warnings 2017-08-02 12:17:52 +01:00
Michael Hinstridge
095e1ca6fe [fix] stop the API pages being orphaned away from the menu 2017-08-02 10:37:40 +01:00
Shams Asari
4a600121cc Removed deprecated methods in DataFeed and deprecated feed-based methods in CordaRPCOps 2017-07-31 15:11:00 +01:00
Andrius Dagys
4ca8b8d681 Remove type-specific transaction builder. Normal transactions should use TransactionBuilder and notary change transactions are created directly. 2017-07-31 14:31:17 +01:00
Andrius Dagys
59edd6f9ae Remove type property from transactions 2017-07-31 14:31:17 +01:00
Joel Dudley
3485827a90 Updates template links to indicate both versions. 2017-07-28 09:13:53 +01:00
Clinton
9eceb26ee9 Renamed corda configuration in gradle to cordaCompile to be more explicit. (#1131)
* Renamed corda configuration in gradle to cordaCompile to be more explicit.

* Bumped version number of gradle plugins.
2017-07-27 17:53:51 +01:00
Andrius Dagys
4487408526 Refactor notary change mechanism (#1019)
* Introduce new NotaryChangeWireTransaction (similar to WireTransaction and NotaryChangeTransaction (similar to LedgerTransaction) types.

Remove 'mustSign' and 'signers' fields from transactions

Deprecate the TransactionType concept. When receiving a SignedTransaction, the verification and signature checking branches out for regular and notary change transactions.

Add custom handling logic for notary change transactions to the vault
2017-07-27 08:32:33 +01:00
Mike Hearn
a9a50ce8f3 Add generics to Vault.Update 2017-07-26 18:30:59 +02:00
Matthew Nesbit
b4ca0cdde9 Remove getCashBalances first part
More removal of getCashBalances

Get rid of duplicated code

Move onto new getCashBalance extension methods

Move onto new getCashBalance extension methods

Correct balance query code

Address PR request comments

Address PR request comments

Address PR request comments
2017-07-26 15:00:03 +01:00
Clinton
68d05eee04 Added corda and cordaRuntime configurations and documentation on integrating with Corda (#1103)
* Added new corda and cordaRuntime configurations for cordapps to be able to explicitly depend on Corda and exclude corda dependencies from the fatjar

* Added corda integration section to docsite to describe how to integrate with Corda.

* Updated more of the documentation to reflect the new method of specifying core corda dependencies.

* Reorganised document logic to move all build system related documentation to the cordapp build systems page.

* Renamed cordapp build systems doc to match actual purpose.

* Improved the warning for building against a net.corda dependency in a cordapp

* Added a line of dialogue to show further reading for those reading about writing cordapps.
2017-07-25 17:54:36 +01:00
Shams Asari
b080d4da3f Removed out-of-date warnings regarding the switchover to X.500 names 2017-07-25 13:16:10 +01:00
Joel Dudley
46fcbf369a Adds a missing bracket. (#1107)
Fixes docsite issues.
2017-07-25 11:31:24 +01:00
Joel Dudley
5eb8b36809 Adds information on writing CorDapps. Reorg. 2017-07-25 09:26:35 +01:00
Shams Asari
407b467f67 Moved the majority of the contents of Utils.kt into either InternalUtils.kt or KotlinUtils.kt.
What remains is being dealt with in another PR.
2017-07-24 19:25:56 +01:00
Joel Dudley
8acbd86c70 Uses dynamic loading of dropdown versions. Styles box slightly. 2017-07-24 18:25:05 +01:00
Shams Asari
800f710fbb Generified Command so that it's more easier to use when querying from LedgerTransaction 2017-07-24 15:33:41 +01:00
Matthew Nesbit
9a02a27619 Add state query methods to LedgerTransaction.
Update to use LedgerTransaction api

Push query output logic onto BaseTransaction and update usages where possible

Migrate a few more uses

Address some PR comments

Address some PR comments

Fixup after rebase
2017-07-21 15:41:00 +01:00
Rick Parker
fe9db6f1f7 Remove links to Kryo from serialization "clients" (#1079) 2017-07-21 14:23:05 +01:00
Joel Dudley
bb4501c09c Updates the example CorDapp page. 2017-07-21 12:33:31 +01:00
Shams Asari
e702025f62 Cleaned up TimeWindow and added a bit more docs. 2017-07-20 13:43:11 +01:00
Matthew Nesbit
0fdd4ae6c6 Remove TransactionForContract and just use LedgerTransaction
Fix minor doc error

Get rid of @deprecated method that was only present for technical reasons.

Minor fix and include in changelog
2017-07-20 09:16:07 +01:00
Andrius Dagys
5501d74d29 Remove NotaryChangeTxBuilder from examples - it's being deprecated 2017-07-18 17:38:18 +01:00
Shams Asari
561a329064 Moved the various extension methods for creating Durations from Utils.kt to KotlinUtils.kt 2017-07-18 10:26:53 +01:00
Joel Dudley
b37c73827f Splits verifySigs into verifySigsExcept and verifyRequiredSigs to clarify usage. 2017-07-17 15:42:08 +01:00
Matthew Nesbit
7d1d5cc0f8 Merge pull request #1050 from corda/mnesbit-services-in-separate-files
Put Services.kt in separate files
2017-07-17 14:29:01 +01:00
Joel Dudley
5df0de8ff7 Adds a tutorial showing multi-party communication. 2017-07-17 12:23:14 +01:00
Ross Nicoll
b7ee7d42a5 Enable anonymisation in integration testing tutorial
Enable anonymisation in integration testing tutorial, and as a requirement fix a bug where the counterparty anonymous
identity was not registered by `TransactionKeyFlow`.
2017-07-17 10:24:20 +01:00
Matthew Nesbit
7a06d941c4 Put Services.kt in clear files, so that at a glance people can see what public services there are.
Fix include

Correct doc links after code movement
2017-07-17 09:34:07 +01:00
Andrius Dagys
7aafcf8c57 Prevent exception causes showing up as null in logs (#1018)
* Passing exception messages via constructor instead of overriding toString
2017-07-14 20:40:21 +01:00
Mike Hearn
2fb187ec75 Docs: Add a note to the troubleshooting page about the -javaagent flag. 2017-07-14 18:21:33 +01:00
Ross Nicoll
42f217f212 Add extension hooks to FinalityFlow
Add extension hooks to FinalityFlow to support different behaviours depending on whether the node knows who all of the parties in a transaction are.
2017-07-14 16:54:39 +01:00
szymonsztuka
05327f3826 decouple Exposed (#1028)
Exposed library decoupled from transaction management and JDBC connection creation for Hibernate and ReQuery
2017-07-14 14:39:59 +01:00
Shams Asari
e93cdf29f8 Moved the core flows into net.corda.core.flows 2017-07-13 13:27:11 +01:00
Konstantinos Chalkias
ce06ad3878 Remove DigitalSignature.LegallyIdentifiable
Remove DigitialSignature.LegallyIdentifiable
2017-07-13 11:24:33 +01:00
josecoll
5f7b8f6ec3 Vault Query Pagination simplification (#997)
* Pagination improvements (fail-fast on too many results without pagination specification)
* Fix incorrectly returned results count.
* Performance optimisation: only return totalStatesAvailable count on Pagination specification.
* Changed DEFAULT_PAGE_NUMBER to 1 (eg. page numbering starts from 1)
* Changed MAX_PAGE_SIZE to Int.MAX_VALUE
* Fixed compiler WARNINGs in Unit tests.
* Fixed minimum page size check (1).
* Updated API-RST docs with behavioural notes.
* Updated documentation (RST and API);
2017-07-12 09:53:15 +01:00
josecoll
c81ef7eb93 Vault Query Sort by StateRef (or constituents: txId, index) (#990)
* Provide sorting by state reference (and individual constituents of: txId, index)

* Fixed formatting.

* Updated import following rebase from master.

* Updated import following rebase from master.
2017-07-10 12:49:00 +01:00
Shams Asari
fb0a043485 Moved dummy contracts to test-utils 2017-07-07 15:16:29 +01:00
Andrzej Cichocki
cefa14507a Retire HostAndPort (#962)
* Don't attempt to parse a resolved InetSocketAddress toString
* A mock node isn't reachable via an address
2017-07-07 15:11:07 +01:00
Shams Asari
7822118835 Moved random63BitValue() to CryptoUtils 2017-07-07 12:19:55 +01:00
Joel Dudley
499f1920c7 Simplifies the Hello, World tutorial. 2017-07-07 12:06:28 +01:00
Joel Dudley
67ccf69dbb Joel integrate cookbook into TX API 2017-07-07 12:06:10 +01:00
Shams Asari
8f1529b863 Moved ByteArrays.kt to core.utilities 2017-07-06 17:58:18 +01:00
Joel Dudley
2ba34de460 Fix broken commands. 2017-07-06 14:23:52 +01:00
Joel Dudley
3063debd98 Moves to builder syntax for TxBuilder. Adds attachments and time-windows to withItems. 2017-07-06 14:23:43 +01:00
Shams Asari
c6e165947b Added background checkpoint checker to make sure they're at least deserialisable 2017-07-06 13:11:46 +01:00
Joel Dudley
177f591e57 Uses brute-force approach to add a dropdown. 2017-07-06 12:25:54 +01:00
Shams Asari
182c9cceb5 Cleaned up the QueryCriteria API to be more Java friendly 2017-07-06 11:08:54 +01:00
josecoll
44f57639d2 Vault Query Aggregate Function support (#950)
* Partial (ie. incomplete) implementation of Aggregate Functions.

* Completed implementation of Aggregate Functions (sum, count, max, min, avg) with optional grouping.

* Completed Java DSL and associated JUnit tests.

* Added optional sorting by aggregate function.

* Added Jvm filename annotation on QueryCriteriaUtils.

* Added documentation (API and RST with code samples).

* Incorporating feedback from MH - improved readability in structuring Java and/or queries.

* Remove redundant import.

* Removed redundant commas.

* Streamlined expression parsing (in doing so, remove the ugly try-catch raised by RP in PR review comments.)

* Added JvmStatic and JvmOverloads to Java DSL; removed duplicate Kotlin DSL functions using default params; changed varargs to lists due to ambiguity

* Fix missing imports after rebase from master.

* Fix errors following rebase from master.

* Updates on expression handling following feedback from RP.
2017-07-06 10:57:59 +01:00
Andrius Dagys
9e563f9b98 Add a doc on writing a custom notary 2017-07-05 13:09:22 +01:00
Shams Asari
2973755bc8 Moved TestConstants.kt from core into test-utils 2017-07-05 11:54:43 +01:00
Joel Dudley
65f385953f Changes the name of the addTimeWindow method to setTimeWindow. 2017-07-05 10:57:18 +01:00
Matthew Nesbit
7eaac8a306 Merge pull request #968 from corda/mnesbit-tidy-test-classes
Move test classes out of api namespaces
2017-07-05 10:20:03 +01:00
josecoll
f732d2cefe FIX Vault Query defaults to UNCONSUMED in all QueryCriteria types (#958)
* Fix https://github.com/corda/corda/issues/949 by providing a default StateStatus argument to all QueryCriteria types.

* Abstracted Common Criteria into its own abstract data class + associated visitor.

* Incorporating feedback from RP PR review.
2017-07-05 10:01:35 +01:00
Matthew Nesbit
3ef5c39633 Put test classes into clear namespaces, so that they don't pollute the API. 2017-07-05 09:14:22 +01:00
Clinton Alexander
8e9591f3ab Deleted publishing documentation because it is out of date and being rewritten on the Wiki. 2017-07-03 18:12:56 +01:00
Clinton
562b186a65 Fix IntegrationTestingTutorial network map race condition (#947)
* Ignoring and adding a TODO to a test that fails spuriously during CI.

* Ensure both parties are regsitered with network map in the integration test tutorial and update docs to reflect this best practice.

* Minor readability fix.
2017-06-30 16:29:57 +01:00
Clinton
c1088038b7 Cordapps now contain their own dependencies (#915)
* Cordapps now contain all explicitly specified dependencies (and sub
dependencies).

* Removed some useless compile dependencies for trader demo.

* Dependent Cordapps are excluded from the build.
:Removed unnecessary dependencies of demos.

* Cleaned up exclusion rules for cordapp dependencies.
2017-06-30 14:18:46 +01:00
Shams Asari
a08f701dc5 Removed the StorageService and puts its components directly into the service hub 2017-06-30 09:37:29 +01:00
josecoll
556444f9e1 Cleaned up incorrect references to vault query and persistence. (#933)
* Cleaned up incorrect references to vault query and persistence.

* Consistent use of :doc: reference.
2017-06-28 16:00:39 +01:00
Konstantinos Chalkias
bd08d6c6f8 change to 0.14-SNAPSHOT (#928) 2017-06-28 15:55:43 +01:00
Ross Nicoll
1a4965c294 Change CashIssueFlow to use anonymous identity
* Add functions for:
    * Retrieving nodes via their legal identity
    * Filtering a set of public keys down to those the node has corresponding private keys for
* Modify contract upgrade flows to handle identifying participants after an anomymisation step
* Correct terminology: "party who" -> "party which"
* Modify CashIssueFlow and CashPaymentFlow to optionally use an anonymous identity for the recipient.
2017-06-28 13:47:50 +01:00
Patrick Kuo
83fdf678ab Update doc to show JMX no longer works in Corda, due to the serialisation changes (#922)
* Update doc to show JMX no longer works in Corda, due to the serialisation changes.

* minor changes

* address PR issues
2017-06-28 11:29:34 +01:00
Katarzyna Streich
58da76c052 Network map redesign: Change field types in NodeInfo, move away messaging data from NodeInfo (#921)
* First stage of changing fields in NodeInfo.

Part of work related to NetworkMapService upgrade. Create slots for
multiple IP addresses and legalIdentities per node.

* NodeInfo stores HostAndPort.

Move information specific to messaging layer away from NodeInfo.
Only HostAndPort addresses are stored. Add peer name - peer handle
mapping to MockNetwork to reflect that change.
2017-06-27 18:14:51 +01:00
josecoll
3e124b0b48 Automatically persist Linear and/or FungibleState attributes for quer… (#920)
* Automatically persist Linear and/or FungibleState attributes for querying (even when Contract does not implement QueryableState).

* Return single() state.
2017-06-26 18:01:07 +01:00
Clinton
cd694b898f Merge pull request #908 from corda/joel-cookbook
Flow cookbook added and merged into flow API page.
2017-06-23 17:23:26 +01:00
josecoll
1866f6ff7f Align CordaRPCOps Vault Query API's for Java/Kotlin with VaultQuery service equivalents. (#914)
Added Kotlin extension functions for ease of use in simplest case.
Added missing Java contractType class (previously was forced cast of ContractState::class)

Fixed generic typing.

Addressed items raised in SA PR review.

Removed 2 blank lines.

Fixed generics typing.

Updates RST doc and grouped API helpers accordingly.
2017-06-23 14:35:55 +01:00
Konstantinos Chalkias
61a24897fe deriveKeyPair renaming 2017-06-23 13:48:21 +01:00
Konstantinos Chalkias
3cabdf4430 Delete not used steps in IRS demo M13 rst (#912) 2017-06-23 13:35:50 +01:00
Joel Dudley
849d5921d3 Updates the cookbook to reflect vault API changes. 2017-06-23 13:31:04 +01:00
Andrius Dagys
7804c68401 Add a config option to toggle auto IP discovery 2017-06-23 13:14:37 +01:00
Konstantinos Chalkias
bf9e2c6f54 M13 changelog (#896) 2017-06-23 13:12:56 +01:00
Konstantinos Chalkias
47eee88f37 Release notes for M13 (#910) 2017-06-23 12:40:06 +01:00
Joel Dudley
e62a54b74d Flow cookbook added and merged into flow API page. 2017-06-22 16:13:54 +01:00
Joel Dudley
575acd2983 Moves vault API information into the API section. 2017-06-22 15:57:40 +01:00
josecoll
f8ad5c9d10 Vault Query Service JPA implementation (#840)
* Vault Query Service API implementation using JPA Hibernate

Added queryBy(QueryCriteria) Vault API and Junit tests.

Minor cosmetic API changes following rebase.

Fixes following rebase from master

Upgraded to requery 1.3.1

WIP - removed 'latestOnly' from LinearStateQueryCriteria

WIP - CommercialSchemas V2, V3, V4 testing

WIP - sort out generics handling.

WIP - most general queries completed.

WIP - join queries, contractStateType derivation

WIP - refactoring Requery

WIP - refactored VaultService to extract a VaultQueryService interface (and associated Requery implementation).

WIP - HibernateVaultQuery implementation

WIP - Re-structured all Schema definitions (requery/jpa) and make Hibernate Config reusable.

WIP - Multi-version schema testing, hibernate query testing.

WIP - Custom Criteria and Fungible Criteria impl & testing.

WIP - Kotlin Comparable Generics error

WIP - Party queries all working now

WIP - All VaultQueryTests now working (refactored for AND / OR composition)

WIP - added schema registration in CordaPluginRegistry to enable custom vault queries on arbitrary schemas.

WIP - added new default Sort NULL order to be NONE + added lots more tests for Logical Operator testing.

Mostly identity fixes following rebase from master.

Exception handling and public API cleanup in prep for PR.

Additional tests for Logical Operators; additional tests for NULLS sort ordering; additional logging;

Additional parser to handle Nullable attribute values; added Unary and Collection logical expression handlers

Lots of cleanup: participants; trackBy interfaces; additional fungible tests; parser cleanup and improved support for Java

Removed all traces of Requery implementation.

Further minor cleanup and Junit test fix.

Final identity and schema related identity clean-up.

Revert unrelated changes.

PR review updates: blank lines, isRelevant.

Fixed wiring of updatesPublisher for dynamic trackBy queries.

PR review changes: multi-versioned schema samples and associated dummy contracts moved to test packages.

Fixed problem with sorted queries (not specifying any filterable criteria).

PR review: minor updates to address RP comments.

Typesafe custom query criteria

Cleanup: remove redundant tests.

Further clean-up and make all Java test work successfully.

Remove debugging print statements.

Rebased from master - changes required due to DealState module change.

fixed broken assertion caused by DealState ordering change (different package)

Fixed transaction demarcation issue causing "java.lang.IllegalStateException: Was not expecting to find existing database transaction on current strand"

trackBy() now filters on ContractType and StateStatus (CONSUMED, UNCONSUMED, ALL)

Added tests to exercise RPCOps trackBy and queryBy (RPC smoke test and CordaRPCOps)

Added additional @CordaSerializable annotations.

Updated documentation and referenced sample code.

Added deprecation annotations.

Re-added missing deprecation annotation.

Hibernate debug logging is now configurable and disabled by default.

Introduced common Sort attributes based on the node schemas.

Completely removed NULL_HANDLING sort parameter as this is not supported in JPA.

Revisited and fixed usage of @CordaSerializable.

* Minor fix following rebase from master.

* Remove blank line as per RP PR feedback request.

* Minor Java documentation and example clean-up.

* Disable BFT Notary Service tests.
2017-06-22 10:35:49 +01:00
Ross Nicoll
4d66e21f32 Release notes for M13 2017-06-21 14:04:22 +01:00
Ross Nicoll
19ff72a411 Correct ISO country code in names 2017-06-21 14:04:22 +01:00
Joel Dudley
d9d20f2215 Formatting and typos. Groups API docs in sidebar. Renames Persistence to API: Persistence and fixes some links. 2017-06-21 13:55:48 +01:00
szymonsztuka
4195adfb7b Move Web API from CordaPluginRegistry to new class WebPluginRegistry (#864)
Move Web API from CordaPluginRegistry to new class WebPluginRegistry
2017-06-20 15:29:35 +01:00
Joel Dudley
7fdbf1fa4a Adds a link to Hello, Word. Other minor fixes. 2017-06-20 11:26:36 +01:00
Patrick Kuo
28afb6d3ff Added throttling to the load test tool and added stability test. (#847)
* Added throttling to the load test tool.
* Added stability test to the tool.
* Some refactoring to allow some configuration via vm option.
* updated doc.
* gradle now passes system parameter to load test.
* using Guava's RateLimiter instead of execute at fix rate.
2017-06-16 15:30:11 +01:00
Joel Dudley
73fbcea0e3 Hello, World! CorDapp tutorial 2017-06-16 14:05:52 +01:00
Shams Asari
b52d3706eb Moved Driver.kt to net.corda.testing.driver in the test-utils module 2017-06-14 15:12:39 +01:00
Joel Dudley
e36a3c40e0 Updates the cheatsheet. 2017-06-14 10:12:42 +01:00
Mike Hearn
ccf43a8e17 Support fuzzy matching for identities.
Matching can be done with case insensitive substrings in the identity service, RPC and shell. In future cleverer matching should be possible, e.g. using Lucene or RDBMS free text search features.
2017-06-13 16:19:55 +02:00
Chris Rankin
d3de125166 Update documentation for DemoBench's MacOSX signing key. (#826) 2017-06-12 12:50:22 +01:00
Joel Dudley
48bbcb8a57 Changes master docs to reflect M12 last-minute changes. 2017-06-09 13:59:39 +01:00
Katarzyna Streich
1e4d1332c8 Change release tag number in docs. 2017-06-08 20:43:35 +01:00
Katarzyna Streich
394d937570 Update M11 to M12 in docs. (#818) 2017-06-08 17:56:52 +01:00