Hi Christian,

I had similar issues when building camel-cassandra on a Linux box with
Java 7. Cassandra spawns a huge amount of threads when running the
component's unit tests. The problem was caused by not having enough
file descriptors available to spawn new threads. This eventually led
to the error message as described in your post.  After increasing the
number of file descriptors per user all tests completed successfully
and I was eventually able to build the component. I used the following
configuration in my limits.conf, but you may need to use other
configuration facilities on your OS X machine:

== /etc/security/limits.conf ====
* soft nofile 32768
* hard nofile 32768
root soft nofile 32768
root hard nofile 32768
[...]
========================

Hope this helps.

Gregor

On Thu, Apr 23, 2015 at 5:35 PM, Christian Müller
<christian.muel...@gmail.com> wrote:
> I have issues by building the camel-cassandraql component:
>
> mvn clean install -Psourcecheck -rf :camel-cassandraql
> ...
> java.lang.OutOfMemoryError: unable to create new native thread
>     at java.lang.Thread.start0(Native Method)
>     at java.lang.Thread.start(Thread.java:714)
>     at
> org.apache.maven.surefire.booter.ForkedBooter.launchLastDitchDaemonShutdownThread(ForkedBooter.java:181)
>     at
> org.apache.maven.surefire.booter.ForkedBooter.exit(ForkedBooter.java:141)
>     at
> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:125)
> java.lang.OutOfMemoryError: unable to create new native thread
>     at java.lang.Thread.start0(Native Method)
>     at java.lang.Thread.start(Thread.java:714)
>     at
> org.apache.maven.surefire.booter.ForkedBooter.launchLastDitchDaemonShutdownThread(ForkedBooter.java:181)
>     at
> org.apache.maven.surefire.booter.ForkedBooter.exit(ForkedBooter.java:141)
>     at
> org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:133)
>
>
> My env:
> Christians-MBP:camel cmueller$ mvn -v
> Apache Maven 3.2.5 (12a6b3acb947671f09b81f49094c53f426d8cea1;
> 2014-12-14T18:29:23+01:00)
> Maven home: /Applications/apache-maven-3.2.5
> Java version: 1.7.0_75, vendor: Oracle Corporation
> Java home:
> /Library/Java/JavaVirtualMachines/jdk1.7.0_75.jdk/Contents/Home/jre
> Default locale: en_US, platform encoding: UTF-8
> OS name: "mac os x", version: "10.10.3", arch: "x86_64", family: "mac"
>
>
> My Maven options:
> -Xmx2048m -XX:MaxPermSize=512m
>
>
> Any ideas?
>
> Thanks in advance,
> Christian
> -----------------
>
> Software Integration Specialist
>
> Apache Member
> V.P. Apache Camel | Apache Camel PMC Member | Apache Camel committer
> Apache Incubator PMC Member
>
> https://www.linkedin.com/pub/christian-mueller/11/551/642

Reply via email to