Commit graph

13653 commits

Author SHA1 Message Date
chimp1984
1ca527447e
Change warnings of banned filter to info level 2020-12-19 14:49:55 -05:00
chimp1984
7e77991cb5
Only log if we removed an offer from a trade not if deactivated 2020-12-19 14:49:36 -05:00
ghubstan
87f75ee10c
Configure GrpcVersionService's rate metering interceptor
This change demonstrates how a method call rate metering interceptor
is configured for a gRPC service.  GrpcVersionService uses a custom
rate metering interceptor, or none.  A commented out, 'default'
interceptor is defined as a usage example.
2020-12-19 16:41:26 -03:00
chimp1984
d65471e976
Remove dev log 2020-12-19 14:34:49 -05:00
chimp1984
55b2cf6259
Change period for statistics log to 5 min instead of 1 min to make it less verbose 2020-12-19 14:34:34 -05:00
chimp1984
9d4d116508
Change log level.
For 1.3.9 filter we expect a error log but dont want to show it as warning
2020-12-19 14:34:09 -05:00
chimp1984
dc19e31fe5
Change log level to debug. Fix wrong method name in log.
We request each min. the price feed so that get very verbose
2020-12-19 14:33:28 -05:00
ghubstan
ea97a801e5
Don't cancel gRPC call if an interceptor does not meter all methods 2020-12-19 16:31:41 -03:00
ghubstan
bb8d2ae7c4
Inject Config into CoreApi 2020-12-19 15:50:00 -03:00
ghubstan
9f679deb08
Add license note and toString method 2020-12-19 15:47:20 -03:00
ghubstan
830a5f009a
Add license note 2020-12-19 15:43:44 -03:00
ghubstan
455ed67f9b
Add GrpcServiceRateMeteringConfigTest 2020-12-19 15:41:55 -03:00
ghubstan
5de910a03d
Add unit test dependencies to daemon subproject 2020-12-19 15:40:27 -03:00
ghubstan
b307593c82
Make CallRateMeteringInterceptor configurable via json
This adds a GrpcServiceRateMeteringConfig class that can read and
write rate metering interceptor config files, and configure
a gRPC rate metering service interceptor at startup.

This seems excessive, but we need to be able to test and tune
method rate metering without having to change hard coded, default
interceptor rate meters.
2020-12-19 15:32:40 -03:00
ghubstan
a5ed17e43f
Add license comment, stop & toString methods, and make isRunning transient 2020-12-19 13:14:06 -03:00
chimp1984
af9f2a9643
In case a reset of the dao state was triggered we delete
now all dao store files and request a shut down of the app.

After a restart the resource files are used. This avoids cases where a resync from
genesis got triggered (observed on seed nodes, not on desktop apps).

Seed nodes and headless apps get shut down automatically.
In case of the desktop app we show a warn popup with shutdown
button and no close button, so we enforce a shutdown to avoid
complications in case the user would continue.
2020-12-18 20:29:47 -05:00
sqrrm
e2c8e4dff6
Merge pull request #4965 from ripcurlx/update-data-stores-for-v1.5.2
[v1.5.2] Update data stores for v1.5.2
2020-12-18 23:09:04 +01:00
Christoph Atteneder
7c0d02ad09
Make it easier to translate trade roles 2020-12-18 20:48:42 +01:00
sqrrm
b04a56e543
Merge pull request #4969 from ripcurlx/improve-translations-in-trade-details
Make it easier to translate trade roles
2020-12-18 19:06:49 +01:00
Christoph Atteneder
9a54ccc077
Make it easier to translate trade roles 2020-12-18 17:06:56 +01:00
Christoph Atteneder
400a713a41
Fix private notification style issue in dark mode 2020-12-18 15:57:07 +01:00
Christoph Atteneder
7fcb857fd3
Use sign state icon selector for payment account cell factory 2020-12-18 11:57:05 +01:00
Christoph Atteneder
4736bb806a
Limit badge display to two digits
Supporting three digits in this UI element wouldn't
work properly in all our use cases
2020-12-18 10:51:39 +01:00
Christoph Atteneder
626aac69a8
Remove wrong error log 2020-12-18 10:01:33 +01:00
ghubstan
89e2187878
Change long to int, tidy up error msg 2020-12-17 14:12:04 -03:00
ghubstan
2148a4d958
Prevent excessive api calls
This change provides a gRPC CallRateMeteringInterceptor to help protect
the server and network against being overloaded by CLI scripting mistakes.

An interceptor instance can be configured on a gRPC service to set
individual method call rate limits on one or more of the the service's
methods. For example, the GrpcOffersService could be configured with
this interceptor to set the createoffer rate limit to 5/hour, and
the takeoffer call rate limit could be set to 20/day.  Whenever a
call rate limit is exceeded, the gRPC call is aborted and the client
recieves a "rate limit exceeded" error.

