Skip to content
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

feat: add logging and worker settings to Sentry web deployment #1459

Merged
merged 1 commit into from
Sep 16, 2024

Conversation

patsevanton
Copy link
Contributor

@Mokto This PR introduces new configuration options for the Sentry web deployment, enabling users to customize the log level, log format, and the number of workers. These changes improve the flexibility and performance of the Sentry web deployment.

Changes include:

  • Enabled customization of log level and log format for Sentry web.
  • Added the ability to set the number of workers for better performance.
  • Updated values.yaml to include new configuration options.

This enhancement allows users to better manage and monitor the Sentry web deployment.

@patsevanton
Copy link
Contributor Author

Check with values.yaml:

sentry:
  web:
    logLevel: "DEBUG" # DEBUG|INFO|WARNING|ERROR|CRITICAL|FATAL
    logFormat: "machine" # human|machine
    workers: 1

stern -n test -l role=web

sentry-web-7f95fb7b-flxf5 sentry-web *** Starting uWSGI 2.0.23 (64bit) on [Sun Sep 15 08:27:28 2024] ***
sentry-web-7f95fb7b-flxf5 sentry-web compiled with version: 10.2.1 20210130 (Red Hat 10.2.1-11) on 10 January 2024 21:25:28
sentry-web-7f95fb7b-flxf5 sentry-web os: Linux-5.4.0-174-generic #193-Ubuntu SMP Thu Mar 7 14:29:28 UTC 2024
sentry-web-7f95fb7b-flxf5 sentry-web nodename: sentry-web-7f95fb7b-flxf5
sentry-web-7f95fb7b-flxf5 sentry-web machine: x86_64
sentry-web-7f95fb7b-flxf5 sentry-web clock source: unix
sentry-web-7f95fb7b-flxf5 sentry-web pcre jit disabled
sentry-web-7f95fb7b-flxf5 sentry-web detected number of CPU cores: 6
sentry-web-7f95fb7b-flxf5 sentry-web current working directory: /usr/src/sentry
sentry-web-7f95fb7b-flxf5 sentry-web detected binary path: /.venv/bin/python3
sentry-web-7f95fb7b-flxf5 sentry-web uWSGI running as root, you can use --uid/--gid/--chroot options
sentry-web-7f95fb7b-flxf5 sentry-web *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** 
sentry-web-7f95fb7b-flxf5 sentry-web your memory page size is 4096 bytes
sentry-web-7f95fb7b-flxf5 sentry-web detected max file descriptor number: 1048576
sentry-web-7f95fb7b-flxf5 sentry-web lock engine: pthread robust mutexes
sentry-web-7f95fb7b-flxf5 sentry-web thunder lock: enabled
sentry-web-7f95fb7b-flxf5 sentry-web uWSGI http bound on 0.0.0.0:9000 fd 4
sentry-web-7f95fb7b-flxf5 sentry-web uwsgi socket 0 bound to TCP address 127.0.0.1:42895 (port auto-assigned) fd 3
sentry-web-7f95fb7b-flxf5 sentry-web uWSGI running as root, you can use --uid/--gid/--chroot options
sentry-web-7f95fb7b-flxf5 sentry-web *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** 
sentry-web-7f95fb7b-flxf5 sentry-web Python version: 3.11.8 (main, Mar 12 2024, 11:52:02) [GCC 12.2.0]
sentry-web-7f95fb7b-flxf5 sentry-web --- Python VM already initialized ---
sentry-web-7f95fb7b-flxf5 sentry-web Python main interpreter initialized at 0x7f1b18a54218
sentry-web-7f95fb7b-flxf5 sentry-web uWSGI running as root, you can use --uid/--gid/--chroot options
sentry-web-7f95fb7b-flxf5 sentry-web *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** 
sentry-web-7f95fb7b-flxf5 sentry-web python threads support enabled
sentry-web-7f95fb7b-flxf5 sentry-web your server socket listen backlog is limited to 100 connections
sentry-web-7f95fb7b-flxf5 sentry-web your mercy for graceful operations on workers is 60 seconds
sentry-web-7f95fb7b-flxf5 sentry-web setting request body buffering size to 65536 bytes
sentry-web-7f95fb7b-flxf5 sentry-web mapped 543520 bytes (530 KB) for 2 cores
sentry-web-7f95fb7b-flxf5 sentry-web *** Operational MODE: threaded ***
sentry-web-7f95fb7b-flxf5 sentry-web uWSGI running as root, you can use --uid/--gid/--chroot options
sentry-web-7f95fb7b-flxf5 sentry-web *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** 
sentry-web-7f95fb7b-flxf5 sentry-web spawned uWSGI master process (pid: 1)
sentry-web-7f95fb7b-flxf5 sentry-web spawned uWSGI worker 1 (pid: 7, cores: 2)
sentry-web-7f95fb7b-flxf5 sentry-web spawned uWSGI http 1 (pid: 8)
sentry-web-7f95fb7b-flxf5 sentry-web {"name":"celery.utils.functional","event":"\ndef post_process_group(*args, **kwargs):\n    return 1\n","level":"debug"}
sentry-web-7f95fb7b-flxf5 sentry-web {"name":"celery.utils.functional","event":"\ndef send_activity_notifications(*args, **kwargs):\n    return 1\n","level":"debug"}
sentry-web-7f95fb7b-flxf5 sentry-web {"name":"celery.utils.functional","event":"\ndef reattempt_deletions_control(*args, **kwargs):\n    return 1\n","level":"debug"}

@patsevanton
Copy link
Contributor Author

Hi @Mokto ,

Could you please review and merge this pull request when you have a moment? It's related to issue #1451 and I believe it's ready for integration.

Thank you for your time and consideration!

Copy link
Contributor

@Mokto Mokto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@Mokto Mokto merged commit f0427e2 into sentry-kubernetes:develop Sep 16, 2024
2 checks passed
@Mokto Mokto mentioned this pull request Sep 16, 2024
@patsevanton patsevanton mentioned this pull request Sep 16, 2024
1 task
@patsevanton patsevanton deleted the web branch September 16, 2024 13:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants