You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by ga...@apache.org on 2015/08/20 08:44:46 UTC
[2/5] stratos git commit: Adding Metering and Monitoring Service
Implementation
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/CloudControllerServiceUtil.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/CloudControllerServiceUtil.java b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/CloudControllerServiceUtil.java
index 4015a77..adbe294 100644
--- a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/CloudControllerServiceUtil.java
+++ b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/CloudControllerServiceUtil.java
@@ -65,18 +65,21 @@ public class CloudControllerServiceUtil {
TopologyBuilder.handleMemberTerminated(memberContext.getCartridgeType(),
memberContext.getClusterId(), memberContext.getNetworkPartitionId(),
partitionId, memberContext.getMemberId());
-
+ //member terminated time
+ Long timeStamp = System.currentTimeMillis();
// Publish statistics to BAM
BAMUsageDataPublisher.publish(memberContext.getMemberId(),
partitionId,
memberContext.getNetworkPartitionId(),
+ memberContext.getClusterInstanceId(),
memberContext.getClusterId(),
memberContext.getCartridgeType(),
MemberStatus.Terminated.toString(),
- null);
+ timeStamp, null, null, null);
// Remove member context
- CloudControllerContext.getInstance().removeMemberContext(memberContext.getClusterId(), memberContext.getMemberId());
+ CloudControllerContext.getInstance().removeMemberContext(memberContext.getClusterId(),
+ memberContext.getMemberId());
// Persist cloud controller context
CloudControllerContext.getInstance().persist();
@@ -87,7 +90,8 @@ public class CloudControllerServiceUtil {
return isValid;
}
- public static IaasProvider validatePartitionAndGetIaasProvider(Partition partition, IaasProvider iaasProvider) throws InvalidPartitionException {
+ public static IaasProvider validatePartitionAndGetIaasProvider(Partition partition, IaasProvider iaasProvider)
+ throws InvalidPartitionException {
if (iaasProvider != null) {
// if this is a IaaS based partition
Iaas iaas = iaasProvider.getIaas();
@@ -104,7 +108,8 @@ public class CloudControllerServiceUtil {
}
}
- public static boolean validatePartition(Partition partition, IaasProvider iaasProvider) throws InvalidPartitionException {
+ public static boolean validatePartition(Partition partition, IaasProvider iaasProvider)
+ throws InvalidPartitionException {
validatePartitionAndGetIaasProvider(partition, iaasProvider);
return true;
}
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/InstanceCreator.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/InstanceCreator.java b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/InstanceCreator.java
index 34a7c93..02730cf 100644
--- a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/InstanceCreator.java
+++ b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/services/impl/InstanceCreator.java
@@ -27,8 +27,6 @@ import org.apache.stratos.cloud.controller.domain.*;
import org.apache.stratos.cloud.controller.exception.CartridgeNotFoundException;
import org.apache.stratos.cloud.controller.iaases.Iaas;
import org.apache.stratos.cloud.controller.messaging.topology.TopologyBuilder;
-import org.apache.stratos.cloud.controller.statistics.publisher.BAMUsageDataPublisher;
-import org.apache.stratos.messaging.domain.topology.MemberStatus;
import java.util.concurrent.locks.Lock;
@@ -68,7 +66,8 @@ public class InstanceCreator implements Runnable {
memberContext = startInstance(iaas, memberContext, payload);
if (log.isInfoEnabled()) {
- log.info(String.format("Instance started successfully: [cartridge-type] %s [cluster-id] %s [instance-id] %s " +
+ log.info(String.format("Instance started successfully: [cartridge-type] %s [cluster-id] %s " +
+ "[instance-id] %s " +
"[default-private-ip] %s [default-public-ip] %s",
memberContext.getCartridgeType(), memberContext.getClusterId(),
memberContext.getInstanceId(), memberContext.getDefaultPrivateIP(),
@@ -85,15 +84,6 @@ public class InstanceCreator implements Runnable {
// Update topology
TopologyBuilder.handleMemberInitializedEvent(memberContext);
- // Publish instance creation statistics to BAM
- BAMUsageDataPublisher.publish(
- memberContext.getMemberId(),
- memberContext.getPartition().getUuid(),
- memberContext.getNetworkPartitionId(),
- memberContext.getClusterId(),
- memberContext.getCartridgeType(),
- MemberStatus.Initialized.toString(),
- memberContext.getInstanceMetadata());
} catch (Exception e) {
String message = String.format("Could not start instance: [cartridge-type] %s [cluster-id] %s",
memberContext.getCartridgeType(), memberContext.getClusterId());
@@ -105,7 +95,8 @@ public class InstanceCreator implements Runnable {
}
}
- private MemberContext startInstance(Iaas iaas, MemberContext memberContext, byte[] payload) throws CartridgeNotFoundException {
+ private MemberContext startInstance(Iaas iaas, MemberContext memberContext, byte[] payload) throws
+ CartridgeNotFoundException {
memberContext = iaas.startInstance(memberContext, payload);
// Validate instance id
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/statistics/publisher/BAMUsageDataPublisher.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/statistics/publisher/BAMUsageDataPublisher.java b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/statistics/publisher/BAMUsageDataPublisher.java
index d5aabbd..690bc59 100644
--- a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/statistics/publisher/BAMUsageDataPublisher.java
+++ b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/statistics/publisher/BAMUsageDataPublisher.java
@@ -52,12 +52,31 @@ public class BAMUsageDataPublisher {
private static StreamDefinition streamDefinition;
private static final String cloudControllerEventStreamVersion = "1.0.0";
+ /**
+ * Publish events to BAM
+ *
+ * @param memberId member id
+ * @param partitionId partition id
+ * @param networkId network partition id
+ * @param clusterId cluster id
+ * @param clusterInstanceId cluster instance id
+ * @param serviceName service name
+ * @param status member status
+ * @param timeStamp time
+ * @param autoscalingReason scaling reason related to member
+ * @param scalingTime scaling time
+ * @param metadata meta-data
+ */
public static void publish(String memberId,
String partitionId,
String networkId,
String clusterId,
+ String clusterInstanceId,
String serviceName,
String status,
+ Long timeStamp,
+ String autoscalingReason,
+ Long scalingTime,
InstanceMetadata metadata) {
if (!CloudControllerConfig.getInstance().isBAMDataPublisherEnabled()) {
return;
@@ -79,16 +98,23 @@ public class BAMUsageDataPublisher {
MemberContext memberContext = CloudControllerContext.getInstance().getMemberContextOfMemberId(memberId);
String cartridgeType = memberContext.getCartridgeType();
Cartridge cartridge = CloudControllerContext.getInstance().getCartridge(cartridgeType);
+ String instanceType = CloudControllerContext.getInstance().getIaasProviderOfPartition(cartridgeType,
+ partitionId).getProperty(CloudControllerConstants.INSTANCE_TYPE);
//Construct the data to be published
List<Object> payload = new ArrayList<Object>();
// Payload values
+ payload.add(timeStamp);
payload.add(memberId);
payload.add(serviceName);
payload.add(clusterId);
+ payload.add(clusterInstanceId);
payload.add(handleNull(memberContext.getLbClusterId()));
payload.add(handleNull(partitionId));
payload.add(handleNull(networkId));
+ payload.add(handleNull(instanceType));
+ payload.add(handleNull(autoscalingReason));
+ payload.add(handleNull(scalingTime));
if (cartridge != null) {
payload.add(handleNull(String.valueOf(cartridge.isMultiTenant())));
} else {
@@ -129,12 +155,14 @@ public class BAMUsageDataPublisher {
try {
if (log.isDebugEnabled()) {
- log.debug(String.format("Publishing BAM event: [stream] %s [version] %s", streamDefinition.getName(), streamDefinition.getVersion()));
+ log.debug(String.format("Publishing BAM event: [stream] %s [version] %s", streamDefinition.getName(),
+ streamDefinition.getVersion()));
}
dataPublisher.publish(streamDefinition.getName(), streamDefinition.getVersion(), event);
} catch (AgentException e) {
if (log.isErrorEnabled()) {
- log.error(String.format("Could not publish BAM event: [stream] %s [version] %s", streamDefinition.getName(), streamDefinition.getVersion()), e);
+ log.error(String.format("Could not publish BAM event: [stream] %s [version] %s",
+ streamDefinition.getName(), streamDefinition.getVersion()), e);
}
}
}
@@ -151,12 +179,17 @@ public class BAMUsageDataPublisher {
streamDefinition.setDescription("Instances booted up by the Cloud Controller");
// Payload definition
List<Attribute> payloadData = new ArrayList<Attribute>();
+ payloadData.add(new Attribute(CloudControllerConstants.TIME_STAMP, AttributeType.LONG));
payloadData.add(new Attribute(CloudControllerConstants.MEMBER_ID_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.CARTRIDGE_TYPE_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.CLUSTER_ID_COL, AttributeType.STRING));
+ payloadData.add(new Attribute(CloudControllerConstants.CLUSTER_INSTANCE_ID_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.LB_CLUSTER_ID_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.PARTITION_ID_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.NETWORK_ID_COL, AttributeType.STRING));
+ payloadData.add(new Attribute(CloudControllerConstants.INSTANCE_TYPE, AttributeType.STRING));
+ payloadData.add(new Attribute(CloudControllerConstants.SCALING_REASON, AttributeType.STRING));
+ payloadData.add(new Attribute(CloudControllerConstants.SCALING_TIME, AttributeType.LONG));
payloadData.add(new Attribute(CloudControllerConstants.IS_MULTI_TENANT_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.IAAS_COL, AttributeType.STRING));
payloadData.add(new Attribute(CloudControllerConstants.STATUS_COL, AttributeType.STRING));
@@ -210,4 +243,11 @@ public class BAMUsageDataPublisher {
}
return val;
}
+
+ private static Long handleNull(Long val) {
+ if (val == null) {
+ return -1L;
+ }
+ return val;
+ }
}
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/util/CloudControllerConstants.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/util/CloudControllerConstants.java b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/util/CloudControllerConstants.java
index 5e6115f..2cb0c31 100644
--- a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/util/CloudControllerConstants.java
+++ b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/util/CloudControllerConstants.java
@@ -103,6 +103,7 @@ public final class CloudControllerConstants {
public static final String MEMBER_ID_COL = "memberId";
public static final String CARTRIDGE_TYPE_COL = "cartridgeType";
public static final String CLUSTER_ID_COL = "clusterId";
+ public static final String CLUSTER_INSTANCE_ID_COL = "clusterInstanceId";
public static final String PARTITION_ID_COL = "partitionId";
public static final String NETWORK_ID_COL = "networkId";
public static final String ALIAS_COL = "alias";
@@ -122,6 +123,9 @@ public final class CloudControllerConstants {
public static final String PRIV_IP_COL = "privateIPAddresses";
public static final String PUB_IP_COL = "publicIPAddresses";
public static final String ALLOCATE_IP_COL = "allocateIPAddresses";
+ public static final String TIME_STAMP = "timeStamp";
+ public static final String SCALING_REASON = "scalingReason";
+ public static final String SCALING_TIME = "scalingTime";
/**
* Properties
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/constants/StratosConstants.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/constants/StratosConstants.java b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/constants/StratosConstants.java
index 194bd81..55e97d9 100644
--- a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/constants/StratosConstants.java
+++ b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/constants/StratosConstants.java
@@ -91,7 +91,8 @@ public class StratosConstants {
// metering constants
public static final String THROTTLING_ALL_ACTION = "all_actions";
- public static final String THROTTLING_IN_DATA_ACTION = "in_data_action"; //this covers registry capacity + registry bandwidth
+ public static final String THROTTLING_IN_DATA_ACTION =
+ "in_data_action"; //this covers registry capacity + registry bandwidth
public static final String THROTTLING_OUT_DATA_ACTION = "out_data_action"; //this covers registry bandwidth
public static final String THROTTLING_ADD_USER_ACTION = "add_user_action";
public static final String THROTTLING_SERVICE_IN_BANDWIDTH_ACTION = "service_in_bandwith_action";
@@ -158,6 +159,8 @@ public class StratosConstants {
public static final String MAX_CHECK_DROOL_FILE = "maxcheck.drl";
public static final String OBSOLETE_CHECK_DROOL_FILE = "obsoletecheck.drl";
public static final String MIN_COUNT = "MIN_COUNT";
+ public static final String SCALING_REASON = "SCALING_REASON";
+ public static final String SCALING_TIME = "SCALING_TIME";
// Policy and definition related constants
public static final int PUBLIC_DEFINITION = 0;
@@ -165,7 +168,8 @@ public class StratosConstants {
// member expiry timeout constants
public static final String PENDING_MEMBER_EXPIRY_TIMEOUT = "autoscaler.member.pendingMemberExpiryTimeout";
public static final String OBSOLETED_MEMBER_EXPIRY_TIMEOUT = "autoscaler.member.obsoletedMemberExpiryTimeout";
- public static final String PENDING_TERMINATION_MEMBER_EXPIRY_TIMEOUT = "autoscaler.member.pendingTerminationMemberExpiryTimeout";
+ public static final String PENDING_TERMINATION_MEMBER_EXPIRY_TIMEOUT =
+ "autoscaler.member.pendingTerminationMemberExpiryTimeout";
public static final String FILTER_VALUE_SEPARATOR = ",";
public static final String TOPOLOGY_SERVICE_FILTER = "stratos.topology.service.filter";
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/HealthStatisticsPublisher.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/HealthStatisticsPublisher.java b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/HealthStatisticsPublisher.java
index dd7ddd4..95b04ff 100644
--- a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/HealthStatisticsPublisher.java
+++ b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/HealthStatisticsPublisher.java
@@ -27,6 +27,7 @@ public interface HealthStatisticsPublisher extends StatisticsPublisher {
/**
* Publish health statistics to complex event processor.
*
+ * @param timeStamp time
* @param clusterId Cluster id of the member
* @param clusterInstanceId Cluster instance id of the member
* @param networkPartitionId Network partition id of the member
@@ -35,6 +36,6 @@ public interface HealthStatisticsPublisher extends StatisticsPublisher {
* @param health Health type: memory_consumption | load_average
* @param value Health type value
*/
- void publish(String clusterId, String clusterInstanceId, String networkPartitionId,
+ void publish(Long timeStamp, String clusterId, String clusterInstanceId, String networkPartitionId,
String memberId, String partitionId, String health, double value);
}
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/InFlightRequestPublisher.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/InFlightRequestPublisher.java b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/InFlightRequestPublisher.java
index 289be8b..af9c8e9 100644
--- a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/InFlightRequestPublisher.java
+++ b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/InFlightRequestPublisher.java
@@ -27,10 +27,12 @@ public interface InFlightRequestPublisher extends StatisticsPublisher {
/**
* Publish in-flight request count.
*
+ * @param timeStamp time
* @param clusterId Cluster id
* @param clusterInstanceId Cluster instance id
* @param networkPartitionId Network partition id of the cluster
* @param inFlightRequestCount In-flight request count of the cluster
*/
- void publish(String clusterId, String clusterInstanceId, String networkPartitionId, int inFlightRequestCount);
+ void publish(Long timeStamp, String clusterId, String clusterInstanceId, String networkPartitionId,
+ int inFlightRequestCount);
}
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPHealthStatisticsPublisher.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPHealthStatisticsPublisher.java b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPHealthStatisticsPublisher.java
index 1dc4240..d5c9265 100644
--- a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPHealthStatisticsPublisher.java
+++ b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPHealthStatisticsPublisher.java
@@ -52,6 +52,7 @@ public class WSO2CEPHealthStatisticsPublisher extends WSO2CEPStatisticsPublisher
// Set payload definition
List<Attribute> payloadData = new ArrayList<Attribute>();
+ payloadData.add(new Attribute("time_stamp", AttributeType.LONG));
payloadData.add(new Attribute("cluster_id", AttributeType.STRING));
payloadData.add(new Attribute("cluster_instance_id", AttributeType.STRING));
payloadData.add(new Attribute("network_partition_id", AttributeType.STRING));
@@ -70,6 +71,7 @@ public class WSO2CEPHealthStatisticsPublisher extends WSO2CEPStatisticsPublisher
/**
* Publish health statistics to cep.
*
+ * @param timeStamp
* @param clusterId
* @param clusterInstanceId
* @param networkPartitionId
@@ -79,13 +81,16 @@ public class WSO2CEPHealthStatisticsPublisher extends WSO2CEPStatisticsPublisher
* @param value
*/
@Override
- public void publish(String clusterId, String clusterInstanceId, String networkPartitionId, String memberId, String partitionId, String health, double value) {
+ public void publish(Long timeStamp, String clusterId, String clusterInstanceId, String networkPartitionId,
+ String memberId, String partitionId, String health, double value) {
if (log.isDebugEnabled()) {
- log.debug(String.format("Publishing health statistics: [cluster] %s [network-partition] %s [partition] %s [member] %s [health] %s [value] %f",
+ log.debug(String.format("Publishing health statistics: [cluster] %s [network-partition] %s " +
+ "[partition] %s [member] %s [health] %s [value] %f",
clusterId, networkPartitionId, partitionId, memberId, health, value));
}
// Set payload values
List<Object> payload = new ArrayList<Object>();
+ payload.add(timeStamp);
payload.add(clusterId);
payload.add(clusterInstanceId);
payload.add(networkPartitionId);
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPInFlightRequestPublisher.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPInFlightRequestPublisher.java b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPInFlightRequestPublisher.java
index 2ed8883..f51eb91 100644
--- a/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPInFlightRequestPublisher.java
+++ b/components/org.apache.stratos.common/src/main/java/org/apache/stratos/common/statistics/publisher/wso2/cep/WSO2CEPInFlightRequestPublisher.java
@@ -51,6 +51,7 @@ public class WSO2CEPInFlightRequestPublisher extends WSO2CEPStatisticsPublisher
List<Attribute> payloadData = new ArrayList<Attribute>();
// Set payload definition
+ payloadData.add(new Attribute("time_stamp", AttributeType.LONG));
payloadData.add(new Attribute("cluster_id", AttributeType.STRING));
payloadData.add(new Attribute("cluster_instance_id", AttributeType.STRING));
payloadData.add(new Attribute("network_partition_id", AttributeType.STRING));
@@ -65,15 +66,18 @@ public class WSO2CEPInFlightRequestPublisher extends WSO2CEPStatisticsPublisher
/**
* Publish in-flight request count of a cluster.
*
+ * @param timeStamp
* @param clusterId
* @param clusterInstanceId
* @param networkPartitionId
* @param inFlightRequestCount
*/
@Override
- public void publish(String clusterId, String clusterInstanceId, String networkPartitionId, int inFlightRequestCount) {
+ public void publish(Long timeStamp, String clusterId, String clusterInstanceId, String networkPartitionId,
+ int inFlightRequestCount) {
// Set payload values
List<Object> payload = new ArrayList<Object>();
+ payload.add(timeStamp);
payload.add(clusterId);
payload.add(clusterInstanceId);
payload.add(networkPartitionId);
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.load.balancer.common/src/main/java/org/apache/stratos/load/balancer/common/statistics/notifier/LoadBalancerStatisticsNotifier.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.load.balancer.common/src/main/java/org/apache/stratos/load/balancer/common/statistics/notifier/LoadBalancerStatisticsNotifier.java b/components/org.apache.stratos.load.balancer.common/src/main/java/org/apache/stratos/load/balancer/common/statistics/notifier/LoadBalancerStatisticsNotifier.java
index dc2233d..1dd12c7 100644
--- a/components/org.apache.stratos.load.balancer.common/src/main/java/org/apache/stratos/load/balancer/common/statistics/notifier/LoadBalancerStatisticsNotifier.java
+++ b/components/org.apache.stratos.load.balancer.common/src/main/java/org/apache/stratos/load/balancer/common/statistics/notifier/LoadBalancerStatisticsNotifier.java
@@ -81,7 +81,8 @@ public class LoadBalancerStatisticsNotifier implements Runnable {
for (Cluster cluster : service.getClusters()) {
// Publish in-flight request count of load balancer's network partition
int requestCount = statsReader.getInFlightRequestCount(cluster.getClusterId());
- inFlightRequestPublisher.publish(cluster.getClusterId(), clusterInstanceId,
+ inFlightRequestPublisher.publish(System.currentTimeMillis(), cluster.getClusterId(),
+ clusterInstanceId,
networkPartitionId, requestCount);
if (log.isDebugEnabled()) {
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.mock.iaas/src/main/java/org/apache/stratos/mock/iaas/statistics/publisher/MockHealthStatisticsNotifier.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.mock.iaas/src/main/java/org/apache/stratos/mock/iaas/statistics/publisher/MockHealthStatisticsNotifier.java b/components/org.apache.stratos.mock.iaas/src/main/java/org/apache/stratos/mock/iaas/statistics/publisher/MockHealthStatisticsNotifier.java
index c2d1c6c..0dc5e67 100644
--- a/components/org.apache.stratos.mock.iaas/src/main/java/org/apache/stratos/mock/iaas/statistics/publisher/MockHealthStatisticsNotifier.java
+++ b/components/org.apache.stratos.mock.iaas/src/main/java/org/apache/stratos/mock/iaas/statistics/publisher/MockHealthStatisticsNotifier.java
@@ -69,6 +69,7 @@ public class MockHealthStatisticsNotifier implements Runnable {
mockMemberContext.getMemberId(), memoryConsumption));
}
healthStatisticsPublisher.publish(
+ System.currentTimeMillis(),
mockMemberContext.getClusterId(),
mockMemberContext.getClusterInstanceId(),
mockMemberContext.getNetworkPartitionId(),
@@ -93,6 +94,7 @@ public class MockHealthStatisticsNotifier implements Runnable {
mockMemberContext.getMemberId(), loadAvereage));
}
healthStatisticsPublisher.publish(
+ System.currentTimeMillis(),
mockMemberContext.getClusterId(),
mockMemberContext.getClusterInstanceId(),
mockMemberContext.getNetworkPartitionId(),
@@ -116,6 +118,7 @@ public class MockHealthStatisticsNotifier implements Runnable {
mockMemberContext.getMemberId(), requestsInFlight));
}
inFlightRequestPublisher.publish(
+ System.currentTimeMillis(),
mockMemberContext.getClusterId(),
mockMemberContext.getClusterInstanceId(),
mockMemberContext.getNetworkPartitionId(),
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/modules/healthstatspublisher/healthstats.py
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/modules/healthstatspublisher/healthstats.py b/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/modules/healthstatspublisher/healthstats.py
index 9753c3e..aae9e9d 100644
--- a/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/modules/healthstatspublisher/healthstats.py
+++ b/components/org.apache.stratos.python.cartridge.agent/src/main/python/cartridge.agent/cartridge.agent/modules/healthstatspublisher/healthstats.py
@@ -17,7 +17,7 @@
from threading import Thread
import multiprocessing
-
+import time
import psutil
from abstracthealthstatisticspublisher import *
@@ -124,6 +124,7 @@ class HealthStatisticsPublisher:
stream_def.description = HealthStatisticsPublisherManager.STREAM_DESCRIPTION
# stream_def.add_payloaddata_attribute()
+ stream_def.add_payloaddata_attribute("time_stamp", StreamDefinition.LONG)
stream_def.add_payloaddata_attribute("cluster_id", StreamDefinition.STRING)
stream_def.add_payloaddata_attribute("cluster_instance_id", StreamDefinition.STRING)
stream_def.add_payloaddata_attribute("network_partition_id", StreamDefinition.STRING)
@@ -141,6 +142,7 @@ class HealthStatisticsPublisher:
"""
event = ThriftEvent()
+ event.payloadData.append(int(round(time.time() * 1000)))
event.payloadData.append(self.cartridge_agent_config.cluster_id)
event.payloadData.append(self.cartridge_agent_config.cluster_instance_id)
event.payloadData.append(self.cartridge_agent_config.network_partition_id)
@@ -159,6 +161,7 @@ class HealthStatisticsPublisher:
"""
event = ThriftEvent()
+ event.payloadData.append(int(round(time.time() * 1000)))
event.payloadData.append(self.cartridge_agent_config.cluster_id)
event.payloadData.append(self.cartridge_agent_config.cluster_instance_id)
event.payloadData.append(self.cartridge_agent_config.network_partition_id)
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/cep/artifacts/eventformatters/HealthStatsEventFormatter.xml
----------------------------------------------------------------------
diff --git a/extensions/cep/artifacts/eventformatters/HealthStatsEventFormatter.xml b/extensions/cep/artifacts/eventformatters/HealthStatsEventFormatter.xml
new file mode 100644
index 0000000..bcef15f
--- /dev/null
+++ b/extensions/cep/artifacts/eventformatters/HealthStatsEventFormatter.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<eventFormatter name="HealthStatsEventFormatter"
+ statistics="disable" trace="enable" xmlns="http://wso2.org/carbon/eventformatter">
+ <from streamName="cartridge_agent_health_stats" version="1.0.0"/>
+ <mapping customMapping="disable" type="wso2event"/>
+ <to eventAdaptorName="DASDefaultWSO2EventOutputAdaptor" eventAdaptorType="wso2event">
+ <property name="stream">cartridge_agent_health_stats</property>
+ <property name="version">1.0.0</property>
+ </to>
+</eventFormatter>
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/cep/artifacts/eventformatters/RIFEventFormatter.xml
----------------------------------------------------------------------
diff --git a/extensions/cep/artifacts/eventformatters/RIFEventFormatter.xml b/extensions/cep/artifacts/eventformatters/RIFEventFormatter.xml
new file mode 100644
index 0000000..3cfd4a9
--- /dev/null
+++ b/extensions/cep/artifacts/eventformatters/RIFEventFormatter.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<eventFormatter name="RIFEventFormatter" statistics="disable"
+ trace="enable" xmlns="http://wso2.org/carbon/eventformatter">
+ <from streamName="in_flight_requests" version="1.0.0"/>
+ <mapping customMapping="disable" type="wso2event"/>
+ <to eventAdaptorName="DASDefaultWSO2EventOutputAdaptor" eventAdaptorType="wso2event">
+ <property name="stream">in_flight_requests</property>
+ <property name="version">1.0.0</property>
+ </to>
+</eventFormatter>
+
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/cep/artifacts/outputeventadaptors/DASDefaultWSO2EventOutputAdaptor.xml
----------------------------------------------------------------------
diff --git a/extensions/cep/artifacts/outputeventadaptors/DASDefaultWSO2EventOutputAdaptor.xml b/extensions/cep/artifacts/outputeventadaptors/DASDefaultWSO2EventOutputAdaptor.xml
new file mode 100755
index 0000000..5cec300
--- /dev/null
+++ b/extensions/cep/artifacts/outputeventadaptors/DASDefaultWSO2EventOutputAdaptor.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<outputEventAdaptor name="DASDefaultWSO2EventOutputAdaptor"
+ statistics="disable" trace="disable" type="wso2event"
+ xmlns="http://wso2.org/carbon/eventadaptormanager">
+ <property name="username">admin</property>
+ <property name="receiverURL">tcp://localhost:7612</property>
+ <property name="password">admin</property>
+ <property name="authenticatorURL">ssl://localhost:7712</property>
+</outputEventAdaptor>
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/cep/artifacts/streamdefinitions/stream-manager-config.xml
----------------------------------------------------------------------
diff --git a/extensions/cep/artifacts/streamdefinitions/stream-manager-config.xml b/extensions/cep/artifacts/streamdefinitions/stream-manager-config.xml
index 4c4c7e0..a256770 100644
--- a/extensions/cep/artifacts/streamdefinitions/stream-manager-config.xml
+++ b/extensions/cep/artifacts/streamdefinitions/stream-manager-config.xml
@@ -23,287 +23,289 @@
<streamManagerConfiguration xmlns="http://wso2.org/carbon/streammanager">
<!-- in-flight requests stream definitions start -->
<streamDefinition name="in_flight_requests" version="1.0.0">
- <description>in-flight request count</description>
- <nickName>in-flight requests</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="in_flight_request_count" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>in-flight request count</description>
+ <nickName>in-flight requests</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="time_stamp" type="long"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="in_flight_request_count" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="gradient_in_flight_requests" version="1.0.0">
- <description>gradient of in flight request count</description>
- <nickName>gradient in flight requests</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="count" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>gradient of in flight request count</description>
+ <nickName>gradient in flight requests</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="count" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="average_in_flight_requests" version="1.0.0">
- <description>average of in-flight request count</description>
- <nickName>average in-flight requests</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="count" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>average of in-flight request count</description>
+ <nickName>average in-flight requests</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="count" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="second_derivative_in_flight_requests" version="1.0.0">
- <description>second derivative of in-flight request count</description>
- <nickName>second derivative in-flight requests</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="count" type="double"/>
- </payloadData>
+ <description>second derivative of in-flight request count</description>
+ <nickName>second derivative in-flight requests</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="count" type="double"/>
+ </payloadData>
</streamDefinition>
<!-- in-flight requests stream definitions end -->
<!-- cartridge agent health stats stream definitions start -->
<streamDefinition name="cartridge_agent_health_stats" version="1.0.0">
- <description>agent health stats</description>
- <nickName>agent health stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_id" type="String" />
- <property name="partition_id" type="String" />
- <property name="health_description" type="String"/>
- <property name="value" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>agent health stats</description>
+ <nickName>agent health stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="time_stamp" type="long"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_id" type="String"/>
+ <property name="partition_id" type="String"/>
+ <property name="health_description" type="String"/>
+ <property name="value" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="average_load_average_stats" version="1.0.0">
- <description>average load average stats</description>
- <nickName>average load average stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="average_load_average" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>average load average stats</description>
+ <nickName>average load average stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="average_load_average" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="average_memory_consumption_stats" version="1.0.0">
- <description>average memory consumption stats</description>
- <nickName>average memory consumption stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="average_memory_consumption" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>average memory consumption stats</description>
+ <nickName>average memory consumption stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="average_memory_consumption" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="gradient_load_average_stats" version="1.0.0">
- <description>gradient load average stats</description>
- <nickName>gradient load average stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="gradient_load_average" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>gradient load average stats</description>
+ <nickName>gradient load average stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="gradient_load_average" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="gradient_memory_consumption_stats" version="1.0.0">
- <description>gradient memoryconsumption stats</description>
- <nickName>gradient memoryconsumption stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="gradient_memory_consumption" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>gradient memoryconsumption stats</description>
+ <nickName>gradient memoryconsumption stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="gradient_memory_consumption" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="second_derivative_memory_consumption_stats" version="1.0.0">
- <description>second derivative memory consumption stats</description>
- <nickName>second derivative memory consumption stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="second_derivative_memory_consumption" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>second derivative memory consumption stats</description>
+ <nickName>second derivative memory consumption stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="second_derivative_memory_consumption" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="second_derivative_load_average_stats" version="1.0.0">
- <description>second derivative load average stats</description>
- <nickName>second derivative load average stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="second_derivative_load_average" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>second derivative load average stats</description>
+ <nickName>second derivative load average stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="second_derivative_load_average" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="fault_message" version="1.0.0">
- <description>fault message</description>
- <nickName>fault message</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_id" type="String"/>
- <property name="partition_id" type="String"/>
- </payloadData>
+ <description>fault message</description>
+ <nickName>fault message</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_id" type="String"/>
+ <property name="partition_id" type="String"/>
+ </payloadData>
</streamDefinition>
<!-- cartridge agent health stats stream definitions end -->
<!-- This is for member_id wise grouping-->
<streamDefinition name="member_average_load_average_stats" version="1.0.0">
- <description>average load average stats</description>
- <nickName>average load average stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="member_id" type="String" />
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_average_load_average" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>average load average stats</description>
+ <nickName>average load average stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="member_id" type="String"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_average_load_average" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="member_average_memory_consumption_stats" version="1.0.0">
- <description>average memory consumption stats</description>
- <nickName>average memory consumption stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="member_id" type="String"/>
- <property name="cluster_id" type="String"/>
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_average_memory_consumption" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>average memory consumption stats</description>
+ <nickName>average memory consumption stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="member_id" type="String"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_average_memory_consumption" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="member_gradient_load_average_stats" version="1.0.0">
- <description>gradient load average stats</description>
- <nickName>gradient load average stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="member_id" type="String" />
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_gradient_load_average" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>gradient load average stats</description>
+ <nickName>gradient load average stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="member_id" type="String"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_gradient_load_average" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="member_gradient_memory_consumption_stats" version="1.0.0">
- <description>gradient memoryconsumption stats</description>
- <nickName>gradient memoryconsumption stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="member_id" type="String" />
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_gradient_memory_consumption" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>gradient memoryconsumption stats</description>
+ <nickName>gradient memoryconsumption stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="member_id" type="String"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_gradient_memory_consumption" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="member_second_derivative_memory_consumption_stats" version="1.0.0">
- <description>second derivative memory consumption stats</description>
- <nickName>second derivative memory consumption stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="member_id" type="String" />
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_second_derivative_memory_consumption" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>second derivative memory consumption stats</description>
+ <nickName>second derivative memory consumption stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="member_id" type="String"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_second_derivative_memory_consumption" type="double"/>
+ </payloadData>
+ </streamDefinition>
<streamDefinition name="member_second_derivative_load_average_stats" version="1.0.0">
- <description>second derivative load average stats</description>
- <nickName>second derivative load average stats</nickName>
- <metaData>
- </metaData>
- <correlationData>
- </correlationData>
- <payloadData>
- <property name="member_id" type="String" />
- <property name="cluster_id" type="String" />
- <property name="cluster_instance_id" type="String"/>
- <property name="network_partition_id" type="String"/>
- <property name="member_second_derivative_load_average" type="double"/>
- </payloadData>
- </streamDefinition>
+ <description>second derivative load average stats</description>
+ <nickName>second derivative load average stats</nickName>
+ <metaData>
+ </metaData>
+ <correlationData>
+ </correlationData>
+ <payloadData>
+ <property name="member_id" type="String"/>
+ <property name="cluster_id" type="String"/>
+ <property name="cluster_instance_id" type="String"/>
+ <property name="network_partition_id" type="String"/>
+ <property name="member_second_derivative_load_average" type="double"/>
+ </payloadData>
+ </streamDefinition>
</streamManagerConfiguration>
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/README.md
----------------------------------------------------------------------
diff --git a/extensions/das/README.md b/extensions/das/README.md
new file mode 100644
index 0000000..00be297
--- /dev/null
+++ b/extensions/das/README.md
@@ -0,0 +1,10 @@
+# Apache Stratos DAS Extensions
+
+Apache Stratos Data Analytics Server (DAS) extensions include DAS artifacts and spark udf to run spark script.
+These extensions need to be deployed manually when running DAS externally.
+
+Please refer below link for more information on WSO2 DAS.
+https://docs.wso2.com/display/DAS300/WSO2+Data+Analytics+Server+Documentation
+
+Thank you for using Apache Stratos!
+The Stratos Team
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventreceivers/CloudControllerEventReceiver.xml
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventreceivers/CloudControllerEventReceiver.xml b/extensions/das/artifacts/eventreceivers/CloudControllerEventReceiver.xml
new file mode 100644
index 0000000..05789db
--- /dev/null
+++ b/extensions/das/artifacts/eventreceivers/CloudControllerEventReceiver.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<eventReceiver name="CloudControllerEventReceiver" statistics="disable"
+ trace="enable" xmlns="http://wso2.org/carbon/eventreceiver">
+ <from eventAdapterType="wso2event">
+ <property name="events.duplicated.in.cluster">false</property>
+ </from>
+ <mapping customMapping="disable" type="wso2event"/>
+ <to streamName="org.apache.stratos.cloud.controller" version="1.0.0"/>
+</eventReceiver>
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventreceivers/HealthStatsEventReceiver.xml
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventreceivers/HealthStatsEventReceiver.xml b/extensions/das/artifacts/eventreceivers/HealthStatsEventReceiver.xml
new file mode 100644
index 0000000..7e0a5ce
--- /dev/null
+++ b/extensions/das/artifacts/eventreceivers/HealthStatsEventReceiver.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<eventReceiver name="HealthStatsEventReceiver" statistics="disable"
+ trace="enable" xmlns="http://wso2.org/carbon/eventreceiver">
+ <from eventAdapterType="wso2event">
+ <property name="events.duplicated.in.cluster">false</property>
+ </from>
+ <mapping customMapping="disable" type="wso2event"/>
+ <to streamName="cartridge_agent_health_stats" version="1.0.0"/>
+</eventReceiver>
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventreceivers/RIFEventReceiver.xml
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventreceivers/RIFEventReceiver.xml b/extensions/das/artifacts/eventreceivers/RIFEventReceiver.xml
new file mode 100644
index 0000000..b11c016
--- /dev/null
+++ b/extensions/das/artifacts/eventreceivers/RIFEventReceiver.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<eventReceiver name="RIFEventReceiver" statistics="disable"
+ trace="enable" xmlns="http://wso2.org/carbon/eventreceiver">
+ <from eventAdapterType="wso2event">
+ <property name="events.duplicated.in.cluster">false</property>
+ </from>
+ <mapping customMapping="disable" type="wso2event"/>
+ <to streamName="in_flight_requests" version="1.0.0"/>
+</eventReceiver>
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventsink/cartridge_agent_health_stats.xml
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventsink/cartridge_agent_health_stats.xml b/extensions/das/artifacts/eventsink/cartridge_agent_health_stats.xml
new file mode 100644
index 0000000..b870bc2
--- /dev/null
+++ b/extensions/das/artifacts/eventsink/cartridge_agent_health_stats.xml
@@ -0,0 +1,85 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<EventStoreConfiguration>
+ <TableSchema>
+ <ColumnDefinition>
+ <Name>time_stamp</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>LONG</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>cluster_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>cluster_instance_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>network_partition_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>member_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>partition_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>health_description</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>value</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>DOUBLE</Type>
+ </ColumnDefinition>
+ </TableSchema>
+ <Source>
+ <StreamId>cartridge_agent_health_stats:1.0.0</StreamId>
+ </Source>
+ <RecordStoreName>EVENT_STORE</RecordStoreName>
+</EventStoreConfiguration>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventsink/in_flight_requests.xml
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventsink/in_flight_requests.xml b/extensions/das/artifacts/eventsink/in_flight_requests.xml
new file mode 100644
index 0000000..d4ca48b
--- /dev/null
+++ b/extensions/das/artifacts/eventsink/in_flight_requests.xml
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<EventStoreConfiguration>
+ <TableSchema>
+ <ColumnDefinition>
+ <Name>time_stamp</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>LONG</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>cluster_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>cluster_instance_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>network_partition_id</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>in_flight_request_count</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>DOUBLE</Type>
+ </ColumnDefinition>
+ </TableSchema>
+ <Source>
+ <StreamId>in_flight_requests:1.0.0</StreamId>
+ </Source>
+ <RecordStoreName>EVENT_STORE</RecordStoreName>
+</EventStoreConfiguration>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventsink/org_apache_stratos_cloud_controller.xml
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventsink/org_apache_stratos_cloud_controller.xml b/extensions/das/artifacts/eventsink/org_apache_stratos_cloud_controller.xml
new file mode 100644
index 0000000..f0dae09
--- /dev/null
+++ b/extensions/das/artifacts/eventsink/org_apache_stratos_cloud_controller.xml
@@ -0,0 +1,211 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+
+-->
+<EventStoreConfiguration>
+ <TableSchema>
+ <ColumnDefinition>
+ <Name>timeStamp</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>LONG</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>memberId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>cartridgeType</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>clusterId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>clusterInstanceId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>lbclusterId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>partitionId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>networkId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>instanceType</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>scalingReason</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>scalingTime</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>LONG</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>isMultiTenant</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>iaas</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>status</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>hostName</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>hypervisor</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>ram</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>imageId</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>loginPort</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>INTEGER</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>osName</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>osVersion</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>osArch</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>is64bitOS</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>privateIPAddresses</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>publicIPAddresses</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ <ColumnDefinition>
+ <Name>allocateIPAddresses</Name>
+ <EnableIndexing>false</EnableIndexing>
+ <IsPrimaryKey>false</IsPrimaryKey>
+ <EnableScoreParam>false</EnableScoreParam>
+ <Type>STRING</Type>
+ </ColumnDefinition>
+ </TableSchema>
+ <Source>
+ <StreamId>org.apache.stratos.cloud.controller:1.0.0</StreamId>
+ </Source>
+ <RecordStoreName>EVENT_STORE</RecordStoreName>
+</EventStoreConfiguration>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventstreams/cartridge_agent_health_stats_1.0.0.json
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventstreams/cartridge_agent_health_stats_1.0.0.json b/extensions/das/artifacts/eventstreams/cartridge_agent_health_stats_1.0.0.json
new file mode 100644
index 0000000..ec61229
--- /dev/null
+++ b/extensions/das/artifacts/eventstreams/cartridge_agent_health_stats_1.0.0.json
@@ -0,0 +1,40 @@
+{
+ "name": "cartridge_agent_health_stats",
+ "version": "1.0.0",
+ "nickName": "",
+ "description": "",
+ "payloadData": [
+ {
+ "name": "time_stamp",
+ "type": "LONG"
+ },
+ {
+ "name": "cluster_id",
+ "type": "STRING"
+ },
+ {
+ "name": "cluster_instance_id",
+ "type": "STRING"
+ },
+ {
+ "name": "network_partition_id",
+ "type": "STRING"
+ },
+ {
+ "name": "member_id",
+ "type": "STRING"
+ },
+ {
+ "name": "partition_id",
+ "type": "STRING"
+ },
+ {
+ "name": "health_description",
+ "type": "STRING"
+ },
+ {
+ "name": "value",
+ "type": "DOUBLE"
+ }
+ ]
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventstreams/in_flight_requests_1.0.0.json
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventstreams/in_flight_requests_1.0.0.json b/extensions/das/artifacts/eventstreams/in_flight_requests_1.0.0.json
new file mode 100644
index 0000000..8c5232a
--- /dev/null
+++ b/extensions/das/artifacts/eventstreams/in_flight_requests_1.0.0.json
@@ -0,0 +1,28 @@
+{
+ "name": "in_flight_requests",
+ "version": "1.0.0",
+ "nickName": "",
+ "description": "",
+ "payloadData": [
+ {
+ "name": "time_stamp",
+ "type": "LONG"
+ },
+ {
+ "name": "cluster_id",
+ "type": "STRING"
+ },
+ {
+ "name": "cluster_instance_id",
+ "type": "STRING"
+ },
+ {
+ "name": "network_partition_id",
+ "type": "STRING"
+ },
+ {
+ "name": "in_flight_request_count",
+ "type": "DOUBLE"
+ }
+ ]
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/stratos/blob/54283eda/extensions/das/artifacts/eventstreams/org.apache.stratos.cloud.controller_1.0.0.json
----------------------------------------------------------------------
diff --git a/extensions/das/artifacts/eventstreams/org.apache.stratos.cloud.controller_1.0.0.json b/extensions/das/artifacts/eventstreams/org.apache.stratos.cloud.controller_1.0.0.json
new file mode 100644
index 0000000..de1025f
--- /dev/null
+++ b/extensions/das/artifacts/eventstreams/org.apache.stratos.cloud.controller_1.0.0.json
@@ -0,0 +1,112 @@
+{
+ "name": "org.apache.stratos.cloud.controller",
+ "version": "1.0.0",
+ "nickName": "cloud.controller",
+ "description": "Instances booted up by the Cloud Controller",
+ "payloadData": [
+ {
+ "name": "timeStamp",
+ "type": "LONG"
+ },
+ {
+ "name": "memberId",
+ "type": "STRING"
+ },
+ {
+ "name": "cartridgeType",
+ "type": "STRING"
+ },
+ {
+ "name": "clusterId",
+ "type": "STRING"
+ },
+ {
+ "name": "clusterInstanceId",
+ "type": "STRING"
+ },
+ {
+ "name": "lbclusterId",
+ "type": "STRING"
+ },
+ {
+ "name": "partitionId",
+ "type": "STRING"
+ },
+ {
+ "name": "networkId",
+ "type": "STRING"
+ },
+ {
+ "name": "instanceType",
+ "type": "STRING"
+ },
+ {
+ "name": "scalingReason",
+ "type": "STRING"
+ },
+ {
+ "name": "scalingTime",
+ "type": "LONG"
+ },
+ {
+ "name": "isMultiTenant",
+ "type": "STRING"
+ },
+ {
+ "name": "iaas",
+ "type": "STRING"
+ },
+ {
+ "name": "status",
+ "type": "STRING"
+ },
+ {
+ "name": "hostName",
+ "type": "STRING"
+ },
+ {
+ "name": "hypervisor",
+ "type": "STRING"
+ },
+ {
+ "name": "ram",
+ "type": "STRING"
+ },
+ {
+ "name": "imageId",
+ "type": "STRING"
+ },
+ {
+ "name": "loginPort",
+ "type": "INT"
+ },
+ {
+ "name": "osName",
+ "type": "STRING"
+ },
+ {
+ "name": "osVersion",
+ "type": "STRING"
+ },
+ {
+ "name": "osArch",
+ "type": "STRING"
+ },
+ {
+ "name": "is64bitOS",
+ "type": "STRING"
+ },
+ {
+ "name": "privateIPAddresses",
+ "type": "STRING"
+ },
+ {
+ "name": "publicIPAddresses",
+ "type": "STRING"
+ },
+ {
+ "name": "allocateIPAddresses",
+ "type": "STRING"
+ }
+ ]
+}
\ No newline at end of file