Commit Graph

517 Commits

Author SHA1 Message Date
ghubstan
37a6b42f74
Set gradle java src & target compat = VERSION_11
This change sets java source and class generation version targets to 11.
The Bisq distribution is built with JDK 11, but source target has remained at 1.10.
Upgrading allows devs to use some Java syntax features available @since 11, and it
might help anyone building the src avoid confusion over which JDK they should use
(minimum is JDK 11).

See https://docs.gradle.org/current/userguide/java_plugin.html#sec:java-extension
2021-11-23 17:43:12 -03:00
Chris Beams
42b00b3a3e
Fix guava dependency issue
Problem: a

    NoSuchMethodError: 'java.util.stream.Collector
    com.google.common.collect.ImmutableMultiset.toImmutableMultiset()'

exception was being thrown when testing the previously-merged upgrade to
Gradle 7.3, as described at keybase://chat/bisq#testing/2466.

Solution: This problem is similar to the issue reported at
jeremylong/DependencyCheck#3221. The source of the problem was multiple
conflicting guava jars on the runtime classpath. This commit upgrades to
guava 30.1.1-jre which ensures a single jar on the classpath.
2021-11-21 17:06:10 +01:00
Chris Beams
cb7b0e8da4
Set pricenode mainClassName explicitly
Problem: after the upgrade from 6.6.1 to 7.3, the usual invocation of,
e.g. `./bisq-pricenode 2 2` started failing as reported by @emzy at [1].

    bisq@ubuntu-4gb-fsn1-1:~$ /bisq/bisq/bisq-pricenode 2
    Error: Could not find or load main class 2
    Caused by: java.lang.ClassNotFoundException: 2

Solution: for unknown reasons, the bisq-pricenode script worked as
expected under 6.6.1, i.e. contained the fq main class name in its
scripted invocation of `java -jar ...`, but under 7.3, this main class
name was missing. Through trial and error, it turns out that setting
`mainClassName` explicitly in the :pricenode subproject configuration
solves this problem and makes the start script work as expected.
Presumably, this problem arose in conjunction with the major version
upgrade of the spring boot Gradle plugin that was necessary when
upgrading to Gradle 7.3, but this has not been verified.

[1]: https://github.com/bisq-network/bisq/pull/5824#issuecomment-968276686
2021-11-15 13:44:44 +01:00
Chris Beams
280c2aaa8e
Adapt Gradle startScript customization logic
Problem: ClassNotFoundError was getting thrown when attempting to run,
e.g. the `./bisq-desktop` or `./bisq-pricenode` start scripts.

Solution: Gradle's posix start scripts were changed significantly
between 6.6.1 and 7.3, including a change to the way the current
directory is determined. This change updates the way we customize start
script generation to allow running them from the root of the repo. This
change only affects the unix / posix variants. The Windows .bat files do
not need to be adapted similarly.
2021-11-15 13:03:49 +01:00
Chris Beams
1460914757
Organize dependency entries
As mentioned in a prior commit, the upgrade to Gradle 7.x results in
many more dependency declarations in the file, many of which are
effectively duplicates. This change does not attempt to eliminate those
duplications in any clever way, but rather just tidies up and organizes
all dependency declarations by sorting them alphabetically.
2021-11-13 14:45:14 +01:00
Chris Beams
e09d56b696
Upgrade Mockito to 4.0.0
This fixes the 'Unsupported class file major version 60' problem
documented at mockito/mockito#2065 to allow building Bisq on JDK 16+.
2021-11-13 13:53:38 +01:00
Chris Beams
990365d5b9
Upgrade Lombok to support JDK16+
This fixes the IllegalAccessError problem documented at
https://stackoverflow.com/a/66981165/622403
2021-11-13 13:43:00 +01:00
Chris Beams
6f8197b419
Migrate to Gradle's built-in dependency verification
This commit removes the use of our fork of the gradle-witness plugin in
favor of Gradle's relatively new built-in dependency verification
feature [1].

The gradle/verification-metadata.xml file was produced using the
following command:

    ./gradlew --write-verification-metadata sha256 build

Where `build` is the usual `gradle build` command. All dependency
configurations are resolved this way, and written out to the file.

The resulting file contains 273 unique dependency declarations, as
compared to just 64 in our now-removed gradle-witness.gradle file. This
means that the coverage of dependencies verified is much more complete.

The new file contains the same sha256 checksums for each dependency as
the old file. This was manually spot-checked for a significant number of
the dependencies.

