diff --git a/newrelic-security-agent/src/main/java/com/newrelic/agent/security/instrumentator/dispatcher/Dispatcher.java b/newrelic-security-agent/src/main/java/com/newrelic/agent/security/instrumentator/dispatcher/Dispatcher.java index a6900813c..a6deb2a50 100644 --- a/newrelic-security-agent/src/main/java/com/newrelic/agent/security/instrumentator/dispatcher/Dispatcher.java +++ b/newrelic-security-agent/src/main/java/com/newrelic/agent/security/instrumentator/dispatcher/Dispatcher.java @@ -127,13 +127,20 @@ public Object call() throws Exception { break; } case NOSQL_DB_COMMAND: - NoSQLOperation noSQLOperationalBean = (NoSQLOperation) operation; - try { - eventBean = prepareNoSQLEvent(eventBean, noSQLOperationalBean); - } catch (Throwable e) { - return null; + if(operation instanceof SQLOperation) { + eventBean = prepareSQLDbCommandEvent((SQLOperation) operation, eventBean); + break; + } else if (operation instanceof BatchSQLOperation) { + eventBean = prepareSQLDbCommandEvent((BatchSQLOperation) operation, eventBean); + break; + } else if (operation instanceof NoSQLOperation) { + try { + eventBean = prepareNoSQLEvent(eventBean, (NoSQLOperation) operation); + } catch (Throwable e) { + return null; + } + break; } - break; case DYNAMO_DB_COMMAND: DynamoDBOperation dynamoDBOperation = (DynamoDBOperation) operation; diff --git a/settings.gradle b/settings.gradle index 1837947c2..bb49bd6a8 100644 --- a/settings.gradle +++ b/settings.gradle @@ -135,6 +135,8 @@ include 'instrumentation:jdbc-inet-merlia' include 'instrumentation:jdbc-inet-oranxo' include 'instrumentation:jdbc-sybase-6' include 'instrumentation:low-priority-instrumentation' +include 'instrumentation:cassandra-datastax-3' +include 'instrumentation:cassandra-datastax-4' include 'instrumentation:commons-jxpath' //include 'instrumentation:grails-1.3' //include 'instrumentation:grails-2.0'