mirror of
https://github.com/aljazceru/lnd-manageJ.git
synced 2026-01-20 14:34:24 +01:00
Merge branch 'fix-5746'
This commit is contained in:
22
Dockerfile
Normal file
22
Dockerfile
Normal file
@@ -0,0 +1,22 @@
|
||||
FROM gradle:latest
|
||||
RUN apt-get update
|
||||
RUN apt-get install postgresql sudo -y
|
||||
|
||||
RUN git clone https://github.com/C-Otto/lnd-manageJ.git --branch fix-5746
|
||||
WORKDIR lnd-manageJ
|
||||
RUN gradle application:bootJar
|
||||
|
||||
RUN mkdir -p /root/.config
|
||||
RUN echo "[lnd]" >> /root/.config/lnd-manageJ.conf
|
||||
RUN echo "host=localhost" >> /root/.config/lnd-manageJ.conf
|
||||
RUN echo "macaroon_file=/root/.lnd/data/chain/bitcoin/testnet/admin.macaroon" >> /root/.config/lnd-manageJ.conf
|
||||
|
||||
EXPOSE 8081
|
||||
RUN echo "server.address=0.0.0.0" >> /root/override.properties
|
||||
CMD /etc/init.d/postgresql start && \
|
||||
sudo -u postgres psql -c "CREATE USER bitcoin WITH PASSWORD 'unset'" && \
|
||||
sudo -u postgres createdb lndmanagej -O bitcoin && \
|
||||
java -jar application/build/libs/application-boot.jar --spring.config.location=classpath:application.properties,/root/override.properties
|
||||
|
||||
# docker build -t lnd-managej .
|
||||
# docker run --network host -v /home/xxx/.lnd/:/root/.lnd lnd-managej
|
||||
@@ -87,6 +87,7 @@ public class GrpcSendToRoute {
|
||||
return SendToRouteRequest.newBuilder()
|
||||
.setRoute(lndRoute)
|
||||
.setPaymentHash(ByteString.copyFrom(paymentHash.getByteArray()))
|
||||
.setSkipTempErr(true)
|
||||
.build();
|
||||
}
|
||||
|
||||
|
||||
@@ -68,6 +68,7 @@ class GrpcSendToRouteTest {
|
||||
void sends_to_converted_route() {
|
||||
grpcSendToRoute.sendToRoute(ROUTE, DECODED_PAYMENT_REQUEST, observer);
|
||||
RouterOuterClass.SendToRouteRequest expectedRequest = RouterOuterClass.SendToRouteRequest.newBuilder()
|
||||
.setSkipTempErr(true)
|
||||
.setRoute(Route.newBuilder()
|
||||
.setTotalTimeLock(ROUTE.getTotalTimeLock(BLOCK_HEIGHT, DECODED_PAYMENT_REQUEST.cltvExpiry()))
|
||||
.addHops(Hop.newBuilder()
|
||||
|
||||
@@ -284,6 +284,12 @@ message SendPaymentRequest {
|
||||
If set, an AMP-payment will be attempted.
|
||||
*/
|
||||
bool amp = 22;
|
||||
|
||||
/*
|
||||
The time preference for this payment. Set to -1 to optimize for fees
|
||||
only, to 1 to optimize for reliability only or a value inbetween for a mix.
|
||||
*/
|
||||
double time_pref = 23;
|
||||
}
|
||||
|
||||
message TrackPaymentRequest {
|
||||
@@ -330,6 +336,14 @@ message SendToRouteRequest {
|
||||
|
||||
// Route that should be used to attempt to complete the payment.
|
||||
lnrpc.Route route = 2;
|
||||
|
||||
/*
|
||||
Whether the payment should be marked as failed when a temporary error is
|
||||
returned from the given route. Set it to true so the payment won't be
|
||||
failed unless a terminal error is occurred, such as payment timeout, no
|
||||
routes, incorrect payment details, or insufficient funds.
|
||||
*/
|
||||
bool skip_temp_err = 3;
|
||||
}
|
||||
|
||||
message SendToRouteResponse {
|
||||
@@ -360,6 +374,11 @@ message QueryMissionControlResponse {
|
||||
message XImportMissionControlRequest {
|
||||
// Node pair-level mission control state to be imported.
|
||||
repeated PairHistory pairs = 1;
|
||||
|
||||
// Whether to force override MC pair history. Note that even with force
|
||||
// override the failure pair is imported before the success pair and both
|
||||
// still clamp existing failure/success amounts.
|
||||
bool force = 2;
|
||||
}
|
||||
|
||||
message XImportMissionControlResponse {
|
||||
@@ -678,7 +697,7 @@ enum PaymentState {
|
||||
FAILED_NO_ROUTE = 3;
|
||||
|
||||
/*
|
||||
A non-recoverable error has occured.
|
||||
A non-recoverable error has occurred.
|
||||
*/
|
||||
FAILED_ERROR = 4;
|
||||
|
||||
@@ -776,6 +795,21 @@ message ForwardHtlcInterceptResponse {
|
||||
|
||||
// The preimage in case the resolve action is Settle.
|
||||
bytes preimage = 3;
|
||||
|
||||
// Encrypted failure message in case the resolve action is Fail.
|
||||
//
|
||||
// If failure_message is specified, the failure_code field must be set
|
||||
// to zero.
|
||||
bytes failure_message = 4;
|
||||
|
||||
// Return the specified failure code in case the resolve action is Fail. The
|
||||
// message data fields are populated automatically.
|
||||
//
|
||||
// If a non-zero failure_code is specified, failure_message must not be set.
|
||||
//
|
||||
// For backwards-compatibility reasons, TEMPORARY_CHANNEL_FAILURE is the
|
||||
// default value for this field.
|
||||
lnrpc.Failure.FailureCode failure_code = 5;
|
||||
}
|
||||
|
||||
enum ResolveHoldForwardAction {
|
||||
|
||||
Reference in New Issue
Block a user