You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@drill.apache.org by br...@apache.org on 2019/04/10 17:41:05 UTC

[drill] branch gh-pages updated: add ltsv doc and minor edits

This is an automated email from the ASF dual-hosted git repository.

bridgetb pushed a commit to branch gh-pages
in repository https://gitbox.apache.org/repos/asf/drill.git


The following commit(s) were added to refs/heads/gh-pages by this push:
     new 77cd367  add ltsv doc and minor edits
77cd367 is described below

commit 77cd367f86af84465fb2a4d6e007185ea1a3f0ad
Author: Bridget Bevens <bb...@maprtech.com>
AuthorDate: Wed Apr 10 10:40:06 2019 -0700

    add ltsv doc and minor edits
---
 .../plugins/116-sys-log-format-plugin.md           |  4 +-
 .../plugins/117-ltsv-format-plugin.md              | 51 ++++++++++++++++++++++
 .../040-installing-drill-on-windows.md             | 15 ++++---
 .../050-starting-drill-on-windows.md               | 19 +++++---
 4 files changed, 74 insertions(+), 15 deletions(-)

diff --git a/_docs/connect-a-data-source/plugins/116-sys-log-format-plugin.md b/_docs/connect-a-data-source/plugins/116-sys-log-format-plugin.md
index bb7211b..eb79fa8 100644
--- a/_docs/connect-a-data-source/plugins/116-sys-log-format-plugin.md
+++ b/_docs/connect-a-data-source/plugins/116-sys-log-format-plugin.md
@@ -1,6 +1,6 @@
 ---
 title: "Syslog Format Plugin"
-date: 2019-04-08
+date: 2019-04-10
 parent: "Connect a Data Source"
 ---
 
@@ -9,7 +9,7 @@ Starting in Drill 1.16, Drill provides a syslog format plugin, which enables Dri
 	<165>1 2003-10-11T22:14:15.003Z mymachine.example.com evntslog - ID47 [exampleSDID@32473 iut="3" eventSource="Application" eventID="1011"][examplePriority@32473 class="high"]  
 
 ## Configuration Options
-This syslog format plugin has the following configuration options:
+The syslog format plugin provides the following configuration options:
 
 
 
