Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Cassandra Wiki" for 
change notification.

The "HowToDebug" page has been changed by DaveBrosius:
http://wiki.apache.org/cassandra/HowToDebug

New page:
= How to debug Cassandra in Eclipse =

{{{In order to debug in Eclipse in Linux you may need to launch the Cassandra 
process with the sudo account. 
   To do this with Eclipse, you must launch Eclipse with sudo/gksudo. By doing 
this, processed launched from
   Eclipse will also be run under that account}}}

== Create Project in Eclipse ==

 1. Create a new Java Project in Eclipse

 1. Add the following directories as source folders

   2. src/gen-java
   2. interface/thrift/gen-java
   2. src/resources
   2. src/java
   2. src/avro

 1. Set the target directory for classes to build/classes

 1. Add the following jars to the eclipse project

   2. All jars in lib

   2. build/lib/hadoop-core-*.jar and build/lib/jna-*.jar

 1. Create a Debug Configuration

   2. Use org.apache.cassandra.thrift.CassandraDaemon as the main class

   2. Put the following parameters in the VM args section
{{{
-ea -javaagent:${project_loc}/lib/jamm-0.2.5.jar -XX:+UseThreadPriorities 
-XX:ThreadPriorityPolicy=42 -Xms752M -Xmx752M -Xmn188M 
-XX:+HeapDumpOnOutOfMemoryError -Xss128k -XX:+UseParNewGC 
-XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:SurvivorRatio=8 
-XX:MaxTenuringThreshold=1 -XX:CMSInitiatingOccupancyFraction=75 
-XX:+UseCMSInitiatingOccupancyOnly -Djava.net.preferIPv4Stack=true 
-Dcom.sun.management.jmxremote.port=7199 
-Dcom.sun.management.jmxremote.ssl=false 
-Dcom.sun.management.jmxremote.authenticate=false 
-Dlog4j.configuration=log4j-server.properties -Dlog4j.defaultInitOverride=true
}}}

 

 

 


Reply via email to