Like with gradle-witness, builds will break when dependencies are
upgraded (and now also when they are added). To fix these breakages, the
`--write-verification-metadata sha256` option must be provided to the
build. Note that new entries will be added for upgraded depedencies, but
old entries are not removed automatically from the file. These must be
removed manually.

[1]: https://docs.gradle.org/current/userguide/dependency_verification.html
2021-11-13 12:59:52 +01:00
Chris Beams
6a3d2642da
Upgrade to Gradle 7.3
This commit does what is necessary to upgrade from Gradle 6.6.1 to
7.3, including:

- generating the new Gradle wrapper
- replacing uses of 'compile' with 'implementation'
- replacing uses of 'testCompile' with 'testImplementation'

Moving from *compile to *implementation results in many more duplicated
dependency declarations throughout the file. These will be tidied up in
a subsequent commit.

Several dependencies needed to be upgraded in order to support this
change. One of them was Spring Boot, from 1.5.1 to 2.5.6. This is a
major upgrade that contained some breaking changes to the Spring Boot
Actuator. These changes required the removal of the pricenode's
/getVersion endpoint.

The Gradle Witness plugin has been disabled in this commit, because it
uses the now-removed 'compile' configuration. Use of the Witness plugin
will be removed entirely in a subsequent commit in favor of using
Gradle's new built-in dependency verification feature.
2021-11-13 12:09:22 +01:00
Christoph Atteneder
1578f45ffc
Merge pull request #5812 from ghubstan/02-cli-console-formatting-api
Deprecate and replace hard-coded CLI console output formatters
2021-11-09 21:21:52 +01:00
chimp1984
62b3e51b22
Cleanups, change log levels 2021-11-09 13:01:19 +01:00
chimp1984
7c32587453
Persist bsq blocks as buckets of 1000 blocks
Improve logging

Add BsqBlockStore to protobuf

Remove DaoStateMonitoringService field

Do not persist the blocks in daoState anymore.

