Wednesday, December 14, 2016
Wednesday, November 30, 2016
Tuesday, November 29, 2016
Wednesday, September 7, 2016
Generate FlameGraph for your java projects
1) Clone the lightweight-java-profiler: git clone https://github.com/dcapwell/lightweight-java-profiler.git
2) Go to it : cd lightweight-java-profiler/
3) Compile it: make all
4) Add this to the VM Options : -agentpath:/space/projects/lightweight-java-profiler/build-64/liblagent.so
Now we need something to display this data..
It is the FlameGraph : https://github.com/brendangregg/FlameGraph
6) Get the FlameGraph : git clone https://github.com/brendangregg/FlameGraph.git
7) Execute the following command under the FlameGraph directory $: ./stackcollapse-ljp.awk < /pathToThe_traces_file/traces.txt | ./flamegraph.pl > traces.svg
8) Open the travces.svg with firefox
firefox travces.svg
9) Press Enter
10) bye
Thursday, September 1, 2016
intellij show spring beans near line number
File > Project Structure > Facets > Click the green + icon in the middle Panel > Select Spring
After Applying You will be seeing the Bean Definition Pointers as shown below
Wednesday, August 24, 2016
Saturday, March 19, 2016
Unix sniff network traffic on specific port with tcpflow
Install it : sudo apt-get install tcpflow
Run the command on console : sudo tcpflow -i any -C -J port 1234
sunels@sunels:~$ sudo tcpflow -i any -C -J port 8888
tcpflow: listening on any
GET /hi?name=serkan, HTTP/1.1
Host: localhost:8888
Connection: keep-alive
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/48.0.2564.116 Chrome/48.0.2564.116 Safari/537.36
Accept-Encoding: gzip, deflate, sdch
Accept-Language: en-US,en;q=0.8
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: text/html;charset=UTF-8
Content-Length: 18
Date: Sat, 19 Mar 2016 20:22:39 GMT
Hi there, serkan,!
Run the command on console : sudo tcpflow -i any -C -J port 1234
sunels@sunels:~$ sudo tcpflow -i any -C -J port 8888
tcpflow: listening on any
GET /hi?name=serkan, HTTP/1.1
Host: localhost:8888
Connection: keep-alive
Cache-Control: max-age=0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Upgrade-Insecure-Requests: 1
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/48.0.2564.116 Chrome/48.0.2564.116 Safari/537.36
Accept-Encoding: gzip, deflate, sdch
Accept-Language: en-US,en;q=0.8
HTTP/1.1 200 OK
Server: Apache-Coyote/1.1
Content-Type: text/html;charset=UTF-8
Content-Length: 18
Date: Sat, 19 Mar 2016 20:22:39 GMT
Hi there, serkan,!
Subscribe to:
Posts (Atom)