You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2019/11/07 13:40:14 UTC

[GitHub] [skywalking-cli] kezhenxu94 edited a comment on issue #6: [Feature] Set GraphQL client and add service ls command

kezhenxu94 edited a comment on issue #6: [Feature] Set GraphQL client and add service ls command
URL: https://github.com/apache/skywalking-cli/pull/6#issuecomment-551044006
 
 
   work like this
   ```shell
   skywalking-cli $ ./bin/swctl --config=/Users/kezhenxu/settings.yml service ls 
   [{"id":"4","name":"projectA"},{"id":"2","name":"projectB"},{"id":"5","name":"projectD"},{"id":"3","name":"projectC"}]
   
   
   skywalking-cli $ ./bin/swctl --config=/Users/kezhenxu/settings.yml --debug service ls 
   DEBU[2019-11-07 19:38:43] Debug mode is enabled                        
   DEBU[2019-11-07 19:38:43] Using configuration file: /Users/kezhenxu/settings.yml 
   DEBU[2019-11-07 19:38:43] Configurations:  {"Global":{"BaseUrl":"http://122.112.182.72:8080/graphql"}} 
   DEBU[2019-11-07 19:38:43] Missing --end, defaults to 2019-11-07 1938   
   DEBU[2019-11-07 19:38:43] Missing --start, defaults to 2019-11-07 1923 
   DEBU[2019-11-07 19:38:43] >> variables: map[duration:{2019-11-07 1923 2019-11-07 1938 MINUTE}] 
   DEBU[2019-11-07 19:38:43] >> query: 
   		query ($duration: Duration!) {
   			services: getAllServices(duration: $duration) {
   				id name
   			}
   		}
   	 
   DEBU[2019-11-07 19:38:43] >> headers: map[Accept:[application/json; charset=utf-8] Content-Type:[application/json; charset=utf-8]] 
   DEBU[2019-11-07 19:38:43] << {"data":{"services":[{"id":"2","name":"projectB"},{"id":"4","name":"projectA"},{"id":"5","name":"projectD"},{"id":"3","name":"projectC"}]}} 
   [{"id":"2","name":"projectB"},{"id":"4","name":"projectA"},{"id":"5","name":"projectD"},{"id":"3","name":"projectC"}]
   
   
   skywalking-cli $ ./bin/swctl --config=/Users/kezhenxu/settings.yml --debug service ls --start=2019-10-01 --step=MONTH
   DEBU[2019-11-07 19:39:06] Debug mode is enabled                        
   DEBU[2019-11-07 19:39:06] Using configuration file: /Users/kezhenxu/settings.yml 
   DEBU[2019-11-07 19:39:06] Configurations:  {"Global":{"BaseUrl":"http://122.112.182.72:8080/graphql"}} 
   DEBU[2019-11-07 19:39:06] Missing --end, defaults to 2019-11-07        
   DEBU[2019-11-07 19:39:06] >> variables: map[duration:{2019-10-01 2019-11-07 MONTH}] 
   DEBU[2019-11-07 19:39:06] >> query: 
   		query ($duration: Duration!) {
   			services: getAllServices(duration: $duration) {
   				id name
   			}
   		}
   	 
   DEBU[2019-11-07 19:39:06] >> headers: map[Accept:[application/json; charset=utf-8] Content-Type:[application/json; charset=utf-8]] 
   DEBU[2019-11-07 19:39:06] << {"data":{"services":[{"id":"4","name":"projectA"},{"id":"2","name":"projectB"},{"id":"5","name":"projectD"},{"id":"3","name":"projectC"}]}} 
   [{"id":"4","name":"projectA"},{"id":"2","name":"projectB"},{"id":"5","name":"projectD"},{"id":"3","name":"projectC"}]
   ```

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services