This improves persistence performance and reduces memory
requirements for snapshots.
2021-11-09 13:01:19 +01:00
ghubstan
1d403e7a42
Add CLI test dependency to check console output diffs, and tests 2021-11-07 14:01:36 -03:00
chimp1984
d5dfdb4a35
Merge branch 'chimp-bsq-swap-1' into bsq-swap-low-risk-refactorings-2
# Conflicts:
#	core/src/main/java/bisq/core/account/witness/AccountAgeWitnessService.java
#	core/src/main/java/bisq/core/api/CoreOffersService.java
#	core/src/main/java/bisq/core/btc/listeners/TxConfidenceListener.java
#	core/src/main/java/bisq/core/notifications/alerts/market/MarketAlerts.java
#	core/src/main/java/bisq/core/offer/OpenOfferManager.java
#	core/src/main/java/bisq/core/offer/bisq_v1/CreateOfferService.java
#	core/src/main/java/bisq/core/offer/bisq_v1/OfferPayload.java
#	core/src/main/java/bisq/core/offer/bisq_v1/TakeOfferModel.java
#	core/src/main/java/bisq/core/offer/bisq_v1/TriggerPriceService.java
#	core/src/main/java/bisq/core/proto/ProtoDevUtil.java
#	core/src/main/java/bisq/core/trade/TradeManager.java
#	core/src/main/java/bisq/core/trade/bisq_v1/TradeResultHandler.java
#	core/src/main/java/bisq/core/trade/bisq_v1/TradeUtil.java
#	core/src/main/java/bisq/core/trade/model/bisq_v1/Trade.java
#	core/src/main/java/bisq/core/trade/protocol/FluentProtocol.java
#	core/src/main/java/bisq/core/trade/protocol/Provider.java
#	core/src/main/java/bisq/core/trade/protocol/TradeProtocol.java
#	core/src/main/java/bisq/core/trade/protocol/TradeProtocolFactory.java
#	core/src/main/java/bisq/core/trade/protocol/TradeTaskRunner.java
#	core/src/main/java/bisq/core/trade/protocol/bisq_v1/DisputeProtocol.java
#	core/src/main/java/bisq/core/trade/protocol/bisq_v1/model/ProcessModel.java
#	core/src/main/java/bisq/core/trade/protocol/bisq_v1/tasks/ApplyFilter.java
#	core/src/main/java/bisq/core/trade/protocol/bisq_v1/tasks/TradeTask.java
#	core/src/main/java/bisq/core/trade/protocol/bisq_v1/tasks/maker/MakerCreateAndSignContract.java
#	core/src/main/java/bisq/core/trade/protocol/bisq_v1/tasks/taker/TakerVerifyAndSignContract.java
#	core/src/main/java/bisq/core/trade/statistics/TradeStatistics2.java
#	core/src/main/java/bisq/core/trade/statistics/TradeStatisticsManager.java
#	core/src/main/java/bisq/core/trade/txproof/xmr/XmrTxProofService.java
#	desktop/src/main/java/bisq/desktop/components/paymentmethods/PaymentMethodForm.java
#	desktop/src/main/java/bisq/desktop/main/PriceUtil.java
#	desktop/src/main/java/bisq/desktop/main/funds/transactions/TransactionAwareTradableFactory.java
#	desktop/src/main/java/bisq/desktop/main/funds/transactions/TransactionAwareTrade.java
#	desktop/src/main/java/bisq/desktop/main/market/offerbook/OfferBookChartView.java
#	desktop/src/main/java/bisq/desktop/main/market/offerbook/OfferBookChartViewModel.java
#	desktop/src/main/java/bisq/desktop/main/market/spread/SpreadViewModel.java
#	desktop/src/main/java/bisq/desktop/main/offer/BuyOfferView.java
#	desktop/src/main/java/bisq/desktop/main/offer/OfferView.java
#	desktop/src/main/java/bisq/desktop/main/offer/SellOfferView.java
#	desktop/src/main/java/bisq/desktop/main/offer/bisq_v1/MutableOfferDataModel.java
#	desktop/src/main/java/bisq/desktop/main/offer/bisq_v1/MutableOfferView.java
#	desktop/src/main/java/bisq/desktop/main/offer/bisq_v1/MutableOfferViewModel.java
#	desktop/src/main/java/bisq/desktop/main/offer/bisq_v1/takeoffer/TakeOfferDataModel.java
#	desktop/src/main/java/bisq/desktop/main/offer/bisq_v1/takeoffer/TakeOfferView.java
#	desktop/src/main/java/bisq/desktop/main/offer/bisq_v1/takeoffer/TakeOfferViewModel.java
#	desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBook.java
#	desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBookView.java
#	desktop/src/main/java/bisq/desktop/main/offer/offerbook/OfferBookViewModel.java
#	desktop/src/main/java/bisq/desktop/main/overlays/windows/OfferDetailsWindow.java
#	desktop/src/main/java/bisq/desktop/main/portfolio/closedtrades/ClosedTradesDataModel.java
#	desktop/src/main/java/bisq/desktop/main/portfolio/editoffer/EditOfferDataModel.java
#	desktop/src/main/java/bisq/desktop/main/portfolio/failedtrades/FailedTradesDataModel.java
#	desktop/src/main/java/bisq/desktop/main/portfolio/openoffer/OpenOffersDataModel.java
#	desktop/src/main/java/bisq/desktop/main/portfolio/openoffer/OpenOffersView.java
#	desktop/src/main/java/bisq/desktop/main/portfolio/pendingtrades/PendingTradesDataModel.java
#	desktop/src/main/java/bisq/desktop/util/DisplayUtils.java
#	desktop/src/test/java/bisq/desktop/main/offer/bisq_v1/createoffer/CreateOfferDataModelTest.java
#	desktop/src/test/java/bisq/desktop/main/offer/bisq_v1/createoffer/CreateOfferViewModelTest.java
#	desktop/src/test/java/bisq/desktop/main/offer/offerbook/OfferBookListItemMaker.java
#	desktop/src/test/java/bisq/desktop/main/portfolio/editoffer/EditOfferDataModelTest.java
#	desktop/src/test/java/bisq/desktop/maker/OfferMaker.java
#	monitor/src/main/java/bisq/monitor/metric/P2PMarketStats.java
2021-11-02 16:04:12 +01:00
Christoph Atteneder
50798f0d62
Revert to SNAPSHOT version 2021-10-29 16:06:49 +02:00
chimp1984
2f40eddae8
Use bitcoinj 42bbae9 (with fix required for bsq swaps) 2021-10-21 15:41:07 +02:00
Christoph Atteneder
8fbccb7547
Bump version number for v1.7.5 2021-10-19 11:32:09 +02:00
cd2357
455a74a4a8
chore: Bump tor to v0.4.5.10
Update netlayer and tor-binary dependencies.
2021-10-18 09:12:21 +02:00
Christoph Atteneder
f73274b0b9
Revert to SNAPSHOT version 2021-09-24 19:28:11 +02:00
Christoph Atteneder
64274cf82e
Bump version number for v1.7.4 2021-09-21 09:24:26 +02:00
Christoph Atteneder
9c411b9ba4
Update Bisq bitcoinj fork with latest commit (3186b200fff690fa51f3ebbf578f427d78242bc2)
Conflicts:
	build.gradle
	gradle/witness/gradle-witness.gradle
