Skip to content

Commit 1dc5436

Browse files
author
Arkadiy Kukarkin
committed
upgrade rclone, libp2p
- need rclone >= v1.68.0 to upgrade away from deprecated v1 aws sdk - need go-libp2p >= v0.44.0 for go-quic version compatibility - rclone dropped fs.NewConfig(), need to hardcode more defaults :( - azureblob retired years ago
1 parent 98df962 commit 1dc5436

File tree

7 files changed

+627
-493
lines changed

7 files changed

+627
-493
lines changed

cmd/storage/create.go

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,10 @@ import (
1515
"github.com/data-preservation-programs/singularity/storagesystem"
1616
"github.com/data-preservation-programs/singularity/util"
1717
"github.com/gotidy/ptr"
18-
"github.com/rclone/rclone/fs"
1918
"github.com/rjNemo/underscore"
2019
"github.com/urfave/cli/v2"
2120
)
2221

23-
var defaultClientConfig = fs.NewConfig()
24-
2522
var CommonConfigFlags = []cli.Flag{
2623
&cli.IntFlag{
2724
Name: "client-retry-max",
@@ -70,19 +67,19 @@ var httpClientConfigFlags = []cli.Flag{
7067
&cli.DurationFlag{
7168
Name: "client-connect-timeout",
7269
Usage: "HTTP Client Connect timeout",
73-
DefaultText: defaultClientConfig.ConnectTimeout.String(),
70+
DefaultText: "1m0s", // rclone default
7471
Category: "Client Config",
7572
},
7673
&cli.DurationFlag{
7774
Name: "client-timeout",
7875
Usage: "IO idle timeout",
79-
DefaultText: defaultClientConfig.Timeout.String(),
76+
DefaultText: "5m0s", // rclone default
8077
Category: "Client Config",
8178
},
8279
&cli.DurationFlag{
8380
Name: "client-expect-continue-timeout",
8481
Usage: "Timeout when using expect / 100-continue in HTTP",
85-
DefaultText: defaultClientConfig.ExpectContinueTimeout.String(),
82+
DefaultText: "1s", // rclone default
8683
Category: "Client Config",
8784
},
8885
&cli.BoolFlag{
@@ -100,7 +97,7 @@ var httpClientConfigFlags = []cli.Flag{
10097
&cli.StringFlag{
10198
Name: "client-user-agent",
10299
Usage: "Set the user-agent to a specified string",
103-
DefaultText: defaultClientConfig.UserAgent,
100+
DefaultText: "rclone default", // Actual: "rclone/" + version
104101
Category: "Client Config",
105102
},
106103
&cli.PathFlag{

cmd/storage/update.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,19 @@ var HTTPClientConfigFlagsForUpdate = []cli.Flag{
2222
&cli.DurationFlag{
2323
Name: "client-connect-timeout",
2424
Usage: "HTTP Client Connect timeout",
25-
DefaultText: defaultClientConfig.ConnectTimeout.String(),
25+
DefaultText: "1m0s", // rclone default
2626
Category: "Client Config",
2727
},
2828
&cli.DurationFlag{
2929
Name: "client-timeout",
3030
Usage: "IO idle timeout",
31-
DefaultText: defaultClientConfig.Timeout.String(),
31+
DefaultText: "5m0s", // rclone default
3232
Category: "Client Config",
3333
},
3434
&cli.DurationFlag{
3535
Name: "client-expect-continue-timeout",
3636
Usage: "Timeout when using expect / 100-continue in HTTP",
37-
DefaultText: defaultClientConfig.ExpectContinueTimeout.String(),
37+
DefaultText: "1s", // rclone default
3838
Category: "Client Config",
3939
},
4040
&cli.BoolFlag{
@@ -52,7 +52,7 @@ var HTTPClientConfigFlagsForUpdate = []cli.Flag{
5252
&cli.StringFlag{
5353
Name: "client-user-agent",
5454
Usage: "Set the user-agent to a specified string. To remove, use empty string.",
55-
DefaultText: defaultClientConfig.UserAgent,
55+
DefaultText: "rclone default", // Actual: "rclone/" + version
5656
Category: "Client Config",
5757
},
5858
&cli.PathFlag{

0 commit comments

Comments
 (0)