diff --git a/_docs/connect-a-data-source/plugins/117-ltsv-format-plugin.md b/_docs/connect-a-data-source/plugins/117-ltsv-format-plugin.md
new file mode 100644
index 0000000..a0e84eb
--- /dev/null
+++ b/_docs/connect-a-data-source/plugins/117-ltsv-format-plugin.md
@@ -0,0 +1,51 @@
+---
+title: "LTSV Format Plugin"
+date: 2019-04-08
+parent: "Connect a Data Source"
+---
+
+Starting in Drill 1.16, Drill provides a LTSV (Labeled Tab-separated Values) format plugin, which enables Drill to query files with the .LTSV file extension. LTSV is a text file format. Each line in a LTSV file has the following structure:  
+
+	time:<value> TAB host:<value> TAB forwardedfor:<value> TAB req:<value> TAB status:<value> TAB size:<value> TAB referer:<value> TAB ua:<value> TAB reqtime:<value> TAB apptime:<value> TAB vhost:<value> NEWLINE
+
+For more information about the LTSV file format, see [LTSV (Labeled Tab-separated Values)](http://ltsv.org/).  
+
+##Configuring the LTSV Format Plugin  
+
+Add the LTSV format to the dfs storage plugin configuration, as shown:  
+
+	"formats": {
+	    "ltsv": {
+	      "type": "ltsv",
+	      "extensions": [
+	        "ltsv"
+	      ]
+	    },
+	    ...
+	  }
+
+## Example: Querying a LTSV File  
+
+Each line in a LTSV file has the following structure:
+
+	time:<value> TAB host:<value> TAB forwardedfor:<value> TAB req:<value> TAB status:<value> TAB size:<value> TAB referer:<value> TAB ua:<value> TAB reqtime:<value> TAB apptime:<value> TAB vhost:<value> NEWLINE
+
+
+Sample data:
+
+	time:30/Nov/2016:00:55:08 +0900<TAB>host:xxx.xxx.xxx.xxx<TAB>forwardedfor:-<TAB>req:GET /v1/xxx HTTP/1.1<TAB>status:200<TAB>size:4968<TAB>referer:-<TAB>ua:Java/1.8.0_131<TAB>reqtime:2.532<TAB>apptime:2.532<TAB>vhost:api.example.com
+	time:30/Nov/2016:00:56:37 +0900<TAB>host:xxx.xxx.xxx.xxx<TAB>forwardedfor:-<TAB>req:GET /v1/yyy HTTP/1.1<TAB>status:200<TAB>size:412<TAB>referer:-<TAB>ua:Java/1.8.0_201<TAB>reqtime:3.580<TAB>apptime:3.580<TAB>vhost:api.example.com
+
+
+
+The following query selects the second row from the sample data shown:
+
+
+	0: jdbc:drill:zk=local> SELECT * FROM dfs.`/tmp/sample.ltsv` WHERE reqtime > 3.0;
+	+-----------------------------+------------------+---------------+-----------------------+---------+-------+----------+-----------------+----------+----------+------------------+
+	|            time             |       host       | forwardedfor  |          req          | status  | size  | referer  |       ua        | reqtime  | apptime  |      vhost       |
+	+-----------------------------+------------------+---------------+-----------------------+---------+-------+----------+-----------------+----------+----------+------------------+
+	| 30/Nov/2016:00:56:37 +0900  | xxx.xxx.xxx.xxx  | -             | GET /v1/yyy HTTP/1.1  | 200     | 412   | -        | Java/1.8.0_201  | 3.580    | 3.580    | api.example.com  |
+	+-----------------------------+------------------+---------------+-----------------------+---------+-------+----------+-----------------+----------+----------+------------------+
+	
+	
diff --git a/_docs/install/installing-drill-in-embedded-mode/040-installing-drill-on-windows.md b/_docs/install/installing-drill-in-embedded-mode/040-installing-drill-on-windows.md
index 24c83cd..6ba365e 100644
--- a/_docs/install/installing-drill-in-embedded-mode/040-installing-drill-on-windows.md
+++ b/_docs/install/installing-drill-in-embedded-mode/040-installing-drill-on-windows.md
@@ -1,6 +1,6 @@
 ---
 title: "Installing Drill on Windows"
-date: 2019-04-08
+date: 2019-04-10
 parent: "Installing Drill in Embedded Mode"
 ---
 
@@ -19,10 +19,13 @@ Before you download and install Drill on your Windows machine, complete the foll
 1.	Go to System Properties. 
 2.	On the Advanced Tab, click Environment Variables.  
 ![](https://i.imgur.com/lpytfmu.png)  
-3.	Click New, and enter JAVA_HOME as the variable name. For the variable value, enter the path to your JDK installation. Instead of using `Program Files` in the path name, use `progra~1`. This is required because Drill cannot use file paths with spaces.![](https://i.imgur.com/3CUoNNZ.png)  
-4.	Click OK to continue. 
-5.	In the System Variables section, select Path and then click Edit.![](https://i.imgur.com/nqv68Nu.png)
-6.	In the Edit Environment Variable window, click New and enter `%JAVA_HOME%\bin`.![](https://i.imgur.com/2kevwLV.png)
+3.	Click New, and enter JAVA_HOME as the variable name. For the variable value, enter the path to your JDK installation. If you installed JDK in the default installation location, instead of using `Program Files` in the path name, use `progra~1`. This is required because Drill cannot use file paths with spaces.    
+![](https://i.imgur.com/3CUoNNZ.png)  
+4.	Click OK to continue.   
+5.	In the System Variables section, select Path and then click Edit.  
+![](https://i.imgur.com/nqv68Nu.png)
+6.	In the Edit Environment Variable window, click New and enter `%JAVA_HOME%\bin`.  
+![](https://i.imgur.com/2kevwLV.png)
 7.	Click OK to continue and exit the System Properties window.    
 
 
@@ -41,7 +44,7 @@ You, or the user that will start Drill, must manually create and own UDF directo
 
 2.	To verify that you (or the user that will run Drill) owns the directories and files, go to the `"%userprofile%\drill"` directory, right-click on it, and select Properties from the list.  
 ![](https://i.imgur.com/lLLYOMX.png)
-3.	Verify that you are the owner for all the directories within drill, including the /udf, /registry, /tmp, and /staging directories. If you are not the owner, Edit the permissions. 
+3.	Verify that you are the owner for all the directories within drill, including the /udf, /registry, /tmp, and /staging directories. If you are not the owner, edit the permissions. 
 
 
 ## Download and Install Drill 
diff --git a/_docs/install/installing-drill-in-embedded-mode/050-starting-drill-on-windows.md b/_docs/install/installing-drill-in-embedded-mode/050-starting-drill-on-windows.md
index 82b3ba9..2c72923 100644
--- a/_docs/install/installing-drill-in-embedded-mode/050-starting-drill-on-windows.md
+++ b/_docs/install/installing-drill-in-embedded-mode/050-starting-drill-on-windows.md
@@ -1,27 +1,32 @@
 ---
 title: "Starting Drill on Windows"
-date: 2019-04-08
+date: 2019-04-10
 parent: "Installing Drill in Embedded Mode"
 ---
 Complete the following steps to launch the Drill:
 
 1. Open the Windows command prompt.  
 2. Navigate to the Drill installation folder, for example:  
-`cd \Users\Bridget Bevens\drill_repo\apache-drill-1.16.0-SNAPSHOT` 
+`cd \Users\user1\drill_repo\apache-drill-1.16.0-SNAPSHOT` 
 3. Go to the `bin` directory, for example:  
 `cd bin`
 4. Enter either of the following commands to start Drill:     
 	- `sqlline.bat -u "jdbc:drill:zk=local"`  
     - `drill-embedded.bat` (Supported in Drill 1.16 and later.)  
 
-The Drill prompt appears:  
-
-	"A Drill is a terrible thing to waste."
-	apache drill> 
+			C:\Users\user1\drill_repo\apache-drill-1.16.0-SNAPSHOT\bin>drill-embedded.bat
+		
+			DRILL_ARGS - " -u jdbc:drill:zk=local"
+			HADOOP_HOME not detected...
+			HBASE_HOME not detected...
+			Calculating Drill classpath...
+			Apache Drill 1.16.0-SNAPSHOT
+			"Drill never goes out of style."
+			apache drill>
 
 You can run a test query to verify that Drill is running, for example:  
 
-	//Drill's classpath contains sample data, including an employees.json file that you can query. Switch schema to cp, for classpath.  
+	//Drill's classpath contains sample data, including an employee.json file that you can query. Switch schema to cp, for classpath.  
  
 	apache drill>use cp;
 	+------+--------------------------------+