This article is based on Skywalking 6.6.0 To write , theoretical support Skywalking 6.0+ All versions .
This article discusses how to use Skywalking Monitoring applications .
Skywalking There are many ways of using , Most popular at present ( And the most powerful ) Is based on Java agent Of .
Java agent Supported framework 、 Middleware etc. , Can be found in
https://github.com/apache/skywalking/blob/v6.6.0/docs/en/setup/service-agent/java-agent/Supported-list.md see .
- except Java agent Out of the way ,Skywalking It also supports other languages agent, See
- Besides ,Skywalking It also supports Service Mesh（ for example Istio, See
https://github.com/apache/skywalking/blob/v6.6.0/docs/en/setup/README.md#service-mesh）、Proxy（ for example Envoy Proxy, See
https://github.com/apache/skywalking/blob/v6.6.0/docs/en/setup/README.md#service-mesh） , But these two ways of using are not very popular at present , So I don't want to repeat it , In fact, it is also relatively simple . Interested children's shoes can also be studied .
find SkyWalking In bag
agentCatalog ,agent The directory structure is as follows
agentCopy directory to any location
- To configure
agent.service_nameChange it to your microservice name ;
- If Skywalking And microservices are deployed on different servers , It needs to be modified
collector.backend_serviceValue , This configuration is used to specify microservices and Skywalking Address of correspondence , The default is
127.0.0.1:11800, Modify as needed . Of course
agent.configThere's a lot of configuration in the file , The table below explains in detail .
for example , There is one Spring Boot application , Then we have finished modifying
agent After the directory ：
Execute the following command to start ：
Be careful -javaagent You have to -jar Before, oh
java -javaagent:/opt/agent/skywalking-agent.jar -jar somr-spring-boot.jar
If you want to IDE Start the test in , Please refer to the following figure for configuration , Then start .
tomcat/bin/catalina.sh The first line of ：
CATALINA_OPTS="$CATALINA_OPTS -javaagent:/opt/agent/skywalking-agent.jar"; export CATALINA_OPTS
tomcat/bin/catalina.bat The first line of ：
Use Skywalking After monitoring the application , When an application API When interviewed , It will show a chart like this .
home page ：
Network topology ： Can analyze the network destination of the request . Such as below , The request was called first foodie-dev This micro service , And then asked for
localhost:3306 This MySQL database .
track ： This navigation bar is the most common one we use to locate problems , You can search for specific details of the query . Locate where the performance bottleneck lies .
The alarm ： seeing the name of a thing one thinks of its function .Skywalking Configurable alarm rules , When the configured threshold is exceeded , Push the alarm information .
Index comparison ： Any indicator can be compared .