Package com.avoka.fc.core.sysevent
Class ServiceClient
java.lang.Object
com.avoka.fc.core.sysevent.ServiceClient
- Direct Known Subclasses:
AWSServiceClient,AzureServiceClient
Provides an implementation for cloud instances for use when send messages from the System Event Publisher
- Since:
- 20.05.0
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract voidcreateQueue(String queueName) Creates a queue in the cloud instance using the name queueNameReturns the unique identifying hash of the Service ClientReturns the expiry date when of the Service Clientabstract StringgetQueueUrlForQueueName(String queueName) For a given queueName will return the URLReturns the queueUrlMap which is maps each queueUrl to the queueNameabstract ServiceClient.ServiceClientTypeWill return the type of the Service Client instance, i.e.abstract booleanisExistingQueue(String queueName) For a given queueName will return true if it existsabstract voidsendMessage(String queueURL, String msg) Will send a message 'msg' to the specified queueUrl
-
Field Details
-
credentialsExpiry
-
configHash
-
queueUrlMap
-
-
Constructor Details
-
ServiceClient
public ServiceClient()
-
-
Method Details
-
createQueue
Creates a queue in the cloud instance using the name queueName- Parameters:
queueName- to create
-
getQueueUrlForQueueName
For a given queueName will return the URL- Parameters:
queueName- for the url- Returns:
- url if queueName found else null
-
getServiceClientType
Will return the type of the Service Client instance, i.e. (AWS, Azure, etc)- Returns:
- serviceClientType of instance
-
isExistingQueue
For a given queueName will return true if it exists- Parameters:
queueName- to determine if exists- Returns:
- true if it exists else false
-
sendMessage
Will send a message 'msg' to the specified queueUrl- Parameters:
queueURL- to receive the messagemsg- to send
-
getCredentialsExpiryDate
Returns the expiry date when of the Service Client- Returns:
- date expiryDate
-
getConfigHash
Returns the unique identifying hash of the Service Client- Returns:
- configHash for the Service Client
-
getQueueUrlMap
Returns the queueUrlMap which is maps each queueUrl to the queueName- Returns:
- queueUrlMap
-