Skip to content

feat: reduce stack-size of threads #774

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions sentry-core/src/session.rs
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,7 @@ mod session_impl {
let worker_shutdown = shutdown.clone();
let worker = std::thread::Builder::new()
.name("sentry-session-flusher".into())
.stack_size(100 * 1024)
.spawn(move || {
let (lock, cvar) = worker_shutdown.as_ref();
let mut shutdown = lock.lock().unwrap();
Expand Down
1 change: 1 addition & 0 deletions sentry/src/transports/thread.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ impl TransportThread {
let shutdown_worker = shutdown.clone();
let handle = thread::Builder::new()
.name("sentry-transport".into())
.stack_size(500 * 1024)
.spawn(move || {
let mut rl = RateLimiter::new();

Expand Down
1 change: 1 addition & 0 deletions sentry/src/transports/tokio_thread.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ impl TransportThread {
let shutdown_worker = shutdown.clone();
let handle = thread::Builder::new()
.name("sentry-transport".into())
.stack_size(500 * 1024)
.spawn(move || {
// create a runtime on the transport thread
let rt = tokio::runtime::Builder::new_current_thread()
Expand Down