Pages

Saturday, November 17, 2012

MySQL Performance Tuning



SHOW VARIABLES LIKE 'have_query_cache';
SHOW VARIABLES LIKE 'query_cache_size';
SET GLOBAL query_cache_size = 256000000;

Gradle jettyRun debug

To start gradle jettyRun in debug mode, follow the steps below.

Set the GRADLE_OPTS as shown in the screen

$ export GRADLE_OPTS="-Xdebug -Xrunjdwp:transport=dt_socket,address=9999,server=y,suspend=n"
$ gradle jettyRun

Start the jetty server

Jetty server started

Open the debug configuration settings in Eclipse
Click on the debug button to start debugger

Set the breakpoints
Call the methods and debug


Set the debug points in your code and open the URL

http://localhost:9999/komliprime-trafficking-service/api/strategi?authtoken=6991a70eb121f3f623ebc2567927fef5


Truncating log files in UNIX/Linux

Most of the time we need log files to be truncated for many reasons. We can use the below command to truncate the file contents.


sudo cp /dev/null trafficking.log