mirror of
https://github.com/corda/corda.git
synced 2024-12-21 05:53:23 +00:00
Merge pull request #5145 from corda/jdk11-migration-gradle5-upgrade
Jdk11 migration gradle5 upgrade
This commit is contained in:
commit
f46377556c
293
.idea/compiler.xml
generated
293
.idea/compiler.xml
generated
@ -1,12 +1,9 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<project version="4">
|
<project version="4">
|
||||||
<component name="CompilerConfiguration">
|
<component name="CompilerConfiguration">
|
||||||
<bytecodeTargetLevel target="1.8">
|
<bytecodeTargetLevel target="11">
|
||||||
<module name="api-scanner_main" target="1.8" />
|
|
||||||
<module name="api-scanner_test" target="1.8" />
|
|
||||||
<module name="attachment-demo-contracts_main" target="1.8" />
|
<module name="attachment-demo-contracts_main" target="1.8" />
|
||||||
<module name="attachment-demo-contracts_test" target="1.8" />
|
<module name="attachment-demo-contracts_test" target="1.8" />
|
||||||
<module name="attachment-demo-workflows_integrationTest" target="1.8" />
|
|
||||||
<module name="attachment-demo-workflows_main" target="1.8" />
|
<module name="attachment-demo-workflows_main" target="1.8" />
|
||||||
<module name="attachment-demo-workflows_test" target="1.8" />
|
<module name="attachment-demo-workflows_test" target="1.8" />
|
||||||
<module name="attachment-demo_integrationTest" target="1.8" />
|
<module name="attachment-demo_integrationTest" target="1.8" />
|
||||||
@ -14,27 +11,21 @@
|
|||||||
<module name="attachment-demo_test" target="1.8" />
|
<module name="attachment-demo_test" target="1.8" />
|
||||||
<module name="avalanche_main" target="1.8" />
|
<module name="avalanche_main" target="1.8" />
|
||||||
<module name="avalanche_test" target="1.8" />
|
<module name="avalanche_test" target="1.8" />
|
||||||
<module name="bank-of-corda-demo_integrationTest" target="1.8" />
|
|
||||||
<module name="bank-of-corda-demo_main" target="1.8" />
|
<module name="bank-of-corda-demo_main" target="1.8" />
|
||||||
<module name="bank-of-corda-demo_test" target="1.8" />
|
<module name="bank-of-corda-demo_test" target="1.8" />
|
||||||
<module name="behave_behave" target="1.8" />
|
<module name="behave_behave" target="1.8" />
|
||||||
<module name="behave_main" target="1.8" />
|
<module name="behave_main" target="1.8" />
|
||||||
<module name="behave_scenario" target="1.8" />
|
|
||||||
<module name="behave_test" target="1.8" />
|
<module name="behave_test" target="1.8" />
|
||||||
<module name="blobinspector_main" target="1.8" />
|
<module name="blobinspector_main" target="1.8" />
|
||||||
<module name="blobinspector_test" target="1.8" />
|
<module name="blobinspector_test" target="1.8" />
|
||||||
<module name="bootstrapper_main" target="1.8" />
|
<module name="bootstrapper_main" target="1.8" />
|
||||||
<module name="bootstrapper_test" target="1.8" />
|
<module name="bootstrapper_test" target="1.8" />
|
||||||
<module name="buildSrc_main" target="1.8" />
|
|
||||||
<module name="buildSrc_test" target="1.8" />
|
|
||||||
<module name="canonicalizer_main" target="1.8" />
|
|
||||||
<module name="canonicalizer_test" target="1.8" />
|
|
||||||
<module name="cli_main" target="1.8" />
|
|
||||||
<module name="cli_test" target="1.8" />
|
|
||||||
<module name="client_main" target="1.8" />
|
<module name="client_main" target="1.8" />
|
||||||
<module name="client_test" target="1.8" />
|
<module name="client_test" target="1.8" />
|
||||||
<module name="cliutils_main" target="1.8" />
|
<module name="cliutils_main" target="1.8" />
|
||||||
<module name="cliutils_test" target="1.8" />
|
<module name="cliutils_test" target="1.8" />
|
||||||
|
<module name="com.r3cev.prototyping-experimental_main" target="11" />
|
||||||
|
<module name="com.r3cev.prototyping-experimental_test" target="11" />
|
||||||
<module name="common-configuration-parsing_main" target="1.8" />
|
<module name="common-configuration-parsing_main" target="1.8" />
|
||||||
<module name="common-configuration-parsing_test" target="1.8" />
|
<module name="common-configuration-parsing_test" target="1.8" />
|
||||||
<module name="common-validation_main" target="1.8" />
|
<module name="common-validation_main" target="1.8" />
|
||||||
@ -43,34 +34,17 @@
|
|||||||
<module name="confidential-identities_test" target="1.8" />
|
<module name="confidential-identities_test" target="1.8" />
|
||||||
<module name="contracts-irs_main" target="1.8" />
|
<module name="contracts-irs_main" target="1.8" />
|
||||||
<module name="contracts-irs_test" target="1.8" />
|
<module name="contracts-irs_test" target="1.8" />
|
||||||
<module name="contracts-states_integrationTest" target="1.8" />
|
|
||||||
<module name="contracts-states_main" target="1.8" />
|
<module name="contracts-states_main" target="1.8" />
|
||||||
<module name="contracts-states_test" target="1.8" />
|
<module name="contracts-states_test" target="1.8" />
|
||||||
<module name="contracts_main" target="1.8" />
|
<module name="corda-project_buildSrc_main" target="11" />
|
||||||
<module name="contracts_test" target="1.8" />
|
<module name="corda-project_buildSrc_test" target="11" />
|
||||||
<module name="corda-core_integrationTest" target="1.8" />
|
<module name="corda-project_canonicalizer_main" target="11" />
|
||||||
<module name="corda-core_smokeTest" target="1.8" />
|
<module name="corda-project_canonicalizer_test" target="11" />
|
||||||
<module name="corda-finance_integrationTest" target="1.8" />
|
|
||||||
<module name="corda-isolated_main" target="1.8" />
|
|
||||||
<module name="corda-isolated_test" target="1.8" />
|
|
||||||
<module name="corda-project_buildSrc_main" target="1.8" />
|
|
||||||
<module name="corda-project_buildSrc_test" target="1.8" />
|
|
||||||
<module name="corda-project_canonicalizer_main" target="1.8" />
|
|
||||||
<module name="corda-project_canonicalizer_test" target="1.8" />
|
|
||||||
<module name="corda-project_main" target="1.8" />
|
<module name="corda-project_main" target="1.8" />
|
||||||
<module name="corda-project_test" target="1.8" />
|
<module name="corda-project_test" target="1.8" />
|
||||||
<module name="corda-smoke-test-utils_main" target="1.8" />
|
|
||||||
<module name="corda-smoke-test-utils_test" target="1.8" />
|
|
||||||
<module name="corda-test-common_main" target="1.8" />
|
|
||||||
<module name="corda-test-common_test" target="1.8" />
|
|
||||||
<module name="corda-test-utils_main" target="1.8" />
|
|
||||||
<module name="corda-test-utils_test" target="1.8" />
|
|
||||||
<module name="corda-utils_integrationTest" target="1.8" />
|
<module name="corda-utils_integrationTest" target="1.8" />
|
||||||
<module name="corda-utils_main" target="1.8" />
|
<module name="corda-utils_main" target="1.8" />
|
||||||
<module name="corda-utils_test" target="1.8" />
|
<module name="corda-utils_test" target="1.8" />
|
||||||
<module name="corda-webserver_integrationTest" target="1.8" />
|
|
||||||
<module name="corda-webserver_main" target="1.8" />
|
|
||||||
<module name="corda-webserver_test" target="1.8" />
|
|
||||||
<module name="cordapp-configuration-workflows_main" target="1.8" />
|
<module name="cordapp-configuration-workflows_main" target="1.8" />
|
||||||
<module name="cordapp-configuration-workflows_test" target="1.8" />
|
<module name="cordapp-configuration-workflows_test" target="1.8" />
|
||||||
<module name="cordapp-configuration_main" target="1.8" />
|
<module name="cordapp-configuration_main" target="1.8" />
|
||||||
@ -78,72 +52,36 @@
|
|||||||
<module name="cordapp_integrationTest" target="1.8" />
|
<module name="cordapp_integrationTest" target="1.8" />
|
||||||
<module name="cordapp_main" target="1.8" />
|
<module name="cordapp_main" target="1.8" />
|
||||||
<module name="cordapp_test" target="1.8" />
|
<module name="cordapp_test" target="1.8" />
|
||||||
<module name="cordform-common_main" target="1.8" />
|
|
||||||
<module name="cordform-common_test" target="1.8" />
|
|
||||||
<module name="cordformation_main" target="1.8" />
|
|
||||||
<module name="cordformation_runnodes" target="1.8" />
|
|
||||||
<module name="cordformation_test" target="1.8" />
|
|
||||||
<module name="core-deterministic_main" target="1.8" />
|
|
||||||
<module name="core-deterministic_test" target="1.8" />
|
|
||||||
<module name="core_extraResource" target="1.8" />
|
|
||||||
<module name="core_integrationTest" target="1.8" />
|
<module name="core_integrationTest" target="1.8" />
|
||||||
<module name="core_main" target="1.8" />
|
<module name="core_main" target="1.8" />
|
||||||
<module name="core_smokeTest" target="1.8" />
|
<module name="core_smokeTest" target="1.8" />
|
||||||
<module name="core_test" target="1.8" />
|
<module name="core_test" target="1.8" />
|
||||||
<module name="data_main" target="1.8" />
|
|
||||||
<module name="data_test" target="1.8" />
|
|
||||||
<module name="demobench_main" target="1.8" />
|
<module name="demobench_main" target="1.8" />
|
||||||
<module name="demobench_test" target="1.8" />
|
<module name="demobench_test" target="1.8" />
|
||||||
<module name="djvm_main" target="1.8" />
|
|
||||||
<module name="djvm_test" target="1.8" />
|
|
||||||
<module name="docker_main" target="1.8" />
|
<module name="docker_main" target="1.8" />
|
||||||
<module name="docker_test" target="1.8" />
|
<module name="docker_test" target="1.8" />
|
||||||
<module name="docs_main" target="1.8" />
|
<module name="docs_main" target="1.8" />
|
||||||
<module name="docs_source_example-code_integrationTest" target="1.8" />
|
|
||||||
<module name="docs_source_example-code_main" target="1.8" />
|
|
||||||
<module name="docs_source_example-code_test" target="1.8" />
|
|
||||||
<module name="docs_test" target="1.8" />
|
<module name="docs_test" target="1.8" />
|
||||||
<module name="example-code_integrationTest" target="1.8" />
|
<module name="example-code_integrationTest" target="1.8" />
|
||||||
<module name="example-code_main" target="1.8" />
|
<module name="example-code_main" target="1.8" />
|
||||||
<module name="example-code_test" target="1.8" />
|
<module name="example-code_test" target="1.8" />
|
||||||
<module name="experimental-behave_behave" target="1.8" />
|
|
||||||
<module name="experimental-behave_main" target="1.8" />
|
|
||||||
<module name="experimental-behave_test" target="1.8" />
|
|
||||||
<module name="experimental-kryo-hook_main" target="1.8" />
|
|
||||||
<module name="experimental-kryo-hook_test" target="1.8" />
|
|
||||||
<module name="experimental_main" target="1.8" />
|
<module name="experimental_main" target="1.8" />
|
||||||
<module name="experimental_test" target="1.8" />
|
<module name="experimental_test" target="1.8" />
|
||||||
<module name="explorer-capsule_main" target="1.6" />
|
<module name="explorer-capsule_main" target="1.6" />
|
||||||
<module name="explorer-capsule_test" target="1.6" />
|
<module name="explorer-capsule_test" target="1.6" />
|
||||||
<module name="explorer_main" target="1.8" />
|
<module name="explorer_main" target="1.8" />
|
||||||
<module name="explorer_test" target="1.8" />
|
<module name="explorer_test" target="1.8" />
|
||||||
<module name="finance-contracts-states_main" target="1.8" />
|
|
||||||
<module name="finance-contracts-states_test" target="1.8" />
|
|
||||||
<module name="finance-contracts_main" target="1.8" />
|
<module name="finance-contracts_main" target="1.8" />
|
||||||
<module name="finance-contracts_test" target="1.8" />
|
<module name="finance-contracts_test" target="1.8" />
|
||||||
<module name="finance-flows_integrationTest" target="1.8" />
|
|
||||||
<module name="finance-flows_main" target="1.8" />
|
|
||||||
<module name="finance-flows_test" target="1.8" />
|
|
||||||
<module name="finance-workflows_integrationTest" target="1.8" />
|
<module name="finance-workflows_integrationTest" target="1.8" />
|
||||||
<module name="finance-workflows_main" target="1.8" />
|
<module name="finance-workflows_main" target="1.8" />
|
||||||
<module name="finance-workflows_test" target="1.8" />
|
<module name="finance-workflows_test" target="1.8" />
|
||||||
<module name="finance_integrationTest" target="1.8" />
|
|
||||||
<module name="finance_main" target="1.8" />
|
<module name="finance_main" target="1.8" />
|
||||||
<module name="finance_test" target="1.8" />
|
<module name="finance_test" target="1.8" />
|
||||||
<module name="flows_integrationTest" target="1.8" />
|
|
||||||
<module name="flows_main" target="1.8" />
|
<module name="flows_main" target="1.8" />
|
||||||
<module name="flows_test" target="1.8" />
|
<module name="flows_test" target="1.8" />
|
||||||
<module name="gradle-plugins-cordapp_main" target="1.8" />
|
|
||||||
<module name="gradle-plugins-cordapp_test" target="1.8" />
|
|
||||||
<module name="graphs_main" target="1.8" />
|
<module name="graphs_main" target="1.8" />
|
||||||
<module name="graphs_test" target="1.8" />
|
<module name="graphs_test" target="1.8" />
|
||||||
<module name="irs-demo-cordapp_integrationTest" target="1.8" />
|
|
||||||
<module name="irs-demo-cordapp_main" target="1.8" />
|
|
||||||
<module name="irs-demo-cordapp_main~1" target="1.8" />
|
|
||||||
<module name="irs-demo-cordapp_test" target="1.8" />
|
|
||||||
<module name="irs-demo-cordapp_test~1" target="1.8" />
|
|
||||||
<module name="irs-demo-web_main" target="1.8" />
|
|
||||||
<module name="irs-demo-web_test" target="1.8" />
|
|
||||||
<module name="irs-demo_integrationTest" target="1.8" />
|
<module name="irs-demo_integrationTest" target="1.8" />
|
||||||
<module name="irs-demo_main" target="1.8" />
|
<module name="irs-demo_main" target="1.8" />
|
||||||
<module name="irs-demo_systemTest" target="1.8" />
|
<module name="irs-demo_systemTest" target="1.8" />
|
||||||
@ -152,27 +90,172 @@
|
|||||||
<module name="isolated_test" target="1.8" />
|
<module name="isolated_test" target="1.8" />
|
||||||
<module name="jackson_main" target="1.8" />
|
<module name="jackson_main" target="1.8" />
|
||||||
<module name="jackson_test" target="1.8" />
|
<module name="jackson_test" target="1.8" />
|
||||||
<module name="jarfilter_main" target="1.8" />
|
|
||||||
<module name="jarfilter_test" target="1.8" />
|
|
||||||
<module name="jdk8u-deterministic_main" target="1.8" />
|
<module name="jdk8u-deterministic_main" target="1.8" />
|
||||||
<module name="jdk8u-deterministic_test" target="1.8" />
|
<module name="jdk8u-deterministic_test" target="1.8" />
|
||||||
<module name="jfx_integrationTest" target="1.8" />
|
<module name="jfx_integrationTest" target="1.8" />
|
||||||
<module name="jfx_main" target="1.8" />
|
<module name="jfx_main" target="1.8" />
|
||||||
<module name="jfx_test" target="1.8" />
|
<module name="jfx_test" target="1.8" />
|
||||||
<module name="kryo-hook_main" target="1.8" />
|
|
||||||
<module name="kryo-hook_test" target="1.8" />
|
|
||||||
<module name="loadtest_main" target="1.8" />
|
<module name="loadtest_main" target="1.8" />
|
||||||
<module name="loadtest_test" target="1.8" />
|
<module name="loadtest_test" target="1.8" />
|
||||||
<module name="mock_main" target="1.8" />
|
<module name="mock_main" target="1.8" />
|
||||||
<module name="mock_test" target="1.8" />
|
<module name="mock_test" target="1.8" />
|
||||||
<module name="net.corda-blobinspector_main" target="1.8" />
|
<module name="net.corda-attachment-demo-contracts_main" target="11" />
|
||||||
<module name="net.corda-blobinspector_test" target="1.8" />
|
<module name="net.corda-attachment-demo-contracts_test" target="11" />
|
||||||
<module name="net.corda-finance-contracts-states_main" target="1.8" />
|
<module name="net.corda-attachment-demo-workflows_main" target="11" />
|
||||||
<module name="net.corda-finance-contracts-states_test" target="1.8" />
|
<module name="net.corda-attachment-demo-workflows_test" target="11" />
|
||||||
<module name="net.corda-isolated_main" target="1.8" />
|
<module name="net.corda-attachment-demo_integrationTest" target="11" />
|
||||||
<module name="net.corda-isolated_test" target="1.8" />
|
<module name="net.corda-attachment-demo_main" target="11" />
|
||||||
<module name="net.corda-verifier_main" target="1.8" />
|
<module name="net.corda-attachment-demo_test" target="11" />
|
||||||
<module name="net.corda-verifier_test" target="1.8" />
|
<module name="net.corda-avalanche_main" target="11" />
|
||||||
|
<module name="net.corda-avalanche_test" target="11" />
|
||||||
|
<module name="net.corda-bank-of-corda-demo_main" target="11" />
|
||||||
|
<module name="net.corda-bank-of-corda-demo_test" target="11" />
|
||||||
|
<module name="net.corda-blobinspector_main" target="11" />
|
||||||
|
<module name="net.corda-blobinspector_test" target="11" />
|
||||||
|
<module name="net.corda-bootstrapper_main" target="11" />
|
||||||
|
<module name="net.corda-bootstrapper_test" target="11" />
|
||||||
|
<module name="net.corda-client_main" target="11" />
|
||||||
|
<module name="net.corda-client_test" target="11" />
|
||||||
|
<module name="net.corda-cliutils_main" target="11" />
|
||||||
|
<module name="net.corda-cliutils_test" target="11" />
|
||||||
|
<module name="net.corda-common-configuration-parsing_main" target="11" />
|
||||||
|
<module name="net.corda-common-configuration-parsing_test" target="11" />
|
||||||
|
<module name="net.corda-common-validation_main" target="11" />
|
||||||
|
<module name="net.corda-common-validation_test" target="11" />
|
||||||
|
<module name="net.corda-confidential-identities_main" target="11" />
|
||||||
|
<module name="net.corda-confidential-identities_test" target="11" />
|
||||||
|
<module name="net.corda-contracts-irs_main" target="11" />
|
||||||
|
<module name="net.corda-contracts-irs_test" target="11" />
|
||||||
|
<module name="net.corda-contracts-states_main" target="11" />
|
||||||
|
<module name="net.corda-contracts-states_test" target="11" />
|
||||||
|
<module name="net.corda-corda-project_main" target="11" />
|
||||||
|
<module name="net.corda-corda-project_test" target="11" />
|
||||||
|
<module name="net.corda-corda-utils_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-corda-utils_main" target="11" />
|
||||||
|
<module name="net.corda-corda-utils_test" target="11" />
|
||||||
|
<module name="net.corda-cordapp-configuration-workflows_main" target="11" />
|
||||||
|
<module name="net.corda-cordapp-configuration-workflows_test" target="11" />
|
||||||
|
<module name="net.corda-cordapp-configuration_main" target="11" />
|
||||||
|
<module name="net.corda-cordapp-configuration_test" target="11" />
|
||||||
|
<module name="net.corda-cordapp_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-cordapp_main" target="11" />
|
||||||
|
<module name="net.corda-cordapp_test" target="11" />
|
||||||
|
<module name="net.corda-core_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-core_main" target="11" />
|
||||||
|
<module name="net.corda-core_smokeTest" target="11" />
|
||||||
|
<module name="net.corda-core_test" target="11" />
|
||||||
|
<module name="net.corda-demobench_main" target="11" />
|
||||||
|
<module name="net.corda-demobench_test" target="11" />
|
||||||
|
<module name="net.corda-docker_main" target="11" />
|
||||||
|
<module name="net.corda-docker_test" target="11" />
|
||||||
|
<module name="net.corda-docs_main" target="11" />
|
||||||
|
<module name="net.corda-docs_test" target="11" />
|
||||||
|
<module name="net.corda-example-code_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-example-code_main" target="11" />
|
||||||
|
<module name="net.corda-example-code_test" target="11" />
|
||||||
|
<module name="net.corda-explorer-capsule_main" target="1.6" />
|
||||||
|
<module name="net.corda-explorer-capsule_test" target="1.6" />
|
||||||
|
<module name="net.corda-explorer_main" target="11" />
|
||||||
|
<module name="net.corda-explorer_test" target="11" />
|
||||||
|
<module name="net.corda-finance-contracts_main" target="11" />
|
||||||
|
<module name="net.corda-finance-contracts_test" target="11" />
|
||||||
|
<module name="net.corda-finance-workflows_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-finance-workflows_main" target="11" />
|
||||||
|
<module name="net.corda-finance-workflows_test" target="11" />
|
||||||
|
<module name="net.corda-finance_main" target="11" />
|
||||||
|
<module name="net.corda-finance_test" target="11" />
|
||||||
|
<module name="net.corda-flows_main" target="11" />
|
||||||
|
<module name="net.corda-flows_test" target="11" />
|
||||||
|
<module name="net.corda-graphs_main" target="11" />
|
||||||
|
<module name="net.corda-graphs_test" target="11" />
|
||||||
|
<module name="net.corda-irs-demo_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-irs-demo_main" target="11" />
|
||||||
|
<module name="net.corda-irs-demo_systemTest" target="11" />
|
||||||
|
<module name="net.corda-irs-demo_test" target="11" />
|
||||||
|
<module name="net.corda-isolated_main" target="11" />
|
||||||
|
<module name="net.corda-isolated_test" target="11" />
|
||||||
|
<module name="net.corda-jackson_main" target="11" />
|
||||||
|
<module name="net.corda-jackson_test" target="11" />
|
||||||
|
<module name="net.corda-jdk8u-deterministic_main" target="11" />
|
||||||
|
<module name="net.corda-jdk8u-deterministic_test" target="11" />
|
||||||
|
<module name="net.corda-jfx_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-jfx_main" target="11" />
|
||||||
|
<module name="net.corda-jfx_test" target="11" />
|
||||||
|
<module name="net.corda-loadtest_main" target="11" />
|
||||||
|
<module name="net.corda-loadtest_test" target="11" />
|
||||||
|
<module name="net.corda-mock_main" target="11" />
|
||||||
|
<module name="net.corda-mock_test" target="11" />
|
||||||
|
<module name="net.corda-network-bootstrapper_main" target="11" />
|
||||||
|
<module name="net.corda-network-bootstrapper_test" target="11" />
|
||||||
|
<module name="net.corda-network-verifier-contracts_main" target="11" />
|
||||||
|
<module name="net.corda-network-verifier-contracts_test" target="11" />
|
||||||
|
<module name="net.corda-network-verifier-workflows_main" target="11" />
|
||||||
|
<module name="net.corda-network-verifier-workflows_test" target="11" />
|
||||||
|
<module name="net.corda-network-verifier_main" target="11" />
|
||||||
|
<module name="net.corda-network-verifier_test" target="11" />
|
||||||
|
<module name="net.corda-node-api_main" target="11" />
|
||||||
|
<module name="net.corda-node-api_test" target="11" />
|
||||||
|
<module name="net.corda-node-capsule_main" target="1.6" />
|
||||||
|
<module name="net.corda-node-capsule_test" target="1.6" />
|
||||||
|
<module name="net.corda-node-driver_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-node-driver_main" target="11" />
|
||||||
|
<module name="net.corda-node-driver_test" target="11" />
|
||||||
|
<module name="net.corda-node_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-node_main" target="11" />
|
||||||
|
<module name="net.corda-node_test" target="11" />
|
||||||
|
<module name="net.corda-notary-demo-contracts_main" target="11" />
|
||||||
|
<module name="net.corda-notary-demo-contracts_test" target="11" />
|
||||||
|
<module name="net.corda-notary-demo-workflows_main" target="11" />
|
||||||
|
<module name="net.corda-notary-demo-workflows_test" target="11" />
|
||||||
|
<module name="net.corda-notary-demo_main" target="11" />
|
||||||
|
<module name="net.corda-notary-demo_test" target="11" />
|
||||||
|
<module name="net.corda-quasar-hook_main" target="11" />
|
||||||
|
<module name="net.corda-quasar-hook_test" target="11" />
|
||||||
|
<module name="net.corda-rpc_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-rpc_main" target="11" />
|
||||||
|
<module name="net.corda-rpc_smokeTest" target="11" />
|
||||||
|
<module name="net.corda-rpc_test" target="11" />
|
||||||
|
<module name="net.corda-samples_main" target="11" />
|
||||||
|
<module name="net.corda-samples_test" target="11" />
|
||||||
|
<module name="net.corda-serialization_main" target="11" />
|
||||||
|
<module name="net.corda-serialization_test" target="11" />
|
||||||
|
<module name="net.corda-shell-cli_main" target="11" />
|
||||||
|
<module name="net.corda-shell-cli_test" target="11" />
|
||||||
|
<module name="net.corda-shell_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-shell_main" target="11" />
|
||||||
|
<module name="net.corda-shell_test" target="11" />
|
||||||
|
<module name="net.corda-simm-valuation-demo_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-simm-valuation-demo_main" target="11" />
|
||||||
|
<module name="net.corda-simm-valuation-demo_test" target="11" />
|
||||||
|
<module name="net.corda-smoke-test-utils_main" target="11" />
|
||||||
|
<module name="net.corda-smoke-test-utils_test" target="11" />
|
||||||
|
<module name="net.corda-test-cli_main" target="11" />
|
||||||
|
<module name="net.corda-test-cli_test" target="11" />
|
||||||
|
<module name="net.corda-test-common_main" target="11" />
|
||||||
|
<module name="net.corda-test-common_test" target="11" />
|
||||||
|
<module name="net.corda-test-utils_main" target="11" />
|
||||||
|
<module name="net.corda-test-utils_test" target="11" />
|
||||||
|
<module name="net.corda-tools_main" target="11" />
|
||||||
|
<module name="net.corda-tools_test" target="11" />
|
||||||
|
<module name="net.corda-trader-demo_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-trader-demo_main" target="11" />
|
||||||
|
<module name="net.corda-trader-demo_test" target="11" />
|
||||||
|
<module name="net.corda-webcapsule_main" target="1.6" />
|
||||||
|
<module name="net.corda-webcapsule_test" target="1.6" />
|
||||||
|
<module name="net.corda-webserver_integrationTest" target="11" />
|
||||||
|
<module name="net.corda-webserver_main" target="11" />
|
||||||
|
<module name="net.corda-webserver_test" target="11" />
|
||||||
|
<module name="net.corda-workflows-irs_main" target="11" />
|
||||||
|
<module name="net.corda-workflows-irs_test" target="11" />
|
||||||
|
<module name="net.corda-workflows-trader_main" target="11" />
|
||||||
|
<module name="net.corda-workflows-trader_test" target="11" />
|
||||||
|
<module name="net.corda-worldmap_main" target="11" />
|
||||||
|
<module name="net.corda-worldmap_test" target="11" />
|
||||||
|
<module name="net.corda.behave-behave_behave" target="11" />
|
||||||
|
<module name="net.corda.behave-behave_main" target="11" />
|
||||||
|
<module name="net.corda.behave-behave_test" target="11" />
|
||||||
|
<module name="net.corda.irs-demo-web_main" target="11" />
|
||||||
|
<module name="net.corda.irs-demo-web_test" target="11" />
|
||||||
<module name="net.corda_buildSrc_main" target="1.8" />
|
<module name="net.corda_buildSrc_main" target="1.8" />
|
||||||
<module name="net.corda_buildSrc_test" target="1.8" />
|
<module name="net.corda_buildSrc_test" target="1.8" />
|
||||||
<module name="net.corda_canonicalizer_main" target="1.8" />
|
<module name="net.corda_canonicalizer_main" target="1.8" />
|
||||||
@ -185,8 +268,6 @@
|
|||||||
<module name="network-verifier-workflows_test" target="1.8" />
|
<module name="network-verifier-workflows_test" target="1.8" />
|
||||||
<module name="network-verifier_main" target="1.8" />
|
<module name="network-verifier_main" target="1.8" />
|
||||||
<module name="network-verifier_test" target="1.8" />
|
<module name="network-verifier_test" target="1.8" />
|
||||||
<module name="network-visualiser_main" target="1.8" />
|
|
||||||
<module name="network-visualiser_test" target="1.8" />
|
|
||||||
<module name="node-api_main" target="1.8" />
|
<module name="node-api_main" target="1.8" />
|
||||||
<module name="node-api_test" target="1.8" />
|
<module name="node-api_test" target="1.8" />
|
||||||
<module name="node-capsule_main" target="1.6" />
|
<module name="node-capsule_main" target="1.6" />
|
||||||
@ -194,103 +275,57 @@
|
|||||||
<module name="node-driver_integrationTest" target="1.8" />
|
<module name="node-driver_integrationTest" target="1.8" />
|
||||||
<module name="node-driver_main" target="1.8" />
|
<module name="node-driver_main" target="1.8" />
|
||||||
<module name="node-driver_test" target="1.8" />
|
<module name="node-driver_test" target="1.8" />
|
||||||
<module name="node-schemas_main" target="1.8" />
|
|
||||||
<module name="node-schemas_test" target="1.8" />
|
|
||||||
<module name="node_integrationTest" target="1.8" />
|
<module name="node_integrationTest" target="1.8" />
|
||||||
<module name="node_main" target="1.8" />
|
<module name="node_main" target="1.8" />
|
||||||
<module name="node_smokeTest" target="1.8" />
|
|
||||||
<module name="node_test" target="1.8" />
|
<module name="node_test" target="1.8" />
|
||||||
<module name="notary-bft-smart_main" target="1.8" />
|
|
||||||
<module name="notary-bft-smart_test" target="1.8" />
|
|
||||||
<module name="notary-demo-contracts_main" target="1.8" />
|
<module name="notary-demo-contracts_main" target="1.8" />
|
||||||
<module name="notary-demo-contracts_test" target="1.8" />
|
<module name="notary-demo-contracts_test" target="1.8" />
|
||||||
<module name="notary-demo-workflows_main" target="1.8" />
|
<module name="notary-demo-workflows_main" target="1.8" />
|
||||||
<module name="notary-demo-workflows_test" target="1.8" />
|
<module name="notary-demo-workflows_test" target="1.8" />
|
||||||
<module name="notary-demo_main" target="1.8" />
|
<module name="notary-demo_main" target="1.8" />
|
||||||
<module name="notary-demo_test" target="1.8" />
|
<module name="notary-demo_test" target="1.8" />
|
||||||
<module name="notary-raft_main" target="1.8" />
|
|
||||||
<module name="notary-raft_test" target="1.8" />
|
|
||||||
<module name="publish-utils_main" target="1.8" />
|
|
||||||
<module name="publish-utils_test" target="1.8" />
|
|
||||||
<module name="quasar-hook_main" target="1.8" />
|
<module name="quasar-hook_main" target="1.8" />
|
||||||
<module name="quasar-hook_test" target="1.8" />
|
<module name="quasar-hook_test" target="1.8" />
|
||||||
<module name="quasar-utils_main" target="1.8" />
|
|
||||||
<module name="quasar-utils_test" target="1.8" />
|
|
||||||
<module name="rpc_integrationTest" target="1.8" />
|
<module name="rpc_integrationTest" target="1.8" />
|
||||||
<module name="rpc_main" target="1.8" />
|
<module name="rpc_main" target="1.8" />
|
||||||
<module name="rpc_smokeTest" target="1.8" />
|
<module name="rpc_smokeTest" target="1.8" />
|
||||||
<module name="rpc_test" target="1.8" />
|
<module name="rpc_test" target="1.8" />
|
||||||
<module name="samples_main" target="1.8" />
|
<module name="samples_main" target="1.8" />
|
||||||
<module name="samples_test" target="1.8" />
|
<module name="samples_test" target="1.8" />
|
||||||
<module name="sandbox_main" target="1.8" />
|
|
||||||
<module name="sandbox_test" target="1.8" />
|
|
||||||
<module name="serialization-deterministic_main" target="1.8" />
|
|
||||||
<module name="serialization-deterministic_test" target="1.8" />
|
|
||||||
<module name="serialization_main" target="1.8" />
|
<module name="serialization_main" target="1.8" />
|
||||||
<module name="serialization_test" target="1.8" />
|
<module name="serialization_test" target="1.8" />
|
||||||
<module name="shell-cli_integrationTest" target="1.8" />
|
|
||||||
<module name="shell-cli_main" target="1.8" />
|
<module name="shell-cli_main" target="1.8" />
|
||||||
<module name="shell-cli_test" target="1.8" />
|
<module name="shell-cli_test" target="1.8" />
|
||||||
<module name="shell_integrationTest" target="1.8" />
|
<module name="shell_integrationTest" target="1.8" />
|
||||||
<module name="shell_main" target="1.8" />
|
<module name="shell_main" target="1.8" />
|
||||||
<module name="shell_test" target="1.8" />
|
<module name="shell_test" target="1.8" />
|
||||||
<module name="simm-valuation-demo-contracts-states_main" target="1.8" />
|
|
||||||
<module name="simm-valuation-demo-contracts-states_test" target="1.8" />
|
|
||||||
<module name="simm-valuation-demo_integrationTest" target="1.8" />
|
<module name="simm-valuation-demo_integrationTest" target="1.8" />
|
||||||
<module name="simm-valuation-demo_main" target="1.8" />
|
<module name="simm-valuation-demo_main" target="1.8" />
|
||||||
<module name="simm-valuation-demo_test" target="1.8" />
|
<module name="simm-valuation-demo_test" target="1.8" />
|
||||||
<module name="smoke-test-utils_main" target="1.8" />
|
<module name="smoke-test-utils_main" target="1.8" />
|
||||||
<module name="smoke-test-utils_test" target="1.8" />
|
<module name="smoke-test-utils_test" target="1.8" />
|
||||||
<module name="source-example-code_integrationTest" target="1.8" />
|
|
||||||
<module name="source-example-code_main" target="1.8" />
|
|
||||||
<module name="source-example-code_test" target="1.8" />
|
|
||||||
<module name="test-cli_main" target="1.8" />
|
<module name="test-cli_main" target="1.8" />
|
||||||
<module name="test-cli_test" target="1.8" />
|
<module name="test-cli_test" target="1.8" />
|
||||||
<module name="test-common_main" target="1.8" />
|
<module name="test-common_main" target="1.8" />
|
||||||
<module name="test-common_test" target="1.8" />
|
<module name="test-common_test" target="1.8" />
|
||||||
<module name="test-utils_integrationTest" target="1.8" />
|
|
||||||
<module name="test-utils_main" target="1.8" />
|
<module name="test-utils_main" target="1.8" />
|
||||||
<module name="test-utils_test" target="1.8" />
|
<module name="test-utils_test" target="1.8" />
|
||||||
<module name="testing-node-driver_integrationTest" target="1.8" />
|
|
||||||
<module name="testing-node-driver_main" target="1.8" />
|
|
||||||
<module name="testing-node-driver_test" target="1.8" />
|
|
||||||
<module name="testing-smoke-test-utils_main" target="1.8" />
|
|
||||||
<module name="testing-smoke-test-utils_test" target="1.8" />
|
|
||||||
<module name="testing-test-common_main" target="1.8" />
|
|
||||||
<module name="testing-test-common_test" target="1.8" />
|
|
||||||
<module name="testing-test-utils_main" target="1.8" />
|
|
||||||
<module name="testing-test-utils_test" target="1.8" />
|
|
||||||
<module name="testing_main" target="1.8" />
|
|
||||||
<module name="testing_test" target="1.8" />
|
|
||||||
<module name="tools-blobinspector_main" target="1.8" />
|
|
||||||
<module name="tools-blobinspector_test" target="1.8" />
|
|
||||||
<module name="tools_main" target="1.8" />
|
<module name="tools_main" target="1.8" />
|
||||||
<module name="tools_test" target="1.8" />
|
<module name="tools_test" target="1.8" />
|
||||||
<module name="trader-demo_integrationTest" target="1.8" />
|
<module name="trader-demo_integrationTest" target="1.8" />
|
||||||
<module name="trader-demo_main" target="1.8" />
|
<module name="trader-demo_main" target="1.8" />
|
||||||
<module name="trader-demo_test" target="1.8" />
|
<module name="trader-demo_test" target="1.8" />
|
||||||
<module name="unwanteds_main" target="1.8" />
|
|
||||||
<module name="unwanteds_test" target="1.8" />
|
|
||||||
<module name="verifier_integrationTest" target="1.8" />
|
|
||||||
<module name="verifier_main" target="1.8" />
|
|
||||||
<module name="verifier_test" target="1.8" />
|
|
||||||
<module name="web_main" target="1.8" />
|
<module name="web_main" target="1.8" />
|
||||||
<module name="web_test" target="1.8" />
|
<module name="web_test" target="1.8" />
|
||||||
<module name="webcapsule_main" target="1.6" />
|
<module name="webcapsule_main" target="1.6" />
|
||||||
<module name="webcapsule_test" target="1.6" />
|
<module name="webcapsule_test" target="1.6" />
|
||||||
<module name="webserver-webcapsule_main" target="1.8" />
|
|
||||||
<module name="webserver-webcapsule_test" target="1.8" />
|
|
||||||
<module name="webserver_integrationTest" target="1.8" />
|
<module name="webserver_integrationTest" target="1.8" />
|
||||||
<module name="webserver_main" target="1.8" />
|
<module name="webserver_main" target="1.8" />
|
||||||
<module name="webserver_test" target="1.8" />
|
<module name="webserver_test" target="1.8" />
|
||||||
<module name="workflows-irs_main" target="1.8" />
|
<module name="workflows-irs_main" target="1.8" />
|
||||||
<module name="workflows-irs_test" target="1.8" />
|
<module name="workflows-irs_test" target="1.8" />
|
||||||
<module name="workflows-trader_integrationTest" target="1.8" />
|
|
||||||
<module name="workflows-trader_main" target="1.8" />
|
<module name="workflows-trader_main" target="1.8" />
|
||||||
<module name="workflows-trader_test" target="1.8" />
|
<module name="workflows-trader_test" target="1.8" />
|
||||||
<module name="workflows_integrationTest" target="1.8" />
|
|
||||||
<module name="workflows_main" target="1.8" />
|
|
||||||
<module name="workflows_test" target="1.8" />
|
|
||||||
<module name="worldmap_main" target="1.8" />
|
<module name="worldmap_main" target="1.8" />
|
||||||
<module name="worldmap_test" target="1.8" />
|
<module name="worldmap_test" target="1.8" />
|
||||||
</bytecodeTargetLevel>
|
</bytecodeTargetLevel>
|
||||||
|
81
build.gradle
81
build.gradle
@ -1,3 +1,6 @@
|
|||||||
|
import static org.gradle.api.JavaVersion.VERSION_1_8
|
||||||
|
import static org.gradle.api.JavaVersion.VERSION_11
|
||||||
|
|
||||||
buildscript {
|
buildscript {
|
||||||
// For sharing constants between builds
|
// For sharing constants between builds
|
||||||
Properties constants = new Properties()
|
Properties constants = new Properties()
|
||||||
@ -46,7 +49,7 @@ buildscript {
|
|||||||
ext.junit_vintage_version = '5.5.0-M1'
|
ext.junit_vintage_version = '5.5.0-M1'
|
||||||
ext.junit_jupiter_version = '5.5.0-M1'
|
ext.junit_jupiter_version = '5.5.0-M1'
|
||||||
ext.junit_platform_version = '1.4.2'
|
ext.junit_platform_version = '1.4.2'
|
||||||
ext.mockito_version = '2.18.3'
|
ext.mockito_version = '2.24.0'
|
||||||
ext.mockito_kotlin_version = '1.5.0'
|
ext.mockito_kotlin_version = '1.5.0'
|
||||||
ext.hamkrest_version = '1.4.2.2'
|
ext.hamkrest_version = '1.4.2.2'
|
||||||
ext.jopt_simple_version = '5.0.2'
|
ext.jopt_simple_version = '5.0.2'
|
||||||
@ -81,6 +84,7 @@ buildscript {
|
|||||||
ext.jcabi_manifests_version = '1.1'
|
ext.jcabi_manifests_version = '1.1'
|
||||||
ext.picocli_version = '3.8.0'
|
ext.picocli_version = '3.8.0'
|
||||||
ext.commons_io_version = '2.6'
|
ext.commons_io_version = '2.6'
|
||||||
|
ext.gradle_modules_plugin_version = constants.getProperty('gradleModulesPluginVersion')
|
||||||
|
|
||||||
// Name of the IntelliJ SDK created for the deterministic Java rt.jar.
|
// Name of the IntelliJ SDK created for the deterministic Java rt.jar.
|
||||||
// ext.deterministic_idea_sdk = '1.8 (Deterministic)'
|
// ext.deterministic_idea_sdk = '1.8 (Deterministic)'
|
||||||
@ -100,6 +104,14 @@ buildscript {
|
|||||||
maven {
|
maven {
|
||||||
url "$artifactory_contextUrl/corda-releases"
|
url "$artifactory_contextUrl/corda-releases"
|
||||||
}
|
}
|
||||||
|
// TEMP: remove once Corda Gradle plugins 5.0.0 published.
|
||||||
|
maven {
|
||||||
|
url "$artifactory_contextUrl/corda-dev"
|
||||||
|
}
|
||||||
|
// JDK11 Java modules gradle plugin
|
||||||
|
maven {
|
||||||
|
url "https://plugins.gradle.org/m2/"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
|
||||||
@ -121,6 +133,7 @@ buildscript {
|
|||||||
// Capsule gradle plugin forked and maintained locally to support Gradle 5.x
|
// Capsule gradle plugin forked and maintained locally to support Gradle 5.x
|
||||||
// See https://github.com/corda/gradle-capsule-plugin
|
// See https://github.com/corda/gradle-capsule-plugin
|
||||||
classpath "us.kirchmeier:gradle-capsule-plugin:1.0.4_r3"
|
classpath "us.kirchmeier:gradle-capsule-plugin:1.0.4_r3"
|
||||||
|
// classpath "org.javamodularity:moduleplugin:$gradle_modules_plugin_version"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -128,6 +141,8 @@ plugins {
|
|||||||
// Add the shadow plugin to the plugins classpath for the entire project.
|
// Add the shadow plugin to the plugins classpath for the entire project.
|
||||||
id 'com.github.johnrengelman.shadow' version '2.0.4' apply false
|
id 'com.github.johnrengelman.shadow' version '2.0.4' apply false
|
||||||
id "com.gradle.build-scan" version "2.2.1"
|
id "com.gradle.build-scan" version "2.2.1"
|
||||||
|
|
||||||
|
// id 'org.javamodularity.moduleplugin' version '1.5.0' apply true
|
||||||
}
|
}
|
||||||
|
|
||||||
ext {
|
ext {
|
||||||
@ -145,15 +160,56 @@ apply plugin: 'com.jfrog.artifactory'
|
|||||||
// with the run configurations. It also doesn't realise that the project is a Java 8 project and misconfigures
|
// with the run configurations. It also doesn't realise that the project is a Java 8 project and misconfigures
|
||||||
// the resulting import. This fixes it.
|
// the resulting import. This fixes it.
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
sourceCompatibility = 1.8
|
//apply plugin: 'org.javamodularity.moduleplugin'
|
||||||
targetCompatibility = 1.8
|
|
||||||
|
|
||||||
|
sourceCompatibility = VERSION_1_8
|
||||||
|
targetCompatibility = VERSION_11
|
||||||
|
println "JAVA_HOME: " + System.getenv('JAVA_HOME')
|
||||||
|
println "Java version: " + JavaVersion.current()
|
||||||
|
println "Java source compatibility: " + sourceCompatibility
|
||||||
|
println "Java target compatibility: " + targetCompatibility
|
||||||
|
|
||||||
|
|
||||||
|
// allprojects not allowed ???
|
||||||
|
// Could not find method kotlinCompile() for arguments [build_1cxylkaspro03mtms9c9xoxft$_run_closure2$_closure16@2dd8b9f2] on root project 'corda-project' of type org.gradle.api.Project.
|
||||||
|
//subprojects {
|
||||||
|
// // inlined usage of compileJava with moduleOptions not allowed ???
|
||||||
|
// // Could not find method moduleOptions() for arguments [build_1cxylkaspro03mtms9c9xoxft$_run_closure2$_closure16$_closure18@afb78c] on task ':client:compileJava' of type org.gradle.api.tasks.compile.JavaCompile.
|
||||||
|
// apply plugin: 'java'
|
||||||
|
// apply plugin: 'kotlin'
|
||||||
|
// apply plugin: "org.javamodularity.moduleplugin"
|
||||||
|
// kotlinCompile {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// compileJava {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// test {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
allprojects {
|
allprojects {
|
||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: 'jacoco'
|
apply plugin: 'jacoco'
|
||||||
apply plugin: 'org.owasp.dependencycheck'
|
apply plugin: 'org.owasp.dependencycheck'
|
||||||
apply plugin: 'kotlin-allopen'
|
apply plugin: 'kotlin-allopen'
|
||||||
|
// apply plugin: 'org.javamodularity.moduleplugin'
|
||||||
|
|
||||||
allOpen {
|
allOpen {
|
||||||
annotations(
|
annotations(
|
||||||
@ -177,12 +233,25 @@ allprojects {
|
|||||||
nugetconfEnabled = false
|
nugetconfEnabled = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
sourceCompatibility = 1.8
|
sourceCompatibility = VERSION_1_8
|
||||||
targetCompatibility = 1.8
|
targetCompatibility = VERSION_11
|
||||||
|
|
||||||
|
jacoco {
|
||||||
|
// JDK11 official support (https://github.com/jacoco/jacoco/releases/tag/v0.8.3)
|
||||||
|
toolVersion = "0.8.3"
|
||||||
|
}
|
||||||
|
|
||||||
tasks.withType(JavaCompile) {
|
tasks.withType(JavaCompile) {
|
||||||
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" << "-Xlint:-options" << "-parameters"
|
options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" << "-Xlint:-options" << "-parameters"
|
||||||
|
//<< "--illegal-access=warn"
|
||||||
options.encoding = 'UTF-8'
|
options.encoding = 'UTF-8'
|
||||||
|
options.verbose = true
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile) {
|
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile) {
|
||||||
@ -210,6 +279,7 @@ allprojects {
|
|||||||
tasks.withType(Test) {
|
tasks.withType(Test) {
|
||||||
useJUnitPlatform()
|
useJUnitPlatform()
|
||||||
|
|
||||||
|
ignoreFailures = project.hasProperty('tests.ignoreFailures') ? project.property('tests.ignoreFailures').toBoolean() : false
|
||||||
failFast = project.hasProperty('tests.failFast') ? project.property('tests.failFast').toBoolean() : false
|
failFast = project.hasProperty('tests.failFast') ? project.property('tests.failFast').toBoolean() : false
|
||||||
|
|
||||||
// Prevent the project from creating temporary files outside of the build directory.
|
// Prevent the project from creating temporary files outside of the build directory.
|
||||||
@ -247,6 +317,7 @@ allprojects {
|
|||||||
maven { url "$artifactory_contextUrl/corda-dependencies" }
|
maven { url "$artifactory_contextUrl/corda-dependencies" }
|
||||||
maven { url 'https://jitpack.io' }
|
maven { url 'https://jitpack.io' }
|
||||||
maven { url 'https://repo.gradle.org/gradle/libs-releases' }
|
maven { url 'https://repo.gradle.org/gradle/libs-releases' }
|
||||||
|
maven { url "https://plugins.gradle.org/m2/" }
|
||||||
}
|
}
|
||||||
|
|
||||||
configurations {
|
configurations {
|
||||||
|
@ -1,3 +1,13 @@
|
|||||||
|
// JDK 11 JavaFX
|
||||||
|
plugins {
|
||||||
|
id 'org.openjfx.javafxplugin' version '0.0.7'
|
||||||
|
}
|
||||||
|
javafx {
|
||||||
|
modules = [ 'javafx.controls',
|
||||||
|
'javafx.fxml'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: 'net.corda.plugins.quasar-utils'
|
apply plugin: 'net.corda.plugins.quasar-utils'
|
||||||
apply plugin: 'net.corda.plugins.publish-utils'
|
apply plugin: 'net.corda.plugins.publish-utils'
|
||||||
|
@ -41,6 +41,9 @@ class AggregatedList<A, E : Any, K : Any>(
|
|||||||
val toKey: (E) -> K,
|
val toKey: (E) -> K,
|
||||||
val assemble: (K, ObservableList<E>) -> A
|
val assemble: (K, ObservableList<E>) -> A
|
||||||
) : TransformationList<A, E>(list) {
|
) : TransformationList<A, E>(list) {
|
||||||
|
override fun getViewIndex(p0: Int): Int {
|
||||||
|
TODO("not implemented") //To change body of created functions use File | Settings | File Templates.
|
||||||
|
}
|
||||||
|
|
||||||
private class AggregationGroup<E, out A>(
|
private class AggregationGroup<E, out A>(
|
||||||
val keyHashCode: Int,
|
val keyHashCode: Int,
|
||||||
|
@ -11,6 +11,10 @@ import java.util.*
|
|||||||
* is propagated as expected.
|
* is propagated as expected.
|
||||||
*/
|
*/
|
||||||
class ConcatenatedList<A>(sourceList: ObservableList<ObservableList<A>>) : TransformationList<A, ObservableList<A>>(sourceList) {
|
class ConcatenatedList<A>(sourceList: ObservableList<ObservableList<A>>) : TransformationList<A, ObservableList<A>>(sourceList) {
|
||||||
|
override fun getViewIndex(p0: Int): Int {
|
||||||
|
TODO("not implemented") //To change body of created functions use File | Settings | File Templates.
|
||||||
|
}
|
||||||
|
|
||||||
// A wrapper for input lists so we hash differently even if a list is reused in the input.
|
// A wrapper for input lists so we hash differently even if a list is reused in the input.
|
||||||
@VisibleForTesting
|
@VisibleForTesting
|
||||||
internal class WrappedObservableList<A>(
|
internal class WrappedObservableList<A>(
|
||||||
|
@ -12,6 +12,9 @@ import java.util.*
|
|||||||
* are reflected in the exposed list as expected.
|
* are reflected in the exposed list as expected.
|
||||||
*/
|
*/
|
||||||
class FlattenedList<A>(val sourceList: ObservableList<out ObservableValue<out A>>) : TransformationList<A, ObservableValue<out A>>(sourceList) {
|
class FlattenedList<A>(val sourceList: ObservableList<out ObservableValue<out A>>) : TransformationList<A, ObservableValue<out A>>(sourceList) {
|
||||||
|
override fun getViewIndex(p0: Int): Int {
|
||||||
|
TODO("not implemented") //To change body of created functions use File | Settings | File Templates.
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* We maintain an ObservableValue->index map. This is needed because we need the ObservableValue's index in order to
|
* We maintain an ObservableValue->index map. This is needed because we need the ObservableValue's index in order to
|
||||||
|
@ -11,6 +11,10 @@ import java.util.*
|
|||||||
* Use this instead of [EasyBind.map] to trade off memory vs CPU, or if (god forbid) the mapped function is side-effecting.
|
* Use this instead of [EasyBind.map] to trade off memory vs CPU, or if (god forbid) the mapped function is side-effecting.
|
||||||
*/
|
*/
|
||||||
class MappedList<A, B>(list: ObservableList<A>, val function: (A) -> B) : TransformationList<B, A>(list) {
|
class MappedList<A, B>(list: ObservableList<A>, val function: (A) -> B) : TransformationList<B, A>(list) {
|
||||||
|
override fun getViewIndex(p0: Int): Int {
|
||||||
|
TODO("not implemented") //To change body of created functions use File | Settings | File Templates.
|
||||||
|
}
|
||||||
|
|
||||||
private val backingList = ArrayList<B>(list.size)
|
private val backingList = ArrayList<B>(list.size)
|
||||||
|
|
||||||
init {
|
init {
|
||||||
|
@ -10,6 +10,9 @@ import java.util.*
|
|||||||
* non-backed observable
|
* non-backed observable
|
||||||
*/
|
*/
|
||||||
class ReplayedList<A>(sourceList: ObservableList<A>) : TransformationList<A, A>(sourceList) {
|
class ReplayedList<A>(sourceList: ObservableList<A>) : TransformationList<A, A>(sourceList) {
|
||||||
|
override fun getViewIndex(p0: Int): Int {
|
||||||
|
TODO("not implemented") //To change body of created functions use File | Settings | File Templates.
|
||||||
|
}
|
||||||
|
|
||||||
val replayedList = ArrayList<A>(sourceList)
|
val replayedList = ArrayList<A>(sourceList)
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
# their own projects. So don't get fancy with syntax!
|
# their own projects. So don't get fancy with syntax!
|
||||||
|
|
||||||
cordaVersion=5.0-SNAPSHOT
|
cordaVersion=5.0-SNAPSHOT
|
||||||
gradlePluginsVersion=5.0.0
|
gradlePluginsVersion=5.0.1-SNAPSHOT
|
||||||
kotlinVersion=1.2.71
|
kotlinVersion=1.2.71
|
||||||
java8MinUpdateVersion=171
|
java8MinUpdateVersion=171
|
||||||
# ***************************************************************#
|
# ***************************************************************#
|
||||||
@ -12,7 +12,8 @@ java8MinUpdateVersion=171
|
|||||||
# ***************************************************************#
|
# ***************************************************************#
|
||||||
platformVersion=5
|
platformVersion=5
|
||||||
guavaVersion=25.1-jre
|
guavaVersion=25.1-jre
|
||||||
quasarVersion=0.7.10
|
# JDK11 support added in 0.8.0 (https://github.com/puniverse/quasar/issues/317)
|
||||||
|
quasarVersion=0.8.0
|
||||||
proguardVersion=6.0.3
|
proguardVersion=6.0.3
|
||||||
bouncycastleVersion=1.60
|
bouncycastleVersion=1.60
|
||||||
disruptorVersion=3.4.2
|
disruptorVersion=3.4.2
|
||||||
@ -23,3 +24,4 @@ snakeYamlVersion=1.19
|
|||||||
caffeineVersion=2.6.2
|
caffeineVersion=2.6.2
|
||||||
metricsVersion=3.2.5
|
metricsVersion=3.2.5
|
||||||
metricsNewRelicVersion=1.1.1
|
metricsNewRelicVersion=1.1.1
|
||||||
|
gradleModulesPluginVersion=1.5.0
|
||||||
|
@ -1,3 +1,6 @@
|
|||||||
|
//plugins {
|
||||||
|
// id 'org.javamodularity.moduleplugin'
|
||||||
|
//}
|
||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: 'kotlin-jpa'
|
apply plugin: 'kotlin-jpa'
|
||||||
apply plugin: 'net.corda.plugins.quasar-utils'
|
apply plugin: 'net.corda.plugins.quasar-utils'
|
||||||
@ -9,6 +12,56 @@ description 'Corda core'
|
|||||||
|
|
||||||
evaluationDependsOn(':node:capsule')
|
evaluationDependsOn(':node:capsule')
|
||||||
|
|
||||||
|
//subprojects {
|
||||||
|
// apply plugin: 'java'
|
||||||
|
// apply plugin: "org.javamodularity.moduleplugin"
|
||||||
|
// kotlinCompile {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// compileJava {
|
||||||
|
// moduleOptions {
|
||||||
|
//// addModules = []
|
||||||
|
//// addReads = [:]
|
||||||
|
//// addOpens = [:]
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
//// 'java.base/sun.security.util.BitArray': 'ALL-UNNAMED',
|
||||||
|
//// 'java.base/sun.security.util.ObjectIdentifier': 'ALL-UNNAMED',
|
||||||
|
//// 'java.base/sun.security.x509.AlgorithmId': 'ALL-UNNAMED',
|
||||||
|
//// 'java.base/sun.security.x509.X509Key': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
//// addExports = [:]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// test {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
|
//allprojects {
|
||||||
|
// apply plugin: 'java'
|
||||||
|
// apply plugin: "org.javamodularity.moduleplugin"
|
||||||
|
// compileJava {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
configurations {
|
configurations {
|
||||||
integrationTestCompile.extendsFrom testCompile
|
integrationTestCompile.extendsFrom testCompile
|
||||||
integrationTestRuntimeOnly.extendsFrom testRuntimeOnly
|
integrationTestRuntimeOnly.extendsFrom testRuntimeOnly
|
||||||
@ -125,8 +178,20 @@ dependencies {
|
|||||||
compile "org.hibernate:hibernate-core:$hibernate_version"
|
compile "org.hibernate:hibernate-core:$hibernate_version"
|
||||||
|
|
||||||
compile group: "io.github.classgraph", name: "classgraph", version: class_graph_version
|
compile group: "io.github.classgraph", name: "classgraph", version: class_graph_version
|
||||||
|
|
||||||
|
// JDK 11 (https://stackoverflow.com/questions/52502189/java-11-package-javax-xml-bind-does-not-exist)
|
||||||
|
compile group: 'javax.xml.bind', name: 'jaxb-api', version: '2.3.0'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//compileJava {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
// TODO Consider moving it to quasar-utils in the future (introduced with PR-1388)
|
// TODO Consider moving it to quasar-utils in the future (introduced with PR-1388)
|
||||||
task copyQuasarJar(type: Copy) {
|
task copyQuasarJar(type: Copy) {
|
||||||
from configurations.quasar
|
from configurations.quasar
|
||||||
@ -143,9 +208,28 @@ configurations {
|
|||||||
testArtifacts.extendsFrom testRuntimeClasspath
|
testArtifacts.extendsFrom testRuntimeClasspath
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.withType(JavaCompile) {
|
||||||
|
// Relaxes JPMS visibility constraints across module boundaries
|
||||||
|
options.compilerArgs << '--add-exports' << 'java.base/sun.security.util=ALL-UNNAMED' << '--add-exports' << 'java.base/sun.security.x509=ALL-UNNAMED'
|
||||||
|
}
|
||||||
|
|
||||||
|
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile) {
|
||||||
|
kotlinOptions {
|
||||||
|
verbose = true
|
||||||
|
allWarningsAsErrors = false
|
||||||
|
// Kotlin Compiler does not yet support passing Modularity directives (eg. add-exports, add-reads, patch-module).
|
||||||
|
// https://youtrack.jetbrains.com/issue/KT-20740
|
||||||
|
// freeCompilerArgs = ['--add-export','java.base/sun.security.util=ALL-UNNAMED']
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
tasks.withType(Test) {
|
tasks.withType(Test) {
|
||||||
// fork a new test process for every test class
|
// fork a new test process for every test class
|
||||||
forkEvery = 10
|
forkEvery = 10
|
||||||
|
|
||||||
|
ignoreFailures = true
|
||||||
|
failFast = false
|
||||||
|
jvmArgs '--add-exports=java.base/sun.security.util=ALL-UNNAMED'
|
||||||
}
|
}
|
||||||
|
|
||||||
task testJar(type: Jar) {
|
task testJar(type: Jar) {
|
||||||
|
@ -42,6 +42,7 @@ fun checkMinimumPlatformVersion(minimumPlatformVersion: Int, requiredMinPlatform
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// JDK11: revisit (JDK 9+ uses different numbering scheme: see https://docs.oracle.com/javase/9/docs/api/java/lang/Runtime.Version.html)
|
||||||
@Throws(NumberFormatException::class)
|
@Throws(NumberFormatException::class)
|
||||||
fun getJavaUpdateVersion(javaVersion: String): Long = javaVersion.substringAfter("_").substringBefore("-").toLong()
|
fun getJavaUpdateVersion(javaVersion: String): Long = javaVersion.substringAfter("_").substringBefore("-").toLong()
|
||||||
|
|
||||||
|
@ -1,37 +0,0 @@
|
|||||||
package net.corda.core.schemas;
|
|
||||||
|
|
||||||
import javax.persistence.*;
|
|
||||||
import java.util.Arrays;
|
|
||||||
|
|
||||||
public class BadSchemaJavaV1 extends MappedSchema {
|
|
||||||
|
|
||||||
public BadSchemaJavaV1() {
|
|
||||||
super(TestJavaSchemaFamily.class, 1, Arrays.asList(State.class));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Entity
|
|
||||||
public static class State extends PersistentState {
|
|
||||||
private String id;
|
|
||||||
private GoodSchemaJavaV1.State other;
|
|
||||||
|
|
||||||
@Column
|
|
||||||
public String getId() {
|
|
||||||
return id;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setId(String id) {
|
|
||||||
this.id = id;
|
|
||||||
}
|
|
||||||
|
|
||||||
@JoinColumns({@JoinColumn(name = "itid"), @JoinColumn(name = "outid")})
|
|
||||||
@OneToOne
|
|
||||||
@MapsId
|
|
||||||
public GoodSchemaJavaV1.State getOther() {
|
|
||||||
return other;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setOther(GoodSchemaJavaV1.State other) {
|
|
||||||
this.other = other;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,29 +0,0 @@
|
|||||||
package net.corda.core.schemas;
|
|
||||||
|
|
||||||
import javax.persistence.*;
|
|
||||||
import java.util.Arrays;
|
|
||||||
|
|
||||||
public class BadSchemaNoGetterJavaV1 extends MappedSchema {
|
|
||||||
|
|
||||||
public BadSchemaNoGetterJavaV1() {
|
|
||||||
super(TestJavaSchemaFamily.class, 1, Arrays.asList(State.class));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Entity
|
|
||||||
public static class State extends PersistentState {
|
|
||||||
@JoinColumns({@JoinColumn(name = "itid"), @JoinColumn(name = "outid")})
|
|
||||||
@OneToOne
|
|
||||||
@MapsId
|
|
||||||
public GoodSchemaJavaV1.State other;
|
|
||||||
private String id;
|
|
||||||
|
|
||||||
@Column
|
|
||||||
public String getId() {
|
|
||||||
return id;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setId(String id) {
|
|
||||||
this.id = id;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
package net.corda.core.schemas;
|
|
||||||
|
|
||||||
import javax.persistence.Column;
|
|
||||||
import javax.persistence.Entity;
|
|
||||||
import java.util.Arrays;
|
|
||||||
|
|
||||||
public class GoodSchemaJavaV1 extends MappedSchema {
|
|
||||||
|
|
||||||
public GoodSchemaJavaV1() {
|
|
||||||
super(TestJavaSchemaFamily.class, 1, Arrays.asList(State.class));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Entity
|
|
||||||
public static class State extends PersistentState {
|
|
||||||
private String id;
|
|
||||||
|
|
||||||
@Column
|
|
||||||
public String getId() {
|
|
||||||
return id;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setId(String id) {
|
|
||||||
this.id = id;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,37 +0,0 @@
|
|||||||
package net.corda.core.schemas;
|
|
||||||
|
|
||||||
import javax.persistence.Column;
|
|
||||||
import javax.persistence.Entity;
|
|
||||||
import javax.persistence.Transient;
|
|
||||||
import java.util.Arrays;
|
|
||||||
|
|
||||||
public class PoliteSchemaJavaV1 extends MappedSchema {
|
|
||||||
|
|
||||||
public PoliteSchemaJavaV1() {
|
|
||||||
super(TestJavaSchemaFamily.class, 1, Arrays.asList(State.class));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Entity
|
|
||||||
public static class State extends PersistentState {
|
|
||||||
private String id;
|
|
||||||
private GoodSchemaJavaV1.State other;
|
|
||||||
|
|
||||||
@Column
|
|
||||||
public String getId() {
|
|
||||||
return id;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setId(String id) {
|
|
||||||
this.id = id;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Transient
|
|
||||||
public GoodSchemaJavaV1.State getOther() {
|
|
||||||
return other;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setOther(GoodSchemaJavaV1.State other) {
|
|
||||||
this.other = other;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,4 +0,0 @@
|
|||||||
package net.corda.core.schemas;
|
|
||||||
|
|
||||||
public class TestJavaSchemaFamily {
|
|
||||||
}
|
|
@ -1,36 +0,0 @@
|
|||||||
package net.corda.core.schemas;
|
|
||||||
|
|
||||||
import javax.persistence.Column;
|
|
||||||
import javax.persistence.Entity;
|
|
||||||
import java.util.Arrays;
|
|
||||||
|
|
||||||
public class TrickySchemaJavaV1 extends MappedSchema {
|
|
||||||
|
|
||||||
public TrickySchemaJavaV1() {
|
|
||||||
super(TestJavaSchemaFamily.class, 1, Arrays.asList(TrickySchemaJavaV1.State.class));
|
|
||||||
}
|
|
||||||
|
|
||||||
@Entity
|
|
||||||
public static class State extends PersistentState {
|
|
||||||
private String id;
|
|
||||||
private GoodSchemaJavaV1.State other;
|
|
||||||
|
|
||||||
@Column
|
|
||||||
public String getId() {
|
|
||||||
return id;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setId(String id) {
|
|
||||||
this.id = id;
|
|
||||||
}
|
|
||||||
|
|
||||||
//the field is a cross-reference to other MappedSchema however the field is not persistent (no JPA annotation)
|
|
||||||
public GoodSchemaJavaV1.State getOther() {
|
|
||||||
return other;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setOther(GoodSchemaJavaV1.State other) {
|
|
||||||
this.other = other;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,125 +0,0 @@
|
|||||||
package net.corda.core.internal
|
|
||||||
|
|
||||||
import net.corda.core.crypto.Crypto
|
|
||||||
import net.i2p.crypto.eddsa.EdDSAEngine
|
|
||||||
import net.i2p.crypto.eddsa.EdDSAPublicKey
|
|
||||||
import org.junit.Test
|
|
||||||
import sun.security.util.BitArray
|
|
||||||
import sun.security.util.ObjectIdentifier
|
|
||||||
import sun.security.x509.AlgorithmId
|
|
||||||
import sun.security.x509.X509Key
|
|
||||||
import java.math.BigInteger
|
|
||||||
import java.security.InvalidKeyException
|
|
||||||
import java.util.*
|
|
||||||
import kotlin.test.assertFailsWith
|
|
||||||
import kotlin.test.assertTrue
|
|
||||||
|
|
||||||
class TestX509Key(algorithmId: AlgorithmId, key: BitArray) : X509Key() {
|
|
||||||
init {
|
|
||||||
this.algid = algorithmId
|
|
||||||
this.setKey(key)
|
|
||||||
this.encode()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
class X509EdDSAEngineTest {
|
|
||||||
companion object {
|
|
||||||
private const val SEED = 20170920L
|
|
||||||
private const val TEST_DATA_SIZE = 2000
|
|
||||||
|
|
||||||
// offset into an EdDSA header indicating where the key header and actual key start
|
|
||||||
// in the underlying byte array
|
|
||||||
private const val keyHeaderStart = 9
|
|
||||||
private const val keyStart = 12
|
|
||||||
|
|
||||||
private fun toX509Key(publicKey: EdDSAPublicKey): X509Key {
|
|
||||||
val internals = publicKey.encoded
|
|
||||||
|
|
||||||
// key size in the header includes the count unused bits at the end of the key
|
|
||||||
// [keyHeaderStart + 2] but NOT the key header ID [keyHeaderStart] so the
|
|
||||||
// actual length of the key blob is size - 1
|
|
||||||
val keySize = (internals[keyHeaderStart + 1].toInt()) - 1
|
|
||||||
|
|
||||||
val key = ByteArray(keySize)
|
|
||||||
System.arraycopy(internals, keyStart, key, 0, keySize)
|
|
||||||
|
|
||||||
// 1.3.101.102 is the EdDSA OID
|
|
||||||
return TestX509Key(AlgorithmId(ObjectIdentifier("1.3.101.112")), BitArray(keySize * 8, key))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Put the X509EdDSA engine through basic tests to verify that the functions are hooked up correctly.
|
|
||||||
*/
|
|
||||||
@Test
|
|
||||||
fun `sign and verify`() {
|
|
||||||
val engine = X509EdDSAEngine()
|
|
||||||
val keyPair = Crypto.deriveKeyPairFromEntropy(Crypto.EDDSA_ED25519_SHA512, BigInteger.valueOf(SEED))
|
|
||||||
val publicKey = keyPair.public as EdDSAPublicKey
|
|
||||||
val randomBytes = ByteArray(TEST_DATA_SIZE)
|
|
||||||
Random(SEED).nextBytes(randomBytes)
|
|
||||||
engine.initSign(keyPair.private)
|
|
||||||
engine.update(randomBytes[0])
|
|
||||||
engine.update(randomBytes, 1, randomBytes.size - 1)
|
|
||||||
|
|
||||||
// Now verify the signature
|
|
||||||
val signature = engine.sign()
|
|
||||||
|
|
||||||
engine.initVerify(publicKey)
|
|
||||||
engine.update(randomBytes)
|
|
||||||
assertTrue { engine.verify(signature) }
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Verify that signing with an X509Key wrapped EdDSA key works.
|
|
||||||
*/
|
|
||||||
@Test
|
|
||||||
fun `sign and verify with X509Key`() {
|
|
||||||
val engine = X509EdDSAEngine()
|
|
||||||
val keyPair = Crypto.deriveKeyPairFromEntropy(Crypto.EDDSA_ED25519_SHA512, BigInteger.valueOf(SEED + 1))
|
|
||||||
val publicKey = toX509Key(keyPair.public as EdDSAPublicKey)
|
|
||||||
val randomBytes = ByteArray(TEST_DATA_SIZE)
|
|
||||||
Random(SEED + 1).nextBytes(randomBytes)
|
|
||||||
engine.initSign(keyPair.private)
|
|
||||||
engine.update(randomBytes[0])
|
|
||||||
engine.update(randomBytes, 1, randomBytes.size - 1)
|
|
||||||
|
|
||||||
// Now verify the signature
|
|
||||||
val signature = engine.sign()
|
|
||||||
|
|
||||||
engine.initVerify(publicKey)
|
|
||||||
engine.update(randomBytes)
|
|
||||||
assertTrue { engine.verify(signature) }
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Verify that signing with an X509Key wrapped EdDSA key fails when using the underlying EdDSAEngine.
|
|
||||||
*/
|
|
||||||
@Test
|
|
||||||
fun `sign and verify with X509Key and old engine fails`() {
|
|
||||||
val engine = EdDSAEngine()
|
|
||||||
val keyPair = Crypto.deriveKeyPairFromEntropy(Crypto.EDDSA_ED25519_SHA512, BigInteger.valueOf(SEED + 1))
|
|
||||||
val publicKey = toX509Key(keyPair.public as EdDSAPublicKey)
|
|
||||||
val randomBytes = ByteArray(TEST_DATA_SIZE)
|
|
||||||
Random(SEED + 1).nextBytes(randomBytes)
|
|
||||||
engine.initSign(keyPair.private)
|
|
||||||
engine.update(randomBytes[0])
|
|
||||||
engine.update(randomBytes, 1, randomBytes.size - 1)
|
|
||||||
|
|
||||||
// Now verify the signature
|
|
||||||
val signature = engine.sign()
|
|
||||||
assertFailsWith<InvalidKeyException> {
|
|
||||||
engine.initVerify(publicKey)
|
|
||||||
engine.update(randomBytes)
|
|
||||||
engine.verify(signature)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Verify will fail if the input public key cannot be converted to EdDSA public key. */
|
|
||||||
@Test
|
|
||||||
fun `verify with non-supported key type fails`() {
|
|
||||||
val engine = EdDSAEngine()
|
|
||||||
val keyPair = Crypto.deriveKeyPairFromEntropy(Crypto.ECDSA_SECP256K1_SHA256, BigInteger.valueOf(SEED))
|
|
||||||
assertFailsWith<InvalidKeyException> { engine.initVerify(keyPair.public) }
|
|
||||||
}
|
|
||||||
}
|
|
@ -0,0 +1,17 @@
|
|||||||
|
package net.corda.core.schemas
|
||||||
|
|
||||||
|
import java.util.*
|
||||||
|
import javax.persistence.*
|
||||||
|
|
||||||
|
class BadSchemaNoGetterV1 : MappedSchema(TestJavaSchemaFamily::class.java, 1, Arrays.asList(State::class.java)) {
|
||||||
|
|
||||||
|
@Entity
|
||||||
|
class State : PersistentState() {
|
||||||
|
@JoinColumns(JoinColumn(name = "itid"), JoinColumn(name = "outid"))
|
||||||
|
@OneToOne
|
||||||
|
@MapsId
|
||||||
|
var other: GoodSchemaV1.State? = null
|
||||||
|
@get:Column
|
||||||
|
var id: String? = null
|
||||||
|
}
|
||||||
|
}
|
17
core/src/test/kotlin/net/corda/core/schemas/BadSchemaV1.kt
Normal file
17
core/src/test/kotlin/net/corda/core/schemas/BadSchemaV1.kt
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
package net.corda.core.schemas
|
||||||
|
|
||||||
|
import java.util.*
|
||||||
|
import javax.persistence.*
|
||||||
|
|
||||||
|
class BadSchemaV1 : MappedSchema(TestJavaSchemaFamily::class.java, 1, Arrays.asList(State::class.java)) {
|
||||||
|
|
||||||
|
@Entity
|
||||||
|
class State : PersistentState() {
|
||||||
|
@get:Column
|
||||||
|
var id: String? = null
|
||||||
|
@get:JoinColumns(JoinColumn(name = "itid"), JoinColumn(name = "outid"))
|
||||||
|
@get:OneToOne
|
||||||
|
@get:MapsId
|
||||||
|
var other: GoodSchemaV1.State? = null
|
||||||
|
}
|
||||||
|
}
|
14
core/src/test/kotlin/net/corda/core/schemas/GoodSchemaV1.kt
Normal file
14
core/src/test/kotlin/net/corda/core/schemas/GoodSchemaV1.kt
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
package net.corda.core.schemas
|
||||||
|
|
||||||
|
import java.util.*
|
||||||
|
import javax.persistence.Column
|
||||||
|
import javax.persistence.Entity
|
||||||
|
|
||||||
|
class GoodSchemaV1 : MappedSchema(TestJavaSchemaFamily::class.java, 1, Arrays.asList(State::class.java)) {
|
||||||
|
|
||||||
|
@Entity
|
||||||
|
class State : PersistentState() {
|
||||||
|
@get:Column
|
||||||
|
var id: String? = null
|
||||||
|
}
|
||||||
|
}
|
@ -78,31 +78,31 @@ class MappedSchemasCrossReferenceDetectionTests {
|
|||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun `no cross reference to other schema java`() {
|
fun `no cross reference to other schema java`() {
|
||||||
assertThat(fieldsFromOtherMappedSchema(GoodSchemaJavaV1())).isEmpty()
|
assertThat(fieldsFromOtherMappedSchema(GoodSchemaV1())).isEmpty()
|
||||||
assertThat(methodsFromOtherMappedSchema(GoodSchemaJavaV1())).isEmpty()
|
assertThat(methodsFromOtherMappedSchema(GoodSchemaV1())).isEmpty()
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun `cross reference to other schema is detected java`() {
|
fun `cross reference to other schema is detected java`() {
|
||||||
assertThat(fieldsFromOtherMappedSchema(BadSchemaJavaV1())).isEmpty()
|
assertThat(fieldsFromOtherMappedSchema(BadSchemaV1())).isEmpty()
|
||||||
assertThat(methodsFromOtherMappedSchema(BadSchemaJavaV1())).isNotEmpty
|
assertThat(methodsFromOtherMappedSchema(BadSchemaV1())).isNotEmpty
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun `cross reference to other schema via field is detected java`() {
|
fun `cross reference to other schema via field is detected java`() {
|
||||||
assertThat(fieldsFromOtherMappedSchema(BadSchemaNoGetterJavaV1())).isNotEmpty
|
assertThat(fieldsFromOtherMappedSchema(BadSchemaNoGetterV1())).isNotEmpty
|
||||||
assertThat(methodsFromOtherMappedSchema(BadSchemaNoGetterJavaV1())).isEmpty()
|
assertThat(methodsFromOtherMappedSchema(BadSchemaNoGetterV1())).isEmpty()
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun `cross reference via non JPA field is allowed java`() {
|
fun `cross reference via non JPA field is allowed java`() {
|
||||||
assertThat(fieldsFromOtherMappedSchema(TrickySchemaJavaV1())).isEmpty()
|
assertThat(fieldsFromOtherMappedSchema(TrickySchemaV1())).isEmpty()
|
||||||
assertThat(methodsFromOtherMappedSchema(TrickySchemaJavaV1())).isEmpty()
|
assertThat(methodsFromOtherMappedSchema(TrickySchemaV1())).isEmpty()
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
fun `cross reference via transient field is allowed java`() {
|
fun `cross reference via transient field is allowed java`() {
|
||||||
assertThat(fieldsFromOtherMappedSchema(PoliteSchemaJavaV1())).isEmpty()
|
assertThat(fieldsFromOtherMappedSchema(PoliteSchemaV1())).isEmpty()
|
||||||
assertThat(methodsFromOtherMappedSchema(PoliteSchemaJavaV1())).isEmpty()
|
assertThat(methodsFromOtherMappedSchema(PoliteSchemaV1())).isEmpty()
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -0,0 +1,17 @@
|
|||||||
|
package net.corda.core.schemas
|
||||||
|
|
||||||
|
import java.util.*
|
||||||
|
import javax.persistence.Column
|
||||||
|
import javax.persistence.Entity
|
||||||
|
import javax.persistence.Transient
|
||||||
|
|
||||||
|
class PoliteSchemaV1 : MappedSchema(TestJavaSchemaFamily::class.java, 1, Arrays.asList(State::class.java)) {
|
||||||
|
|
||||||
|
@Entity
|
||||||
|
class State : PersistentState() {
|
||||||
|
@get:Column
|
||||||
|
var id: String? = null
|
||||||
|
@get:Transient
|
||||||
|
var other: GoodSchemaV1.State? = null
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,3 @@
|
|||||||
|
package net.corda.core.schemas
|
||||||
|
|
||||||
|
class TestJavaSchemaFamily
|
@ -0,0 +1,16 @@
|
|||||||
|
package net.corda.core.schemas
|
||||||
|
|
||||||
|
import java.util.*
|
||||||
|
import javax.persistence.Column
|
||||||
|
import javax.persistence.Entity
|
||||||
|
|
||||||
|
class TrickySchemaV1 : MappedSchema(TestJavaSchemaFamily::class.java, 1, Arrays.asList(TrickySchemaV1.State::class.java)) {
|
||||||
|
|
||||||
|
@Entity
|
||||||
|
class State : PersistentState() {
|
||||||
|
@get:Column
|
||||||
|
var id: String? = null
|
||||||
|
//the field is a cross-reference to other MappedSchema however the field is not persistent (no JPA annotation)
|
||||||
|
var other: GoodSchemaV1.State? = null
|
||||||
|
}
|
||||||
|
}
|
@ -1,5 +1,5 @@
|
|||||||
kotlin.incremental=true
|
kotlin.incremental=true
|
||||||
org.gradle.jvmargs=-XX:+UseG1GC -Xmx1g -Dfile.encoding=UTF-8
|
org.gradle.jvmargs=-XX:+UseG1GC -Xmx1g -Dfile.encoding=UTF-8 --illegal-access=warn
|
||||||
org.gradle.caching=false
|
org.gradle.caching=false
|
||||||
owasp.failOnError=false
|
owasp.failOnError=false
|
||||||
owasp.failBuildOnCVSS=11.0
|
owasp.failBuildOnCVSS=11.0
|
||||||
|
BIN
lib/quasar.jar
BIN
lib/quasar.jar
Binary file not shown.
@ -59,6 +59,20 @@ configurations {
|
|||||||
testArtifacts.extendsFrom testRuntimeClasspath
|
testArtifacts.extendsFrom testRuntimeClasspath
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tasks.withType(Test) {
|
||||||
|
// jvmArgs '-Djava.security.debug=provider'
|
||||||
|
jvmArgs
|
||||||
|
//'-Xbootclasspath/jar:/Users/josecoll/IdeaProjects/corda-jdk11/lib/patch.jar'
|
||||||
|
//'--list-modules'
|
||||||
|
// '--patch-module=java.base=/Users/josecoll/IdeaProjects/corda-jdk11/lib/java.base.jmod'
|
||||||
|
// '--list-modules'
|
||||||
|
// '--upgrade-module-path=/Users/josecoll/IdeaProjects/corda-jdk11/lib ' +
|
||||||
|
// '-Xbootclasspath/p:/Users/josecoll/IdeaProjects/corda-jdk11/lib/java.base.jmod '
|
||||||
|
|
||||||
|
// compile time option only:
|
||||||
|
// '--system /Users/josecoll/IdeaProjects/jdk11/build/macosx-x86_64-normal-server-release/images/jdk ' //<<
|
||||||
|
}
|
||||||
|
|
||||||
task testJar(type: Jar) {
|
task testJar(type: Jar) {
|
||||||
classifier "tests"
|
classifier "tests"
|
||||||
from sourceSets.test.output
|
from sourceSets.test.output
|
||||||
|
@ -6,7 +6,6 @@ import net.corda.core.utilities.contextLogger
|
|||||||
import net.corda.nodeapi.internal.config.CertificateStore
|
import net.corda.nodeapi.internal.config.CertificateStore
|
||||||
import net.corda.nodeapi.internal.protonwrapper.netty.init
|
import net.corda.nodeapi.internal.protonwrapper.netty.init
|
||||||
import org.assertj.core.api.Assertions
|
import org.assertj.core.api.Assertions
|
||||||
import org.junit.Ignore
|
|
||||||
import org.junit.Rule
|
import org.junit.Rule
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
import org.junit.rules.TemporaryFolder
|
import org.junit.rules.TemporaryFolder
|
||||||
@ -29,7 +28,6 @@ import javax.net.ssl.StandardConstants
|
|||||||
/**
|
/**
|
||||||
* This test checks compatibility of TLS 1.2 and 1.3 communication using different cipher suites with SNI header
|
* This test checks compatibility of TLS 1.2 and 1.3 communication using different cipher suites with SNI header
|
||||||
*/
|
*/
|
||||||
@Ignore("Disabled till we switched to Java 11 where TLS 1.3 becomes available")
|
|
||||||
@RunWith(Parameterized::class)
|
@RunWith(Parameterized::class)
|
||||||
class TlsDiffProtocolsTest(private val serverAlgo: String, private val clientAlgo: String,
|
class TlsDiffProtocolsTest(private val serverAlgo: String, private val clientAlgo: String,
|
||||||
private val cipherSuites: CipherSuites, private val shouldFail: Boolean,
|
private val cipherSuites: CipherSuites, private val shouldFail: Boolean,
|
||||||
@ -70,7 +68,9 @@ class TlsDiffProtocolsTest(private val serverAlgo: String, private val clientAlg
|
|||||||
CIPHER_SUITES_ALL(arrayOf(
|
CIPHER_SUITES_ALL(arrayOf(
|
||||||
// 1.3 only
|
// 1.3 only
|
||||||
"TLS_AES_128_GCM_SHA256",
|
"TLS_AES_128_GCM_SHA256",
|
||||||
"TLS_CHACHA20_POLY1305_SHA256",
|
// Unsupported CipherSuite: TLS_CHACHA20_POLY1305_SHA256 (java version "11.0.2" 2019-01-15 LTS)
|
||||||
|
// Works with: openjdk version "12.0.1" 2019-04-16 (OpenJDK Runtime Environment (build 12.0.1+12))
|
||||||
|
// "TLS_CHACHA20_POLY1305_SHA256",
|
||||||
// 1.2 only
|
// 1.2 only
|
||||||
"TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256",
|
"TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256",
|
||||||
"TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256"
|
"TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256"
|
||||||
|
@ -40,7 +40,7 @@ import org.bouncycastle.pqc.jcajce.provider.sphincs.BCSphincs256PrivateKey
|
|||||||
import org.junit.Rule
|
import org.junit.Rule
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
import org.junit.rules.TemporaryFolder
|
import org.junit.rules.TemporaryFolder
|
||||||
import sun.security.rsa.RSAPrivateCrtKeyImpl
|
//import sun.security.rsa.RSAPrivateCrtKeyImpl
|
||||||
import java.io.DataInputStream
|
import java.io.DataInputStream
|
||||||
import java.io.DataOutputStream
|
import java.io.DataOutputStream
|
||||||
import java.io.IOException
|
import java.io.IOException
|
||||||
@ -86,7 +86,7 @@ class X509UtilitiesTest {
|
|||||||
Triple(ECDSA_SECP256K1_SHA256,java.security.interfaces.ECPrivateKey::class.java, org.bouncycastle.jce.interfaces.ECPrivateKey::class.java),
|
Triple(ECDSA_SECP256K1_SHA256,java.security.interfaces.ECPrivateKey::class.java, org.bouncycastle.jce.interfaces.ECPrivateKey::class.java),
|
||||||
Triple(EDDSA_ED25519_SHA512, EdDSAPrivateKey::class.java, EdDSAPrivateKey::class.java),
|
Triple(EDDSA_ED25519_SHA512, EdDSAPrivateKey::class.java, EdDSAPrivateKey::class.java),
|
||||||
// By default, JKS returns SUN RSA key.
|
// By default, JKS returns SUN RSA key.
|
||||||
Triple(RSA_SHA256, RSAPrivateCrtKeyImpl::class.java, BCRSAPrivateCrtKey::class.java),
|
// Triple(RSA_SHA256, RSAPrivateCrtKeyImpl::class.java, BCRSAPrivateCrtKey::class.java),
|
||||||
Triple(SPHINCS256_SHA256, BCSphincs256PrivateKey::class.java, BCSphincs256PrivateKey::class.java)
|
Triple(SPHINCS256_SHA256, BCSphincs256PrivateKey::class.java, BCSphincs256PrivateKey::class.java)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -8,6 +8,7 @@ buildscript {
|
|||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
id 'com.google.cloud.tools.jib' version '0.9.4'
|
id 'com.google.cloud.tools.jib' version '0.9.4'
|
||||||
|
id 'org.javamodularity.moduleplugin' version '1.5.0' apply true
|
||||||
}
|
}
|
||||||
|
|
||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
@ -19,6 +20,9 @@ apply plugin: 'net.corda.plugins.quasar-utils'
|
|||||||
apply plugin: 'net.corda.plugins.publish-utils'
|
apply plugin: 'net.corda.plugins.publish-utils'
|
||||||
apply plugin: 'com.jfrog.artifactory'
|
apply plugin: 'com.jfrog.artifactory'
|
||||||
|
|
||||||
|
// CordaCaplet using 'sun.misc.Signal'
|
||||||
|
apply plugin: "org.javamodularity.moduleplugin"
|
||||||
|
|
||||||
description 'Corda node modules'
|
description 'Corda node modules'
|
||||||
|
|
||||||
//noinspection GroovyAssignabilityCheck
|
//noinspection GroovyAssignabilityCheck
|
||||||
@ -49,7 +53,7 @@ jib.container {
|
|||||||
mainClass = "net.corda.node.Corda"
|
mainClass = "net.corda.node.Corda"
|
||||||
args = ['--log-to-console', '--no-local-shell', '--config-file=/config/node.conf']
|
args = ['--log-to-console', '--no-local-shell', '--config-file=/config/node.conf']
|
||||||
// The Groovy string needs to be converted to a `java.lang.String` below.
|
// The Groovy string needs to be converted to a `java.lang.String` below.
|
||||||
jvmFlags = ['-Xmx1g', "-javaagent:/app/libs/quasar-core-${quasar_version}-jdk8.jar".toString()]
|
jvmFlags = ['-Xmx1g', "-javaagent:/app/libs/quasar-core-${quasar_version}.jar".toString()]
|
||||||
}
|
}
|
||||||
|
|
||||||
// Use manual resource copying of log4j2.xml rather than source sets.
|
// Use manual resource copying of log4j2.xml rather than source sets.
|
||||||
@ -209,7 +213,16 @@ dependencies {
|
|||||||
|
|
||||||
tasks.withType(JavaCompile) {
|
tasks.withType(JavaCompile) {
|
||||||
// Resolves a Gradle warning about not scanning for pre-processors.
|
// Resolves a Gradle warning about not scanning for pre-processors.
|
||||||
options.compilerArgs << '-proc:none'
|
options.compilerArgs << '-proc:none' << '--add-exports' << 'java.unsupported/sun.misc=ALL-UNNAMED' << '--add-exports' << 'java.base/sun.security.util=ALL-UNNAMED' << '--add-exports' << 'java.base/sun.security.x509=ALL-UNNAMED'
|
||||||
|
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.unsupported/sun.misc.Unsafe': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
|
||||||
|
// jvmArgs('--add-exports', 'java.unsupported/sun.misc.Unsafe=ALL-UNNAMED')
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.withType(Test) {
|
tasks.withType(Test) {
|
||||||
|
@ -51,7 +51,7 @@ task buildCordaJAR(type: FatCapsule, dependsOn: project(':node').tasks.jar) {
|
|||||||
applicationId = "net.corda.node.Corda"
|
applicationId = "net.corda.node.Corda"
|
||||||
// See experimental/quasar-hook/README.md for how to generate.
|
// See experimental/quasar-hook/README.md for how to generate.
|
||||||
def quasarExcludeExpression = "x(antlr**;bftsmart**;co.paralleluniverse**;com.codahale**;com.esotericsoftware**;com.fasterxml**;com.google**;com.ibm**;com.intellij**;com.jcabi**;com.nhaarman**;com.opengamma**;com.typesafe**;com.zaxxer**;de.javakaffee**;groovy**;groovyjarjarantlr**;groovyjarjarasm**;io.atomix**;io.github**;io.netty**;jdk**;junit**;kotlin**;net.bytebuddy**;net.i2p**;org.apache**;org.assertj**;org.bouncycastle**;org.codehaus**;org.crsh**;org.dom4j**;org.fusesource**;org.h2**;org.hamcrest**;org.hibernate**;org.jboss**;org.jcp**;org.joda**;org.junit**;org.mockito**;org.objectweb**;org.objenesis**;org.slf4j**;org.w3c**;org.xml**;org.yaml**;reflectasm**;rx**;org.jolokia**;com.lmax**;picocli**;liquibase**;com.github.benmanes**;org.json**;org.postgresql**;nonapi.io.github.classgraph**)"
|
def quasarExcludeExpression = "x(antlr**;bftsmart**;co.paralleluniverse**;com.codahale**;com.esotericsoftware**;com.fasterxml**;com.google**;com.ibm**;com.intellij**;com.jcabi**;com.nhaarman**;com.opengamma**;com.typesafe**;com.zaxxer**;de.javakaffee**;groovy**;groovyjarjarantlr**;groovyjarjarasm**;io.atomix**;io.github**;io.netty**;jdk**;junit**;kotlin**;net.bytebuddy**;net.i2p**;org.apache**;org.assertj**;org.bouncycastle**;org.codehaus**;org.crsh**;org.dom4j**;org.fusesource**;org.h2**;org.hamcrest**;org.hibernate**;org.jboss**;org.jcp**;org.joda**;org.junit**;org.mockito**;org.objectweb**;org.objenesis**;org.slf4j**;org.w3c**;org.xml**;org.yaml**;reflectasm**;rx**;org.jolokia**;com.lmax**;picocli**;liquibase**;com.github.benmanes**;org.json**;org.postgresql**;nonapi.io.github.classgraph**)"
|
||||||
javaAgents = ["quasar-core-${quasar_version}-jdk8.jar=${quasarExcludeExpression}"]
|
javaAgents = ["quasar-core-${quasar_version}.jar=${quasarExcludeExpression}"]
|
||||||
systemProperties['visualvm.display.name'] = 'Corda'
|
systemProperties['visualvm.display.name'] = 'Corda'
|
||||||
minJavaVersion = '1.8.0'
|
minJavaVersion = '1.8.0'
|
||||||
minUpdateVersion['1.8'] = java8_minUpdateVersion
|
minUpdateVersion['1.8'] = java8_minUpdateVersion
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
// trying to construct this from Capsule, so it is written in Java.
|
// trying to construct this from Capsule, so it is written in Java.
|
||||||
|
|
||||||
import com.typesafe.config.*;
|
import com.typesafe.config.*;
|
||||||
import sun.misc.Signal;
|
//import sun.misc.Signal;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.nio.file.Path;
|
import java.nio.file.Path;
|
||||||
@ -173,8 +173,8 @@ public class CordaCaplet extends Capsule {
|
|||||||
|
|
||||||
private static void checkJavaVersion() {
|
private static void checkJavaVersion() {
|
||||||
String version = System.getProperty("java.version");
|
String version = System.getProperty("java.version");
|
||||||
if (version == null || !version.startsWith("1.8")) {
|
if (version == null || Arrays.asList("1.8", "11").stream().noneMatch(version::startsWith)) {
|
||||||
System.err.printf("Error: Unsupported Java version %s; currently only version 1.8 is supported.\n", version);
|
System.err.printf("Error: Unsupported Java version %s; currently only version 1.8 or 11 is supported.\n", version);
|
||||||
System.exit(1);
|
System.exit(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -216,9 +216,9 @@ public class CordaCaplet extends Capsule {
|
|||||||
@Override
|
@Override
|
||||||
protected void liftoff() {
|
protected void liftoff() {
|
||||||
super.liftoff();
|
super.liftoff();
|
||||||
Signal.handle(new Signal("INT"), signal -> {
|
// Signal.handle(new Signal("INT"), signal -> {
|
||||||
// Disable Ctrl-C for this process, so the child process can handle it in the shell instead.
|
// // Disable Ctrl-C for this process, so the child process can handle it in the shell instead.
|
||||||
});
|
// });
|
||||||
}
|
}
|
||||||
|
|
||||||
private Boolean isJAR(File file) {
|
private Boolean isJAR(File file) {
|
||||||
|
@ -17,7 +17,6 @@ import net.corda.core.internal.concurrent.openFuture
|
|||||||
import net.corda.core.internal.concurrent.thenMatch
|
import net.corda.core.internal.concurrent.thenMatch
|
||||||
import net.corda.core.internal.div
|
import net.corda.core.internal.div
|
||||||
import net.corda.core.internal.errors.AddressBindingException
|
import net.corda.core.internal.errors.AddressBindingException
|
||||||
import net.corda.core.internal.getJavaUpdateVersion
|
|
||||||
import net.corda.core.internal.notary.NotaryService
|
import net.corda.core.internal.notary.NotaryService
|
||||||
import net.corda.core.messaging.CordaRPCOps
|
import net.corda.core.messaging.CordaRPCOps
|
||||||
import net.corda.core.messaging.RPCOps
|
import net.corda.core.messaging.RPCOps
|
||||||
@ -155,14 +154,8 @@ open class Node(configuration: NodeConfiguration,
|
|||||||
}
|
}
|
||||||
|
|
||||||
private fun hasMinimumJavaVersion(): Boolean {
|
private fun hasMinimumJavaVersion(): Boolean {
|
||||||
// when the ext.java8_minUpdateVersion gradle constant changes, so must this check
|
// JDK 11: review naming convention and checking of 'minUpdateVersion' and 'distributionType` (OpenJDK, Oracle, Zulu, AdoptOpenJDK, Cornetto)
|
||||||
val major = SystemUtils.JAVA_VERSION_FLOAT
|
return Runtime.version().feature() >= 11
|
||||||
return try {
|
|
||||||
val update = getJavaUpdateVersion(SystemUtils.JAVA_VERSION) // To filter out cases like 1.8.0_202-ea
|
|
||||||
major == 1.8F && update >= 171
|
|
||||||
} catch (e: NumberFormatException) { // custom JDKs may not have the update version (e.g. 1.8.0-adoptopenjdk)
|
|
||||||
false
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ import net.corda.tools.shell.InteractiveShell
|
|||||||
import org.fusesource.jansi.Ansi
|
import org.fusesource.jansi.Ansi
|
||||||
import org.slf4j.bridge.SLF4JBridgeHandler
|
import org.slf4j.bridge.SLF4JBridgeHandler
|
||||||
import picocli.CommandLine.Mixin
|
import picocli.CommandLine.Mixin
|
||||||
import sun.misc.VMSupport
|
//import sun.misc.VMSupport
|
||||||
import java.io.IOException
|
import java.io.IOException
|
||||||
import java.io.RandomAccessFile
|
import java.io.RandomAccessFile
|
||||||
import java.lang.management.ManagementFactory
|
import java.lang.management.ManagementFactory
|
||||||
@ -246,15 +246,16 @@ open class NodeStartup : NodeStartupLogging {
|
|||||||
logger.info("PID: ${info.name.split("@").firstOrNull()}") // TODO Java 9 has better support for this
|
logger.info("PID: ${info.name.split("@").firstOrNull()}") // TODO Java 9 has better support for this
|
||||||
logger.info("Main class: ${NodeConfiguration::class.java.location.toURI().path}")
|
logger.info("Main class: ${NodeConfiguration::class.java.location.toURI().path}")
|
||||||
logger.info("CommandLine Args: ${info.inputArguments.joinToString(" ")}")
|
logger.info("CommandLine Args: ${info.inputArguments.joinToString(" ")}")
|
||||||
logger.info("bootclasspath: ${info.bootClassPath}")
|
// JDK 11 (bootclasspath no longer supported from JDK 9)
|
||||||
|
if (info.isBootClassPathSupported) logger.info("bootclasspath: ${info.bootClassPath}")
|
||||||
logger.info("classpath: ${info.classPath}")
|
logger.info("classpath: ${info.classPath}")
|
||||||
logger.info("VM ${info.vmName} ${info.vmVendor} ${info.vmVersion}")
|
logger.info("VM ${info.vmName} ${info.vmVendor} ${info.vmVersion}")
|
||||||
logger.info("Machine: ${lookupMachineNameAndMaybeWarn()}")
|
logger.info("Machine: ${lookupMachineNameAndMaybeWarn()}")
|
||||||
logger.info("Working Directory: ${cmdLineOptions.baseDirectory}")
|
logger.info("Working Directory: ${cmdLineOptions.baseDirectory}")
|
||||||
val agentProperties = VMSupport.getAgentProperties()
|
// val agentProperties = VMSupport.getAgentProperties()
|
||||||
if (agentProperties.containsKey("sun.jdwp.listenerAddress")) {
|
// if (agentProperties.containsKey("sun.jdwp.listenerAddress")) {
|
||||||
logger.info("Debug port: ${agentProperties.getProperty("sun.jdwp.listenerAddress")}")
|
// logger.info("Debug port: ${agentProperties.getProperty("sun.jdwp.listenerAddress")}")
|
||||||
}
|
// }
|
||||||
var nodeStartedMessage = "Starting as node on ${conf.p2pAddress}"
|
var nodeStartedMessage = "Starting as node on ${conf.p2pAddress}"
|
||||||
if (conf.extraNetworkMapKeys.isNotEmpty()) {
|
if (conf.extraNetworkMapKeys.isNotEmpty()) {
|
||||||
nodeStartedMessage = "$nodeStartedMessage with additional Network Map keys ${conf.extraNetworkMapKeys.joinToString(prefix = "[", postfix = "]", separator = ", ")}"
|
nodeStartedMessage = "$nodeStartedMessage with additional Network Map keys ${conf.extraNetworkMapKeys.joinToString(prefix = "[", postfix = "]", separator = ", ")}"
|
||||||
|
@ -22,7 +22,6 @@ import net.corda.nodeapi.internal.network.NETWORK_PARAMS_FILE_NAME
|
|||||||
import net.corda.nodeapi.internal.network.SignedNetworkParameters
|
import net.corda.nodeapi.internal.network.SignedNetworkParameters
|
||||||
import net.corda.nodeapi.internal.persistence.CordaPersistence
|
import net.corda.nodeapi.internal.persistence.CordaPersistence
|
||||||
import net.corda.nodeapi.internal.persistence.SchemaMigration
|
import net.corda.nodeapi.internal.persistence.SchemaMigration
|
||||||
import sun.reflect.generics.reflectiveObjects.NotImplementedException
|
|
||||||
import java.nio.file.Paths
|
import java.nio.file.Paths
|
||||||
import java.time.Clock
|
import java.time.Clock
|
||||||
import java.time.Duration
|
import java.time.Duration
|
||||||
@ -44,11 +43,11 @@ class MigrationServicesForResolution(
|
|||||||
val cordappLoader = SchemaMigration.loader.get()
|
val cordappLoader = SchemaMigration.loader.get()
|
||||||
|
|
||||||
override fun getAppContext(): CordappContext {
|
override fun getAppContext(): CordappContext {
|
||||||
throw NotImplementedException()
|
TODO("not implemented")
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun getContractAttachmentID(contractClassName: ContractClassName): AttachmentId? {
|
override fun getContractAttachmentID(contractClassName: ContractClassName): AttachmentId? {
|
||||||
throw NotImplementedException()
|
TODO("not implemented")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private val cordappLoader = SchemaMigration.loader.get()
|
private val cordappLoader = SchemaMigration.loader.get()
|
||||||
|
@ -42,8 +42,8 @@ import org.objenesis.instantiator.ObjectInstantiator
|
|||||||
import org.objenesis.strategy.InstantiatorStrategy
|
import org.objenesis.strategy.InstantiatorStrategy
|
||||||
import org.objenesis.strategy.StdInstantiatorStrategy
|
import org.objenesis.strategy.StdInstantiatorStrategy
|
||||||
import org.slf4j.Logger
|
import org.slf4j.Logger
|
||||||
import sun.security.ec.ECPublicKeyImpl
|
//import sun.security.ec.ECPublicKeyImpl
|
||||||
import sun.security.provider.certpath.X509CertPath
|
//import sun.security.provider.certpath.X509CertPath
|
||||||
import java.io.BufferedInputStream
|
import java.io.BufferedInputStream
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.FileInputStream
|
import java.io.FileInputStream
|
||||||
@ -97,7 +97,7 @@ object DefaultKryoCustomizer {
|
|||||||
register(BufferedInputStream::class.java, InputStreamSerializer)
|
register(BufferedInputStream::class.java, InputStreamSerializer)
|
||||||
register(Class.forName("sun.net.www.protocol.jar.JarURLConnection\$JarURLInputStream"), InputStreamSerializer)
|
register(Class.forName("sun.net.www.protocol.jar.JarURLConnection\$JarURLInputStream"), InputStreamSerializer)
|
||||||
noReferencesWithin<WireTransaction>()
|
noReferencesWithin<WireTransaction>()
|
||||||
register(ECPublicKeyImpl::class.java, publicKeySerializer)
|
// register(ECPublicKeyImpl::class.java, publicKeySerializer)
|
||||||
register(EdDSAPublicKey::class.java, publicKeySerializer)
|
register(EdDSAPublicKey::class.java, publicKeySerializer)
|
||||||
register(EdDSAPrivateKey::class.java, PrivateKeySerializer)
|
register(EdDSAPrivateKey::class.java, PrivateKeySerializer)
|
||||||
register(CompositeKey::class.java, publicKeySerializer) // Using a custom serializer for compactness
|
register(CompositeKey::class.java, publicKeySerializer) // Using a custom serializer for compactness
|
||||||
@ -109,7 +109,7 @@ object DefaultKryoCustomizer {
|
|||||||
register(Class::class.java, ClassSerializer)
|
register(Class::class.java, ClassSerializer)
|
||||||
register(FileInputStream::class.java, InputStreamSerializer)
|
register(FileInputStream::class.java, InputStreamSerializer)
|
||||||
register(CertPath::class.java, CertPathSerializer)
|
register(CertPath::class.java, CertPathSerializer)
|
||||||
register(X509CertPath::class.java, CertPathSerializer)
|
// register(X509CertPath::class.java, CertPathSerializer)
|
||||||
register(BCECPrivateKey::class.java, PrivateKeySerializer)
|
register(BCECPrivateKey::class.java, PrivateKeySerializer)
|
||||||
register(BCECPublicKey::class.java, publicKeySerializer)
|
register(BCECPublicKey::class.java, publicKeySerializer)
|
||||||
register(BCRSAPrivateCrtKey::class.java, PrivateKeySerializer)
|
register(BCRSAPrivateCrtKey::class.java, PrivateKeySerializer)
|
||||||
|
@ -24,6 +24,7 @@ import net.corda.testing.internal.createNodeInfoAndSigned
|
|||||||
import net.corda.testing.internal.rigorousMock
|
import net.corda.testing.internal.rigorousMock
|
||||||
import net.corda.testing.node.MockServices.Companion.makeTestDataSourceProperties
|
import net.corda.testing.node.MockServices.Companion.makeTestDataSourceProperties
|
||||||
import org.assertj.core.api.Assertions.assertThat
|
import org.assertj.core.api.Assertions.assertThat
|
||||||
|
import org.junit.Ignore
|
||||||
import org.junit.Rule
|
import org.junit.Rule
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
import org.junit.rules.TemporaryFolder
|
import org.junit.rules.TemporaryFolder
|
||||||
@ -143,6 +144,14 @@ class NodeTest {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// JDK 11 check
|
||||||
|
@Test
|
||||||
|
fun `test getJavaRuntimeVersion`() {
|
||||||
|
assertThat(Runtime.version().feature()).isEqualTo(11)
|
||||||
|
}
|
||||||
|
|
||||||
|
// JDK11: revisit (JDK 9+ uses different numbering scheme: see https://docs.oracle.com/javase/9/docs/api/java/lang/Runtime.Version.html)
|
||||||
|
@Ignore
|
||||||
@Test
|
@Test
|
||||||
fun `test getJavaUpdateVersion`() {
|
fun `test getJavaUpdateVersion`() {
|
||||||
assertThat(getJavaUpdateVersion("1.8.0_202-ea")).isEqualTo(202)
|
assertThat(getJavaUpdateVersion("1.8.0_202-ea")).isEqualTo(202)
|
||||||
|
@ -354,7 +354,7 @@ class KryoTests(private val compression: CordaSerializationEncoding?) {
|
|||||||
val uncompressedSize = obj.checkpointSerialize(context.withEncoding(null)).size
|
val uncompressedSize = obj.checkpointSerialize(context.withEncoding(null)).size
|
||||||
val compressedSize = obj.checkpointSerialize(context.withEncoding(CordaSerializationEncoding.SNAPPY)).size
|
val compressedSize = obj.checkpointSerialize(context.withEncoding(CordaSerializationEncoding.SNAPPY)).size
|
||||||
// If these need fixing, sounds like Kryo wire format changed and checkpoints might not surive an upgrade.
|
// If these need fixing, sounds like Kryo wire format changed and checkpoints might not surive an upgrade.
|
||||||
assertEquals(20222, uncompressedSize)
|
assertEquals(20172, uncompressedSize)
|
||||||
assertEquals(1111, compressedSize)
|
assertEquals(1111, compressedSize)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -4,7 +4,6 @@ import com.nhaarman.mockito_kotlin.any
|
|||||||
import com.nhaarman.mockito_kotlin.mock
|
import com.nhaarman.mockito_kotlin.mock
|
||||||
import com.nhaarman.mockito_kotlin.times
|
import com.nhaarman.mockito_kotlin.times
|
||||||
import com.nhaarman.mockito_kotlin.verify
|
import com.nhaarman.mockito_kotlin.verify
|
||||||
import com.sun.xml.internal.messaging.saaj.util.ByteOutputStream
|
|
||||||
import net.corda.core.crypto.SecureHash
|
import net.corda.core.crypto.SecureHash
|
||||||
import net.corda.core.internal.SignedDataWithCert
|
import net.corda.core.internal.SignedDataWithCert
|
||||||
import net.corda.core.node.NetworkParameters
|
import net.corda.core.node.NetworkParameters
|
||||||
@ -26,6 +25,7 @@ import org.junit.After
|
|||||||
import org.junit.Before
|
import org.junit.Before
|
||||||
import org.junit.Rule
|
import org.junit.Rule
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.PrintStream
|
import java.io.PrintStream
|
||||||
import kotlin.streams.toList
|
import kotlin.streams.toList
|
||||||
|
|
||||||
@ -100,6 +100,7 @@ class DBNetworkParametersStorageTest {
|
|||||||
database.transaction {
|
database.transaction {
|
||||||
val consoleOutput = interceptConsoleOutput {
|
val consoleOutput = interceptConsoleOutput {
|
||||||
networkParametersService.lookup(hash3)
|
networkParametersService.lookup(hash3)
|
||||||
|
System.out.println()
|
||||||
}
|
}
|
||||||
assertThat(consoleOutput).anySatisfy {
|
assertThat(consoleOutput).anySatisfy {
|
||||||
it.contains("Caused by: java.security.cert.CertPathValidatorException: subject/issuer name chaining check failed")
|
it.contains("Caused by: java.security.cert.CertPathValidatorException: subject/issuer name chaining check failed")
|
||||||
@ -109,11 +110,11 @@ class DBNetworkParametersStorageTest {
|
|||||||
|
|
||||||
private fun interceptConsoleOutput(block: () -> Unit): List<String> {
|
private fun interceptConsoleOutput(block: () -> Unit): List<String> {
|
||||||
val oldOut = System.out
|
val oldOut = System.out
|
||||||
val out = ByteOutputStream()
|
val out = ByteArrayOutputStream()
|
||||||
System.setOut(PrintStream(out))
|
System.setOut(PrintStream(out))
|
||||||
block()
|
block()
|
||||||
System.setOut(oldOut)
|
System.setOut(oldOut)
|
||||||
return out.bytes.inputStream().bufferedReader().lines().toList()
|
return out.toByteArray().inputStream().bufferedReader().lines().toList()
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun createMockNetworkMapClient(): NetworkMapClient {
|
private fun createMockNetworkMapClient(): NetworkMapClient {
|
||||||
|
@ -31,7 +31,7 @@ dependencies {
|
|||||||
// The SIMM demo CorDapp depends upon Cash CorDapp features
|
// The SIMM demo CorDapp depends upon Cash CorDapp features
|
||||||
cordapp project(':finance:contracts')
|
cordapp project(':finance:contracts')
|
||||||
cordapp project(':finance:workflows')
|
cordapp project(':finance:workflows')
|
||||||
cordapp project(path: ':samples:simm-valuation-demo:contracts-states', configuration: 'shrinkArtifacts')
|
cordapp project(':samples:simm-valuation-demo:contracts-states')
|
||||||
cordapp project(':samples:simm-valuation-demo:flows')
|
cordapp project(':samples:simm-valuation-demo:flows')
|
||||||
|
|
||||||
// Corda integration dependencies
|
// Corda integration dependencies
|
||||||
|
@ -87,7 +87,8 @@ task sign(type: net.corda.plugins.SignJar) {
|
|||||||
inputJars shrink
|
inputJars shrink
|
||||||
}
|
}
|
||||||
|
|
||||||
jar.finalizedBy shrink
|
if (!JavaVersion.current().java8Compatible)
|
||||||
|
jar.finalizedBy shrink
|
||||||
shrink.finalizedBy sign
|
shrink.finalizedBy sign
|
||||||
|
|
||||||
artifacts {
|
artifacts {
|
||||||
|
@ -22,7 +22,7 @@ dependencies {
|
|||||||
// The SIMM demo CorDapp depends upon Cash CorDapp features
|
// The SIMM demo CorDapp depends upon Cash CorDapp features
|
||||||
cordapp project(':finance:workflows')
|
cordapp project(':finance:workflows')
|
||||||
cordapp project(':finance:contracts')
|
cordapp project(':finance:contracts')
|
||||||
cordapp project(path: ':samples:simm-valuation-demo:contracts-states', configuration: 'shrinkArtifacts')
|
cordapp project(':samples:simm-valuation-demo:contracts-states')
|
||||||
|
|
||||||
// Corda integration dependencies
|
// Corda integration dependencies
|
||||||
cordaCompile project(':core')
|
cordaCompile project(':core')
|
||||||
|
@ -1,9 +1,15 @@
|
|||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: 'net.corda.plugins.publish-utils'
|
apply plugin: 'net.corda.plugins.publish-utils'
|
||||||
apply plugin: 'com.jfrog.artifactory'
|
apply plugin: 'com.jfrog.artifactory'
|
||||||
|
//apply plugin: "org.javamodularity.moduleplugin"
|
||||||
|
|
||||||
description 'Corda serialization'
|
description 'Corda serialization'
|
||||||
|
|
||||||
|
repositories {
|
||||||
|
mavenLocal()
|
||||||
|
maven { url "https://plugins.gradle.org/m2/" }
|
||||||
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
compile project(":core")
|
compile project(":core")
|
||||||
|
|
||||||
@ -40,6 +46,49 @@ dependencies {
|
|||||||
testCompile project(':node-driver')
|
testCompile project(':node-driver')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// allprojects not allowed ???
|
||||||
|
//subprojects {
|
||||||
|
// // inlined usage of compileJava with moduleOptions not allowed ???
|
||||||
|
// compileJava {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util' : 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// // WARNING: An illegal reflective access operation has occurred
|
||||||
|
// addOpens = [
|
||||||
|
// 'java.base/java.time.ZonedDateTime' : 'ALL-UNNAMED'
|
||||||
|
// // WARNING: Illegal reflective access by net.corda.serialization.internal.amqp.custom.ZonedDateTimeSerializer (file:/Users/josecoll/IdeaProjects/corda-jdk11/serialization/build/libs/corda-serialization-5.0-SNAPSHOT.jar) to method java.time.ZonedDateTime.ofLenient(java.time.LocalDateTime,java.time.ZoneOffset,java.time.ZoneId)
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// test {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED',
|
||||||
|
// 'java.base/sun.security.x509': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// addOpens = [
|
||||||
|
// 'java.base/java.time.ZonedDateTime' : 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// kotlinCompile {
|
||||||
|
// moduleOptions {
|
||||||
|
// addExports = [
|
||||||
|
// 'java.base/sun.security.util': 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// addOpens = [
|
||||||
|
// 'java.base/java.time.ZonedDateTime' : 'ALL-UNNAMED'
|
||||||
|
// ]
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
//}
|
||||||
|
|
||||||
|
// Alternative configuration without java modularity plugin:
|
||||||
|
//test {
|
||||||
|
// jvmArgs('--add-opens', 'java.base/java.time.ZonedDateTime=ALL-UNNAMED')
|
||||||
|
//}
|
||||||
|
|
||||||
configurations {
|
configurations {
|
||||||
testArtifacts.extendsFrom testRuntimeClasspath
|
testArtifacts.extendsFrom testRuntimeClasspath
|
||||||
}
|
}
|
||||||
|
@ -2,8 +2,8 @@ package net.corda.serialization.internal
|
|||||||
|
|
||||||
import net.corda.core.DeleteForDJVM
|
import net.corda.core.DeleteForDJVM
|
||||||
import net.corda.core.serialization.ClassWhitelist
|
import net.corda.core.serialization.ClassWhitelist
|
||||||
import sun.misc.Unsafe
|
//import sun.misc.Unsafe
|
||||||
import sun.security.util.Password
|
//import sun.security.util.Password
|
||||||
import java.io.*
|
import java.io.*
|
||||||
import java.lang.invoke.*
|
import java.lang.invoke.*
|
||||||
import java.lang.reflect.AccessibleObject
|
import java.lang.reflect.AccessibleObject
|
||||||
@ -50,7 +50,7 @@ object AllButBlacklisted : ClassWhitelist {
|
|||||||
ClassLoader::class.java.name,
|
ClassLoader::class.java.name,
|
||||||
Handler::class.java.name, // MemoryHandler, StreamHandler
|
Handler::class.java.name, // MemoryHandler, StreamHandler
|
||||||
Runtime::class.java.name,
|
Runtime::class.java.name,
|
||||||
Unsafe::class.java.name,
|
// Unsafe::class.java.name,
|
||||||
ZipFile::class.java.name,
|
ZipFile::class.java.name,
|
||||||
Provider::class.java.name,
|
Provider::class.java.name,
|
||||||
SecurityManager::class.java.name,
|
SecurityManager::class.java.name,
|
||||||
@ -62,7 +62,7 @@ object AllButBlacklisted : ClassWhitelist {
|
|||||||
|
|
||||||
// java.security.
|
// java.security.
|
||||||
KeyStore::class.java.name,
|
KeyStore::class.java.name,
|
||||||
Password::class.java.name,
|
// Password::class.java.name,
|
||||||
AccessController::class.java.name,
|
AccessController::class.java.name,
|
||||||
Permission::class.java.name,
|
Permission::class.java.name,
|
||||||
|
|
||||||
|
@ -5,7 +5,7 @@ import net.corda.core.utilities.NetworkHostAndPort
|
|||||||
import org.apache.activemq.artemis.api.core.SimpleString
|
import org.apache.activemq.artemis.api.core.SimpleString
|
||||||
import rx.Notification
|
import rx.Notification
|
||||||
import rx.exceptions.OnErrorNotImplementedException
|
import rx.exceptions.OnErrorNotImplementedException
|
||||||
import sun.security.x509.X509CertImpl
|
//import sun.security.x509.X509CertImpl
|
||||||
import java.security.cert.CRLReason
|
import java.security.cert.CRLReason
|
||||||
import java.util.*
|
import java.util.*
|
||||||
|
|
||||||
@ -62,7 +62,7 @@ object DefaultWhitelist : SerializationWhitelist {
|
|||||||
StackTraceElement::class.java,
|
StackTraceElement::class.java,
|
||||||
|
|
||||||
// Implementation of X509Certificate.
|
// Implementation of X509Certificate.
|
||||||
X509CertImpl::class.java,
|
// X509CertImpl::class.java,
|
||||||
CRLReason::class.java
|
CRLReason::class.java
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
@ -4,6 +4,7 @@ pluginManagement {
|
|||||||
repositories {
|
repositories {
|
||||||
mavenLocal()
|
mavenLocal()
|
||||||
gradlePluginPortal()
|
gradlePluginPortal()
|
||||||
|
maven { url "$artifactory_contextUrl/corda-dev" }
|
||||||
maven { url "$artifactory_contextUrl/corda-dependencies" }
|
maven { url "$artifactory_contextUrl/corda-dependencies" }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -89,11 +90,11 @@ project(":common-logging").projectDir = new File("$settingsDir/common/logging")
|
|||||||
|
|
||||||
apply from: 'buildCacheSettings.gradle'
|
apply from: 'buildCacheSettings.gradle'
|
||||||
|
|
||||||
if (JavaVersion.current() == JavaVersion.VERSION_1_8) {
|
//if (JavaVersion.current() == JavaVersion.VERSION_1_8) {
|
||||||
include 'core-deterministic'
|
// include 'core-deterministic'
|
||||||
include 'core-deterministic:testing'
|
// include 'core-deterministic:testing'
|
||||||
include 'core-deterministic:testing:data'
|
// include 'core-deterministic:testing:data'
|
||||||
include 'core-deterministic:testing:verifier'
|
// include 'core-deterministic:testing:verifier'
|
||||||
include 'serialization-deterministic'
|
// include 'serialization-deterministic'
|
||||||
}
|
//}
|
||||||
|
|
||||||
|
@ -126,7 +126,7 @@ class DriverDSLImpl(
|
|||||||
private val state = ThreadBox(State())
|
private val state = ThreadBox(State())
|
||||||
|
|
||||||
//TODO: remove this once we can bundle quasar properly.
|
//TODO: remove this once we can bundle quasar properly.
|
||||||
private val quasarJarPath: String by lazy { resolveJar(".*quasar.*\\.jar$") }
|
private val quasarJarPath: String by lazy { resolveJar("co.paralleluniverse.fibers.Suspendable") }
|
||||||
|
|
||||||
private fun NodeConfig.checkAndOverrideForInMemoryDB(): NodeConfig = this.run {
|
private fun NodeConfig.checkAndOverrideForInMemoryDB(): NodeConfig = this.run {
|
||||||
if (inMemoryDB && corda.dataSourceProperties.getProperty("dataSource.url").startsWith("jdbc:h2:")) {
|
if (inMemoryDB && corda.dataSourceProperties.getProperty("dataSource.url").startsWith("jdbc:h2:")) {
|
||||||
@ -138,15 +138,13 @@ class DriverDSLImpl(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun resolveJar(jarNamePattern: String): String {
|
private fun resolveJar(className: String): String {
|
||||||
return try {
|
return try {
|
||||||
val cl = ClassLoader.getSystemClassLoader()
|
val type = Class.forName(className)
|
||||||
val urls = (cl as URLClassLoader).urLs
|
val src = type.protectionDomain.codeSource
|
||||||
val jarPattern = jarNamePattern.toRegex()
|
return src.location.toPath().toString()
|
||||||
val jarFileUrl = urls.first { jarPattern.matches(it.path) }
|
|
||||||
jarFileUrl.toPath().toString()
|
|
||||||
} catch (e: Exception) {
|
} catch (e: Exception) {
|
||||||
log.warn("Unable to locate JAR `$jarNamePattern` on classpath: ${e.message}", e)
|
log.warn("Unable to locate JAR for class given by `$className` on classpath: ${e.message}", e)
|
||||||
throw e
|
throw e
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -551,6 +549,7 @@ class DriverDSLImpl(
|
|||||||
*extraCmdLineFlag
|
*extraCmdLineFlag
|
||||||
)
|
)
|
||||||
|
|
||||||
|
System.exit(-1)
|
||||||
return poll(executorService, "$extraCmdLineFlag (${config.corda.myLegalName})") {
|
return poll(executorService, "$extraCmdLineFlag (${config.corda.myLegalName})") {
|
||||||
if (process.isAlive) null else Unit
|
if (process.isAlive) null else Unit
|
||||||
}
|
}
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
package net.corda.testing.node;
|
package net.corda.testing.node.internal;
|
||||||
|
|
||||||
import co.paralleluniverse.fibers.Suspendable;
|
import co.paralleluniverse.fibers.Suspendable;
|
||||||
import net.corda.core.Utils;
|
import net.corda.core.Utils;
|
||||||
@ -6,6 +6,9 @@ import net.corda.core.concurrent.CordaFuture;
|
|||||||
import net.corda.core.flows.*;
|
import net.corda.core.flows.*;
|
||||||
import net.corda.core.identity.Party;
|
import net.corda.core.identity.Party;
|
||||||
import net.corda.core.utilities.UntrustworthyData;
|
import net.corda.core.utilities.UntrustworthyData;
|
||||||
|
import net.corda.testing.node.MockNetwork;
|
||||||
|
import net.corda.testing.node.MockNetworkParameters;
|
||||||
|
import net.corda.testing.node.StartedMockNode;
|
||||||
import org.junit.After;
|
import org.junit.After;
|
||||||
import org.junit.Rule;
|
import org.junit.Rule;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
@ -1,3 +1,14 @@
|
|||||||
|
// JDK 11 JavaFX
|
||||||
|
plugins {
|
||||||
|
id 'org.openjfx.javafxplugin' version '0.0.7'
|
||||||
|
}
|
||||||
|
javafx {
|
||||||
|
modules = [ 'javafx.controls',
|
||||||
|
'javafx.fxml',
|
||||||
|
'javafx.swing'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
ext {
|
ext {
|
||||||
tornadofx_version = '1.7.15'
|
tornadofx_version = '1.7.15'
|
||||||
jna_version = '4.1.0'
|
jna_version = '4.1.0'
|
||||||
|
@ -1,3 +1,14 @@
|
|||||||
|
// JDK 11 JavaFX
|
||||||
|
plugins {
|
||||||
|
id 'org.openjfx.javafxplugin' version '0.0.7'
|
||||||
|
}
|
||||||
|
javafx {
|
||||||
|
modules = [ 'javafx.controls',
|
||||||
|
'javafx.fxml',
|
||||||
|
'javafx.swing'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
apply plugin: 'java'
|
apply plugin: 'java'
|
||||||
apply plugin: 'kotlin'
|
apply plugin: 'kotlin'
|
||||||
apply plugin: 'application'
|
apply plugin: 'application'
|
||||||
|
@ -1,3 +1,14 @@
|
|||||||
|
// JDK 11 JavaFX
|
||||||
|
plugins {
|
||||||
|
id 'org.openjfx.javafxplugin' version '0.0.7'
|
||||||
|
}
|
||||||
|
javafx {
|
||||||
|
modules = [ 'javafx.controls',
|
||||||
|
'javafx.fxml',
|
||||||
|
'javafx.swing'
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
ext {
|
ext {
|
||||||
tornadofx_version = '1.7.15'
|
tornadofx_version = '1.7.15'
|
||||||
controlsfx_version = '8.40.12'
|
controlsfx_version = '8.40.12'
|
||||||
|
@ -174,8 +174,8 @@ public class CordaWebserverCaplet extends Capsule {
|
|||||||
|
|
||||||
private static void checkJavaVersion() {
|
private static void checkJavaVersion() {
|
||||||
String version = System.getProperty("java.version");
|
String version = System.getProperty("java.version");
|
||||||
if (version == null || !version.startsWith("1.8")) {
|
if (version == null || Arrays.asList("1.8", "11").stream().noneMatch(version::startsWith)) {
|
||||||
System.err.printf("Error: Unsupported Java version %s; currently only version 1.8 is supported.\n", version);
|
System.err.printf("Error: Unsupported Java version %s; currently only version 1.8 or 11 is supported.\n", version);
|
||||||
System.exit(1);
|
System.exit(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -54,7 +54,8 @@ fun main(args: Array<String>) {
|
|||||||
val info = ManagementFactory.getRuntimeMXBean()
|
val info = ManagementFactory.getRuntimeMXBean()
|
||||||
log.info("CommandLine Args: ${info.inputArguments.joinToString(" ")}")
|
log.info("CommandLine Args: ${info.inputArguments.joinToString(" ")}")
|
||||||
log.info("Application Args: ${args.joinToString(" ")}")
|
log.info("Application Args: ${args.joinToString(" ")}")
|
||||||
log.info("bootclasspath: ${info.bootClassPath}")
|
// JDK 11 (bootclasspath no longer supported from JDK 9)
|
||||||
|
if (info.isBootClassPathSupported) log.info("bootclasspath: ${info.bootClassPath}")
|
||||||
log.info("classpath: ${info.classPath}")
|
log.info("classpath: ${info.classPath}")
|
||||||
log.info("VM ${info.vmName} ${info.vmVendor} ${info.vmVersion}")
|
log.info("VM ${info.vmName} ${info.vmVendor} ${info.vmVersion}")
|
||||||
log.info("Machine: ${InetAddress.getLocalHost().hostName}")
|
log.info("Machine: ${InetAddress.getLocalHost().hostName}")
|
||||||
|
@ -48,7 +48,7 @@ task buildWebserverJar(type: FatCapsule, dependsOn: project(':node').tasks.jar)
|
|||||||
|
|
||||||
capsuleManifest {
|
capsuleManifest {
|
||||||
applicationVersion = corda_release_version
|
applicationVersion = corda_release_version
|
||||||
javaAgents = ["quasar-core-${quasar_version}-jdk8.jar"]
|
javaAgents = ["quasar-core-${quasar_version}.jar"]
|
||||||
systemProperties['visualvm.display.name'] = 'Corda Webserver'
|
systemProperties['visualvm.display.name'] = 'Corda Webserver'
|
||||||
minJavaVersion = '1.8.0'
|
minJavaVersion = '1.8.0'
|
||||||
minUpdateVersion['1.8'] = java8_minUpdateVersion
|
minUpdateVersion['1.8'] = java8_minUpdateVersion
|
||||||
|
Loading…
Reference in New Issue
Block a user