Below is a simple example showing how to set rate limits for one method
in GrpcVersionService.

    final ServerInterceptor[] interceptors() {
        return new ServerInterceptor[]{
                new CallRateMeteringInterceptor(new HashMap<>() {{
                    put("getVersion", new GrpcCallRateMeter(2, SECONDS));
                }})
        };
    }

It specifies a CLI can execute getversion 2 times / second.

This is not a throttling mechansim, there is no blocking nor locking
to slow call rates.  When call rates are exceeded, calls are
simply aborted.
2020-12-17 12:33:45 -03:00
Christoph Atteneder
6384753332
Update data stores for v1.5.2 2020-12-17 15:48:05 +01:00
Christoph Atteneder
2ba15a97ac
Update bitcoinj checkpoints for v1.5.2 2020-12-17 15:47:36 +01:00
jmacxx
a49cb24e09
review fix: try..catch around all parseCoin() 2020-12-17 15:33:26 +01:00
jmacxx
9cb9ed20e4
Privacy improvements for manual payout
Redesign the UI
Add import/export of payout settings
Add ability to import from mediation ticket
Mediator does not need private key
User can sign using own wallet or private key
Validation of input fields
Calculate the tx fee based on inputs
Display of the generated txid & hex so it can be checked
2020-12-17 15:33:21 +01:00
Christoph Atteneder
ceecb404d2
Merge pull request #4899 from jmacxx/4061_privacy_improvement
Privacy improvements for manual payout
2020-12-17 15:32:44 +01:00
Christoph Atteneder
a3824f8151
Merge pull request #4961 from m52go/remove-btcnode-ip
Remove m52go btc node ip
2020-12-17 10:01:52 +01:00
jmacxx
e888be3192
review fix: try..catch around all parseCoin() 2020-12-16 22:15:16 -06:00
sqrrm
113bb4f7f2
Merge pull request #4963 from chimp1984/fix-case-if-no-data-store-service-is-available
Call completeHandler if services in store services is empty.
2020-12-17 00:55:26 +01:00
chimp1984
f270b9c6fa
Call completeHandler if services in store services is empty.
If oen starts with --daoActivated=false there is no service
set up in one of the data store services so it never calls
the result handler and the app never starts up.
2020-12-16 22:25:06 +01:00
chimp1984
4c575098b7
Call completeHandler if services in store services is empty.
If oen starts with --daoActivated=false there is no service
set up in one of the data store services so it never calls
the result handler and the app never starts up.
2020-12-16 16:21:10 -05:00
Christoph Atteneder
c5c93b213d
Merge pull request #4962 from oscarguindzberg/bloomFilterFix2
Use bitcoinj 0.15.8.bisq.13 (commit dcf8af0)
2020-12-16 21:45:49 +01:00
ghubstan
fa9ffa1fb2
Put arguments on separate lines 2020-12-16 15:35:12 -03:00
m52go
b94d06c33f
Remove m52go btc node ip 2020-12-16 19:30:56 +01:00
ghubstan
2572e8641d
Create grpc interceptor pkg, move auth interceptor into it 2020-12-16 15:30:40 -03:00
Oscar Guindzberg
a161376da3
Use bitcoinj 0.15.8.bisq.13 (commit dcf8af0) 2020-12-16 14:57:41 -03:00
m52go
4e4cb42f6a
Remove m52go btc node ip 2020-12-16 12:50:46 -05:00
ghubstan
f7c1103848
Rename gRPC exception handler class 2020-12-16 14:42:23 -03:00
ghubstan
c60605f75c
Fix class level comment 2020-12-16 14:26:12 -03:00
ghubstan
1cd47fd0aa
Merge branch 'master' into 09-refactor-grpc-error-handling 2020-12-16 13:45:29 -03:00
ghubstan
e6c6d3b8d3
Add new CoreApiExceptionHandler to gRPC services
This change reduces gRPC service error handling duplication by moving
it into a @Singleton encapsulating everything needed to wrap
an expected or unexpected core api exception into a gRPC
StatusRuntimeException before sending it to the client.  It also
fixes some boilerpate classes were gRPC error handling was missing.
2020-12-16 13:34:21 -03:00
chimp1984
83e620d462
Fix missing param in test 2020-12-16 10:08:55 -05:00
chimp1984
0cd32fa6e5
Add null check (for tests) and fix missing param for test class.
Fix test with price display.
2020-12-16 15:42:30 +01:00
chimp1984
169f46d753
Set bsq30DayAveragePrice only at activate as its expensive
call and does not change frequently and is only used for
informational purpose as % display.
2020-12-16 15:42:24 +01:00
chimp1984
14e5eefab4
Add check to not devide by 0
Cleanups
2020-12-16 15:42:18 +01:00