Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public FileInfo fileInfo() {
dataConnection.setRequestMethod("HEAD");

if (dataConnection.getResponseCode() > 299 || dataConnection.getResponseCode() < 200) {
throw new DownloaderException("Could not find remote file");
throw new DownloaderException("Could not find remote file " + dataConnection.getResponseCode());
}

long fileSize = dataConnection.getContentLengthLong();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public synchronized FileInfo fileInfo() {
dataConnection.setRequestMethod("HEAD");

if (dataConnection.getResponseCode() > 299 || dataConnection.getResponseCode() < 200) {
throw new DownloaderException("Could not find remote file");
throw new DownloaderException("Could not find remote file " + dataConnection.getResponseCode());
}

long fileSize = dataConnection.getContentLengthLong();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,12 @@
name = "ipinfo-site",
description = "Downloads the selected IpInfo dataset from IpInfo's website")
public class DownloadIpInfoSiteCommand extends IpInfoBaseCommand {
@Option(
names = {"-t", "--token"},
required = true,
description = "The ipinfo download key")

@Option(
names = {"-t", "--token"},
required = false,
defaultValue = "${env:IPINFO_API_KEY}",
description = "The ipinfo download key")
String token;

@Parameters(
Expand All @@ -26,6 +28,6 @@ public class DownloadIpInfoSiteCommand extends IpInfoBaseCommand {
public DownloadExecutionResult execute() {
return new DownloadIpInfoSite(
noCheckMd5, overwrite, verbose, dataset, format, token, destination)
.execute();
.execute();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@
description = "Downloads the selected Maxmind edition of a database from Maxmind's website")
public class DownloadMaxmindSiteCommand extends MaxmindBaseCommand {

@Option(
names = {"-k", "--key"},
required = true,
description = "The maxmind download key")
@Option(
names = {"-k", "--key"},
required = false,
defaultValue = "${env:MAXMIND_API_KEY}",
description = "The maxmind download key")
String key;

@Parameters(
Expand Down