danny0405 commented on a change in pull request #1444: [CALCITE-3329] Implement 
osquery for OS adapter
URL: https://github.com/apache/calcite/pull/1444#discussion_r323029232
 
 

 ##########
 File path: site/_docs/os_adapter.md
 ##########
 @@ -258,6 +258,209 @@ $ ./sqlsh select distinct jps.\`pid\`, jps.\`info\` from 
jps
 
 {% endhighlight %}
 
+## Example: system_info
+
+provides a display of system info In `sqlsh`:
+
+{% highlight bash %}
+$ ./sqlsh -o mysql select 
user_name,local_hostname,ip,total_memory,free_memory,cpu_cores,cpu_mhz,os_name,os_arch,os_version
 from system_info
++-----------+----------------+-------------+--------------+-------------+-----------+---------+----------+---------+------------+
+| user_name | local_hostname | ip          | total_memory | free_memory | 
cpu_cores | cpu_mhz | os_name  | os_arch | os_version |
++-----------+----------------+-------------+--------------+-------------+-----------+---------+----------+---------+------------+
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
+| forwardxu | FORWARDXU-MB0  | 10.68.84.42 |    189267968 |   175867248 |      
  12 | 2200    | Mac OS X | x86_64  | 10.14.5    |
 
 Review comment:
   We better not include the real user name and host name in the example.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to