OliverKeyes has submitted this change and it was merged.
Change subject: Switch from hive cli to beeline
......................................................................
Switch from hive cli to beeline
Bug: T116291
Change-Id: If5a6a592e59cbbfe0735cffc72f44bad7c8ed0e3
---
M CHANGELOG.md
M common.R
2 files changed, 11 insertions(+), 1 deletion(-)
Approvals:
OliverKeyes: Verified; Looks good to me, approved
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 4fcf32d..81c51ad 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,6 +1,9 @@
# Change Log (Patch Notes)
All notable changes to this project will be documented in this file.
+## 2015/10/26
+- Switches Varnish-querying script from Hive CLI (deprecated) to Beeline
+
## 2015/10/22
- Fixes LDN (survival) code
diff --git a/common.R b/common.R
index 202ec46..3a192b7 100644
--- a/common.R
+++ b/common.R
@@ -53,7 +53,14 @@
# Query and read in the results
try({
- system(paste0("export HADOOP_HEAPSIZE=1024 && hive -S -f ", query_dump, "
> ", results_dump))
+ system(paste("export HADOOP_HEAPSIZE=1024 && beeline",
+ "--showHeader=true", # show column names in query results
+ "--verbose=false", # show verbose error messages and debug
info
+ "--silent=true", # be more silent
+ "--outputformat=tsv2", # format mode for result display
+ "-u jdbc:hive2://", # very important! this is how you connect!
+ "-f", query_dump, # script file that should be executed
+ ">", results_dump))
results <- read.delim(results_dump, sep = "\t", quote = "", as.is = TRUE,
header = TRUE)
})
--
To view, visit https://gerrit.wikimedia.org/r/248940
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: If5a6a592e59cbbfe0735cffc72f44bad7c8ed0e3
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/discovery/golden
Gerrit-Branch: master
Gerrit-Owner: Bearloga <[email protected]>
Gerrit-Reviewer: Bearloga <[email protected]>
Gerrit-Reviewer: OliverKeyes <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits