This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Specify the Siddhi application name. | |
var siddhiApplication = 'LoginRiskCalculator'; | |
// Specify the Siddhi input stream name. | |
var siddhiInputStream = 'InputStream'; | |
function onLoginRequest(context) { | |
executeStep(1, { | |
onSuccess: function (context) { | |
getRiskOfLoginAttempt(context); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Source(type = 'http-request', source.id='testsource', receiver.url="https://localhost:8280/Analytics/InputStream", | |
@map(type='json', | |
@attributes(messageId='trp:messageId', | |
username='$.event.username', | |
loginTime='$.event.loginTime', | |
loginIp = '$.event.loginIp'))) | |
define stream InputStream (messageId string, username string, loginIp string, loginTime long); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BasicAWSCredentials credentials = new BasicAWSCredentials("accessKey", "secretKey"); | |
sqs = AmazonSQSClientBuilder.standard() | |
.withCredentials(new AWSStaticCredentialsProvider(credentials)) | |
.withRegion(configs.getRegion()) | |
.build(); |
NewerOlder