Skip to content

Commit

Permalink
Fix #1230 Increase default JFR stack depth to 256 frames (from 64) (#…
Browse files Browse the repository at this point in the history
…1282)

Increase default JFR stack depth to 256 frames (from 64)
  • Loading branch information
carterkozak authored Jan 27, 2022
1 parent 2f924df commit 02feb38
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
5 changes: 5 additions & 0 deletions changelog/@unreleased/pr-1282.v2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
type: improvement
improvement:
description: Increase default JFR stack depth to 256 frames (from 64)
links:
- https://github.com/palantir/sls-packaging/pull/1282
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,11 @@ public abstract class LaunchConfigTask extends DefaultTask {
// Set DNS cache TTL to 20s to account for systems such as RDS and other
// AWS-managed systems that modify DNS records on failover.
"-Dsun.net.inetaddr.ttl=20",
"-XX:NativeMemoryTracking=summary");
"-XX:NativeMemoryTracking=summary",
// Increase default JFR stack depth beyond the default (conservative) 64 frames.
// This can be overridden by user-provided options.
// See sls-packaging#1230
"-XX:FlightRecorderOptions=stackdepth=256");

// Reduce memory usage for some versions of glibc.
// Default value is 8 * CORES.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,7 @@ class JavaServiceDistributionPluginTests extends GradleIntegrationSpec {
'-XX:HeapDumpPath=var/log',
'-Dsun.net.inetaddr.ttl=20',
'-XX:NativeMemoryTracking=summary',
'-XX:FlightRecorderOptions=stackdepth=256',
'-XX:+UseParallelGC',
'-Xmx4M',
'-Djavax.net.ssl.trustStore=truststore.jks'])
Expand All @@ -431,6 +432,7 @@ class JavaServiceDistributionPluginTests extends GradleIntegrationSpec {
'-XX:HeapDumpPath=var/log',
'-Dsun.net.inetaddr.ttl=20',
'-XX:NativeMemoryTracking=summary',
'-XX:FlightRecorderOptions=stackdepth=256',
'-Xmx4M',
'-Djavax.net.ssl.trustStore=truststore.jks'])
.env(LaunchConfigTask.defaultEnvironment)
Expand Down Expand Up @@ -469,6 +471,7 @@ class JavaServiceDistributionPluginTests extends GradleIntegrationSpec {
'-XX:HeapDumpPath=var/log',
'-Dsun.net.inetaddr.ttl=20',
'-XX:NativeMemoryTracking=summary',
'-XX:FlightRecorderOptions=stackdepth=256',
"-XX:+PrintGCDateStamps",
"-XX:+PrintGCDetails",
"-XX:-TraceClassUnloading",
Expand Down

0 comments on commit 02feb38

Please sign in to comment.