question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Increase default stack size used by launcher when .jvmopts does not specify -Xss

See original GitHub issue

I’m running Bloop 1.4.0-RC1 on linux.

Step 1. bloop clean - works great, np

Step 2. bloop compile root-test - compiles everything doesn’t exit at the end. Zipkin shows that all modules are compiled successfully.

Output looks normal, like this:

> bloop compile root-test
Compiling base-util-jvm (65 Scala sources)
Compiling base-util-js (57 Scala sources)
Compiled base-util-jvm (12100ms)
...
Compiled benchmark-jvm (2953ms)
Compiling benchmark-jvm-test (1 Scala source)
Compiled benchmark-jvm-test (151ms)

and then it hangs and I have to ctrl-C to kill it.

What’s really, really bad about this is that after I ctrl-C, if I run the same command again it recompiles everything (!).

> bloop compile root-test
Compiling base-util-js (57 Scala sources)
Compiling base-util-jvm (65 Scala sources)
Compiled base-util-jvm (4013ms)
...
Deduplicating compilation of base-test from cli client 'bloop-cli' (since 6m 51.545s)
...
Compiled benchmark-jvm (2593ms)
Compiling benchmark-jvm-test (1 Scala source)
Compiled benchmark-jvm-test (116ms)

and then it’s stuck again.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
olafurpgcommented, Feb 12, 2020

I wonder if the bloop launcher should by default increase the stack size if it’s not defined in .jvmopts? It’s normal that compilation requires a deeper stack size than the default and the error is currently quite cryptic when the stack overflows.

0reactions
jvicancommented, Feb 14, 2020
Read more comments on GitHub >

github_iconTop Results From Across the Web

Configuring Stack Sizes in the JVM | Baeldung
Learn how to configure the thread stack sizes in the HotSpot JVM. ... To change the stack size, we can use the -Xss...
Read more >
9.2 Increasing the Stack Size for Recursive Workflows
To increase the stack size, define the new value in the -Xss setting in the JAVA_OPTS entry in your Tomcat start script file...
Read more >
What is the difference between -Xss and -XX:ThreadStackSize?
When I set JAVA_OPTS to -XX:ThreadStackSize=2m , I get about 1000 started threads until the memory is consumed. But, when I use JAVA_OPTS='- ......
Read more >
Java launcher should create JVM from non-primordial thread
On Windows primordial thread stack size is controlled by PE header in the executable. There is no way for user to change it...
Read more >
Increasing the JVM memory allocation and thread stack size
Use one of the following procedures to increase the JVM memory allocation ... Xmx is the maximum memory pool; Xss is the thread...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found