mirror of
https://github.com/signalapp/Signal-Server.git
synced 2026-12-01 11:26:47 +00:00
Specify SQS region
This commit is contained in:
1 parent
fedfc66403
commit
ce5f73a5a6
2 files changed
+9
-1
No files matched your search
@@ -32,6 +32,10 @@ public class SqsConfiguration {
|
||||
@JsonProperty
|
||||
private String queueUrl;
|
||||
|
||||
@NotEmpty
|
||||
@JsonProperty
|
||||
private String region = "us-east-1";
|
||||
|
||||
public String getAccessKey() {
|
||||
return accessKey;
|
||||
}
|
||||
@@ -43,6 +47,10 @@ public class SqsConfiguration {
|
||||
public String getQueueUrl() {
|
||||
return queueUrl;
|
||||
}
|
||||
|
||||
public String getRegion() {
|
||||
return region;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -54,7 +54,7 @@ public class DirectoryQueue {
|
||||
final AWSStaticCredentialsProvider credentialsProvider = new AWSStaticCredentialsProvider(credentials);
|
||||
|
||||
this.queueUrl = sqsConfig.getQueueUrl();
|
||||
this.sqs = AmazonSQSClientBuilder.standard().withCredentials(credentialsProvider).build();
|
||||
this.sqs = AmazonSQSClientBuilder.standard().withRegion(sqsConfig.getRegion()).withCredentials(credentialsProvider).build();
|
||||
}
|
||||
|
||||
public void addRegisteredUser(String user) {
|
||||
|
||||
Reference in new issue
Block a user