Check for multiple versions of httpcore .jar in the class path and remove if any. If there are duplicates, it reads the one which appears first in your classpath.
- Check classpath in Eclipse: Run > Run Configurations > Classpath
- Leave only project dependencies: Select the project > Edit > Edit Runtime classpath > check "Only include exported entries" > Ok > Run
Showing posts with label Apache Stanbol. Show all posts
Showing posts with label Apache Stanbol. Show all posts
Wednesday, November 6, 2013
Monday, November 4, 2013
Fixing java.lang.OutOfMemoryError: PermGen space error in Apache Stanbol
If you get the above error when launching the full launcher in debug mode use the following command to overcome the issue:
java -Xms256m -Xmx1024m -XX:PermSize=512m -XX:MaxPermSize=512m -Xdebug -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n -jar org.apache.stanbol.launchers.full-0.10.0-SNAPSHOT.jar -p 8080
Some more info. on the Java PermGen space for those who want to go beyond fixing the issue :).
This memory slot is reserved for long term objects which are not garbage collected by default. And if there is a memory leak in PermGen space, setting -Xmx won't help as this is not stored in general heap. Reason for OutOfMemory issue in PermGen is a memory leak in the Class loader.
java -Xms256m -Xmx1024m -XX:PermSize=512m -XX:MaxPermSize=512m -Xdebug -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n -jar org.apache.stanbol.launchers.full-0.10.0-SNAPSHOT.jar -p 8080
Some more info. on the Java PermGen space for those who want to go beyond fixing the issue :).
This memory slot is reserved for long term objects which are not garbage collected by default. And if there is a memory leak in PermGen space, setting -Xmx won't help as this is not stored in general heap. Reason for OutOfMemory issue in PermGen is a memory leak in the Class loader.
Subscribe to:
Posts (Atom)