2021-09-13 11:33:12 +02:00
Christoph Atteneder
704333f133
Add bitcoinj Tor v3 support 2021-09-09 11:41:01 +02:00
Christoph Atteneder
0e4278012b
Revert to SNAPSHOT version 2021-08-30 14:16:11 +02:00
Christoph Atteneder
ad95e5b3be
Bump version number for v1.7.3 2021-08-23 11:20:09 +02:00
Christoph Atteneder
4c451ebc11
Revert to SNAPSHOT version 2021-07-23 14:02:37 +02:00
Christoph Atteneder
0cd20d6cc5
Increase MaxRam setting to 8g 2021-07-22 15:01:11 +02:00
Christoph Atteneder
6648ab04f7
Add new JVM arguments also to build script 2021-07-22 15:01:11 +02:00
Christoph Atteneder
401f9d25f0
Update remaining Java max ram default settings 2021-07-22 15:01:11 +02:00
Christoph Atteneder
12b0a5bf80
Bump version number for v1.7.2 2021-07-16 20:37:10 +02:00
Christoph Atteneder
ef5ff1249b
Merge branch 'master' of github.com:bisq-network/bisq into release/v1.7.1
# Conflicts:
#	build.gradle
#	desktop/package/linux/Dockerfile
#	desktop/package/macosx/finalize.sh
#	desktop/package/macosx/insert_snapshot_version.sh
#	relay/src/main/resources/version.txt
2021-07-16 13:02:18 +02:00
Christoph Atteneder
a924e1058d
Revert to SNAPSHOT version 2021-07-16 12:58:55 +02:00
Christoph Atteneder
dddabe3081
Merge pull request #5582 from jmacxx/pricenode_config_ccy_excl
PriceNode: exclude currencies via config
2021-07-13 17:54:47 +02:00
Christoph Atteneder
dfb97ca05f
Bump version number for v1.7.1 2021-07-12 14:52:38 +02:00
Christoph Atteneder
b9db2426ba
Revert to SNAPSHOT version 2021-07-06 11:13:35 +02:00
Christoph Atteneder
9f42035108
Bump version number for v1.7.0 2021-06-23 14:27:22 +02:00
jmacxx
1c05e5d990
PriceNode: exclude currencies via config 2021-06-22 16:46:47 -05:00
cd2357
eea3acae36
Bump guice version to fix startup warnings
Bump guice to v5.0.1 to fix reflection warning logs shown each time Bisq started.
2021-06-11 12:03:28 +02:00
Christoph Atteneder
351d5f13e7
Revert to SNAPSHOT version 2021-05-31 09:53:33 +02:00
Christoph Atteneder
59de78c332
Bump version number for v1.6.5 2021-05-21 20:00:49 +02:00
Christoph Atteneder
0160039788
Revert "Remove openjfx plugin and manually add cross-platform openjfx libs"
This reverts commit 1c0409ad84.
2021-05-20 16:19:48 +02:00
Christoph Atteneder
1c0409ad84
Remove openjfx plugin and manually add cross-platform openjfx libs 2021-05-19 11:37:38 +02:00
Christoph Atteneder
e3842f2d04
Use gradle javafx plugin 2021-05-18 17:19:56 +02:00
Christoph Atteneder
fb410ac345
Upgrade JavaFX to v16 2021-05-18 16:44:30 +02:00
cd2357
a4863baa94
Preserve shadow plugin name
Include plugins.gradle.org repository, which contains the shadow plugin of the same artefact group and name as used before in jcenter.
2021-05-17 12:55:32 +02:00
cd2357
f26ccb15b7
Remove jcenter repository
Replace the jcenter repo with mavenCentral and jitpack.
2021-05-16 15:17:44 +02:00
Christoph Atteneder
25d2731fb4
Revert to SNAPSHOT version 2021-05-06 20:40:11 +02:00
Christoph Atteneder
dba59138df
Bump version number for v1.6.4 2021-05-05 10:27:42 +02:00
Christoph Atteneder
2c5e785a1e
Bump version number for v1.6.3 2021-04-22 10:36:37 +02:00
Christoph Atteneder
3281767a52
Clean build files and adapt binary signing 2021-04-20 15:10:44 +02:00
Christoph Atteneder
b5beea58db
Temporary delete QR code scanner
used for mobile notification pairing because of missing current macOS support by currently used webcam library
2021-04-20 10:20:58 +02:00