You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spot.apache.org by ev...@apache.org on 2017/07/21 20:21:13 UTC

[14/50] [abbrv] incubator-spot git commit: Fixing shifted fields and table schema for flow ingest summary

Fixing shifted fields and table schema for flow ingest summary


Project: http://git-wip-us.apache.org/repos/asf/incubator-spot/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-spot/commit/73b71619
Tree: http://git-wip-us.apache.org/repos/asf/incubator-spot/tree/73b71619
Diff: http://git-wip-us.apache.org/repos/asf/incubator-spot/diff/73b71619

Branch: refs/heads/master
Commit: 73b716196d1b98dded849d7c540eb601fd9c0f87
Parents: ffa5b87
Author: Moy Valdovinos <mo...@gmail.com>
Authored: Fri Jun 23 18:46:58 2017 -0500
Committer: LedaLima <ga...@intel.com>
Committed: Tue Jul 4 18:55:44 2017 -0500

----------------------------------------------------------------------
 spot-setup/migration/create_flow_migration_tables.hql | 5 +++--
 spot-setup/migration/migrate_old_flow_data.sh         | 2 +-
 2 files changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-spot/blob/73b71619/spot-setup/migration/create_flow_migration_tables.hql
----------------------------------------------------------------------
diff --git a/spot-setup/migration/create_flow_migration_tables.hql b/spot-setup/migration/create_flow_migration_tables.hql
index 6e87ec3..453d14f 100644
--- a/spot-setup/migration/create_flow_migration_tables.hql
+++ b/spot-setup/migration/create_flow_migration_tables.hql
@@ -11,10 +11,11 @@ dstip STRING,
 sport INT, 
 dport INT, 
 proto STRING,
-flag STRING,
 ipkt INT,
 ibyt INT,
-lda_score FLOAT,
+opkt INT,
+obyt INT,
+score FLOAT,
 rank INT,
 srcIpInternal INT,
 destIpInternal INT,

http://git-wip-us.apache.org/repos/asf/incubator-spot/blob/73b71619/spot-setup/migration/migrate_old_flow_data.sh
----------------------------------------------------------------------
diff --git a/spot-setup/migration/migrate_old_flow_data.sh b/spot-setup/migration/migrate_old_flow_data.sh
index 42534bb..4a7e04c 100755
--- a/spot-setup/migration/migrate_old_flow_data.sh
+++ b/spot-setup/migration/migrate_old_flow_data.sh
@@ -76,7 +76,7 @@ do
     hive -e "$command"
 
     command="INSERT INTO $DEST_DB.flow_scores PARTITION (y=$y, m=$m, d=$d) 
-select tstart,srcip,dstip,sport,dport,proto,ipkt,ibyt,0,0,lda_score,rank,srcIpInternal,destIpInternal,srcGeo,dstGeo,srcDomain,dstDomain,srcIP_rep,dstIP_rep 
+select tstart,srcip,dstip,sport,dport,proto,ipkt,ibyt,opkt,obyt,score,rank,srcIpInternal,destIpInternal,srcGeo,dstGeo,srcDomain,dstDomain,srcIP_rep,dstIP_rep 
 from $STAGING_DB.flow_scores_tmp;"
     echo $command
     hive -e "$command"