MCPcopy Create free account

hub / github.com/benoitc/gunicorn / functions

Functions4,571 in github.com/benoitc/gunicorn

↓ 13 callersMethodexecute_async
Execute an action on a dirty app (async/non-blocking). Args: app_path: Import path of the dirty app action:
gunicorn/dirty/client.py:223
↓ 13 callersMethodfeed_eof
Signal that the connection has been closed.
gunicorn/asgi/websocket.py:95
↓ 13 callersMethodfileno
(self)
gunicorn/workers/workertmp.py:49
↓ 13 callersFunctionload_dirty_app
Load a dirty app class from an import path. Args: import_path: String in format 'module.path:ClassName' Returns: An ins
gunicorn/dirty/app.py:215
↓ 13 callersMethodstream_async
Stream results from a dirty app action (async). This method returns an async iterator that yields chunks from a streaming re
gunicorn/dirty/client.py:279
↓ 13 callersMethodwrite
(self, data)
tests/test_dirty_worker.py:61
↓ 13 callersMethodwrite_message
Write one message to a socket. Args: sock: Socket to write to data: Message dictionary to send
gunicorn/ctl/protocol.py:121
↓ 12 callersMethod_get_reason_phrase
Get HTTP reason phrase for status code.
gunicorn/asgi/protocol.py:1423
↓ 12 callersMethodclose
(self)
tests/dirty/test_client_streaming.py:51
↓ 12 callersMethoddebug
(self, msg, *args, **kwargs)
gunicorn/glogging.py:289
↓ 12 callersFunctiondrain_body
Drain the request body.
tests/docker/asgi_compliance/apps/http_app.py:578
↓ 12 callersMethodhandle_exit
(self, sig, frame)
gunicorn/workers/base.py:185
↓ 12 callersFunctionmake_error_response
Create an error response message. Args: request_id: Request identifier being responded to error: Error message Returns:
gunicorn/ctl/protocol.py:209
↓ 12 callersFunctionparse_dirty_app_spec
Parse a dirty app specification. Supports two formats: - ``"module:Class"`` - standard format, all workers load the app - ``"module:
gunicorn/dirty/app.py:140
↓ 12 callersMethodread_message_async
Read one message from an async reader. Args: reader: asyncio StreamReader Returns: Decoded message
gunicorn/ctl/protocol.py:133
↓ 12 callersMethodrecv
(self, length=None)
tests/t.py:51
↓ 12 callersMethodstart
\ Initialize the arbiter. Start listening and set pidfile if needed.
gunicorn/arbiter.py:166
↓ 12 callersMethodupdate_priority
Update stream priority from PRIORITY frame. Args: weight: Priority weight (1-256), higher = more resources depends_on
gunicorn/http2/stream.py:254
↓ 11 callersMethod_build_http2_scope
Build ASGI HTTP scope from HTTP/2 request.
gunicorn/asgi/protocol.py:1744
↓ 11 callersMethod_close_transport
Close the transport safely. Calls write_eof() first if supported to signal end of writing, which helps ensure buffered data is flushe
gunicorn/asgi/protocol.py:1462
↓ 11 callersFunction_get_client
Get or create a thread-local stash client.
gunicorn/dirty/stash.py:439
↓ 11 callersMethodclear
Delete all entries.
gunicorn/dirty/stash.py:392
↓ 11 callersMethodconnect
Establish sync socket connection to arbiter. Raises: DirtyConnectionError: If connection fails
gunicorn/dirty/client.py:59
↓ 11 callersMethodhandle
(self, listener, client, addr)
gunicorn/workers/sync.py:134
↓ 11 callersFunctionmake_stash_message
Build a stash operation message dict. Args: request_id: Unique request identifier (int or str) op: Stash operation code (STA
gunicorn/dirty/protocol.py:762
↓ 11 callersMethodreceive
ASGI receive callable - returns body chunks or disconnect.
gunicorn/asgi/protocol.py:213
↓ 11 callersMethodsend_command
Send command and wait for response. Args: command: Command string (e.g., "show workers") args: Optional addi
gunicorn/ctl/client.py:74
↓ 11 callersMethodstartup
Run lifespan startup and wait for completion. Raises: RuntimeError: If startup fails or app doesn't support lifespan
gunicorn/asgi/lifespan.py:53
↓ 10 callersMethod_execute
Execute a stash operation. Args: op: Operation code (STASH_OP_*) table: Table name key: Optional
gunicorn/dirty/stash.py:137
↓ 10 callersMethodaccess
Measure request duration request_time is a datetime.timedelta
gunicorn/instrument/statsd.py:96
↓ 10 callersMethodclear_sent
(self)
tests/test_http2_integration.py:65
↓ 10 callersMethodencode_header
Encode the 16-byte message header. Args: msg_type: Message type (MSG_TYPE_REQUEST, etc.) request_id: Unique
gunicorn/dirty/protocol.py:115
↓ 10 callersMethodfinish_body
Discard any unread body of the current message. Called before returning a keepalive connection to the poller so the socket does not a
gunicorn/http/parser.py:38
↓ 10 callersMethodget_client
Create HTTP/2 client.
examples/http2_gevent/test_http2_gevent.py:59
↓ 10 callersMethodget_gunicorn_pids
Get PIDs of gunicorn processes. Uses ps output with proctitle if available, otherwise falls back to process tree analysis.
tests/docker/dirty_arbiter/test_parent_death.py:132
↓ 10 callersMethodget_sent_data
(self)
tests/test_early_hints.py:91
↓ 10 callersMethodget_written_data
(self)
tests/test_http2_async_connection.py:83
↓ 10 callersMethodgetsockname
(self)
tests/test_gthread.py:53
↓ 10 callersMethodhandle_request
Handle a single request message. Supports both regular (non-streaming) and streaming responses. For streaming, detects if th
gunicorn/dirty/worker.py:315
↓ 10 callersMethodinfo
(self, msg, *args)
examples/dirty_example/test_worker_integration.py:31
↓ 10 callersMethodroute_request
Route a request to an available dirty worker via queue. Each worker has a dedicated queue and consumer task. Requests are su
gunicorn/dirty/arbiter.py:445
↓ 10 callersMethodstop
\ Stop workers :attr graceful: boolean, If True (the default) workers will be killed gracefully (ie. trying to wait for the
gunicorn/arbiter.py:443
↓ 10 callersMethodvalues
Iterate over values.
gunicorn/dirty/stash.py:401
↓ 10 callersMethodwrite_message_async
Write a message to async stream. Accepts dict format for backwards compatibility. Args: writer: asyncio StreamW
gunicorn/dirty/protocol.py:468
↓ 9 callersMethod_build_environ
Build minimal WSGI-like environ dict for access logging.
gunicorn/asgi/protocol.py:1182
↓ 9 callersFunction_cfg
(http_parser, **overrides)
tests/test_header_policy_parity.py:30
↓ 9 callersMethod_is_websocket_upgrade
Check if request is a WebSocket upgrade. Per RFC 6455 Section 4.1, the opening handshake requires: - HTTP method MUST be GET
gunicorn/asgi/protocol.py:904
↓ 9 callersFunction_parse
(raw, cfg, peer_addr)
tests/test_header_policy_parity.py:25
↓ 9 callersMethod_read_exact
Read exactly size bytes from the unreader.
gunicorn/uwsgi/message.py:116
↓ 9 callersMethodclear
(self)
tests/test_early_hints.py:94
↓ 9 callersMethodclose
Close the connection gracefully with GOAWAY. Args: error_code: HTTP/2 error code (default: NO_ERROR) last_stream_id:
gunicorn/http2/connection.py:610
↓ 9 callersMethodclose
Cleanup on shutdown.
examples/dirty_example/dirty_app.py:112
↓ 9 callersFunctioncreate_arbiter
Create a test arbiter with mocked components.
tests/dirty/test_arbiter_streaming.py:85
↓ 9 callersFunctioncreate_client_with_mock_socket
Create a client with a mock socket returning the given messages.
tests/dirty/test_client_streaming.py:55
↓ 9 callersFunctiondrain_body
Drain the request body.
tests/docker/asgi_compliance/apps/streaming_app.py:471
↓ 9 callersMethodget_header
Get a header value by name. Args: name: Header name (case-insensitive) Returns: str: Header value, or None i
gunicorn/http2/request.py:186
↓ 9 callersMethodread
Read data from the body. Args: size: Number of bytes to read, or None for all remaining Returns: bytes: The
gunicorn/http2/request.py:33
↓ 9 callersMethodreadline
(self, size=None)
gunicorn/http/body.py:238
↓ 9 callersMethodseek
(self, offset, whence=0)
tests/t.py:65
↓ 9 callersMethodset_complete
Mark body as complete (called when message ends).
gunicorn/asgi/protocol.py:193
↓ 9 callersMethodsettimeout
(self, timeout)
benchmarks/dirty_streaming.py:541
↓ 9 callersMethodsignal
Signal handler - NO LOGGING, just queue the signal.
gunicorn/arbiter.py:238
↓ 9 callersMethodsignal_disconnect
Signal that the client transport has gone away.
gunicorn/asgi/protocol.py:198
↓ 9 callersMethodstart
Start the dirty arbiter and workers.
benchmarks/dirty_benchmark.py:217
↓ 9 callersMethodstop
Stop the dirty arbiter.
benchmarks/dirty_benchmark.py:258
↓ 8 callersMethod__init__
(self, message, details=None)
gunicorn/dirty/errors.py:15
↓ 8 callersMethod_build_websocket_scope
Build ASGI WebSocket scope from parsed request.
gunicorn/asgi/protocol.py:1200
↓ 8 callersMethod_cleanup_worker
Clean up after a worker exits. Saves the dead worker's app list to pending respawns so the replacement worker gets the same
gunicorn/dirty/arbiter.py:1015
↓ 8 callersMethod_create_mock_request
Create a mock HTTP request.
tests/test_asgi_http_scope.py:665
↓ 8 callersMethod_create_protocol
Create an ASGIProtocol instance for testing.
tests/test_asgi_http_scope.py:654
↓ 8 callersMethod_create_protocol
Create a WebSocketProtocol instance for testing.
tests/test_asgi_websocket_protocol.py:748
↓ 8 callersMethod_get_apps_for_new_worker
Determine which apps a new worker should load. Returns a list of import paths for apps that need more workers. Apps with wor
gunicorn/dirty/arbiter.py:172
↓ 8 callersMethod_get_available_worker
Get an available worker PID using round-robin selection. If app_path is provided, only returns workers that have loaded that
gunicorn/dirty/arbiter.py:587
↓ 8 callersMethod_get_minimum_workers
Calculate minimum number of workers required by app specs. Returns the maximum worker_count across all apps that have limits.
gunicorn/dirty/arbiter.py:155
↓ 8 callersMethodclear
(self)
tests/test_http2_async_connection.py:86
↓ 8 callersMethodclose
Close the sync connection.
gunicorn/dirty/client.py:188
↓ 8 callersMethodclose
Cleanup resources. Called when the dirty worker is shutting down. Use this to release resources like database connections, u
gunicorn/dirty/app.py:131
↓ 8 callersMethodclose
(self)
tests/test_asgi_worker.py:55
↓ 8 callersMethodconnect
Connect to control socket. Raises: ControlClientError: If connection fails
gunicorn/ctl/client.py:47
↓ 8 callersFunctioncreate_async_client_with_mocks
Create a client with mock async reader/writer.
tests/dirty/test_client_streaming_async.py:60
↓ 8 callersMethodcreate_worker
Create a worker instance for testing.
tests/test_gthread.py:236
↓ 8 callersMethodexecute
Execute an action on a dirty app (sync/blocking). Args: app_path: Import path of the dirty app (e.g., 'myapp.ml:MLApp')
gunicorn/dirty/client.py:80
↓ 8 callersMethodhttp_get
Make HTTP GET request to the container.
tests/docker/per_app_allocation/test_per_app_e2e.py:186
↓ 8 callersMethodinfo
(self, msg, *args, **kwargs)
gunicorn/instrument/statsd.py:61
↓ 8 callersMethodlast_update
(self)
gunicorn/workers/workertmp.py:46
↓ 8 callersMethodnotify
\ Your worker subclass must arrange to have this method called once every ``self.timeout`` seconds. If you fail in accomplishing
gunicorn/workers/base.py:70
↓ 8 callersMethodread_into
Read data from unreader and append to bytearray buffer.
gunicorn/http/message.py:625
↓ 8 callersMethodstream_chunks
Stream response chunks from URL.
tests/docker/asgi_compliance/conftest.py:337
↓ 8 callersMethodwait_closed
(self)
tests/test_dirty_worker.py:87
↓ 8 callersMethodwsgi
(self)
gunicorn/app/base.py:64
↓ 7 callersMethod_close_worker_connection
Close connection to a worker.
gunicorn/dirty/arbiter.py:650
↓ 7 callersMethod_create_manager
Create a LifespanManager instance.
tests/test_asgi_lifespan.py:121
↓ 7 callersMethod_create_mock_request
Create a mock WebSocket upgrade request.
tests/test_asgi_http_scope.py:368
↓ 7 callersMethod_create_mock_request
Create a mock HTTP request.
tests/test_asgi_websocket_protocol.py:437
↓ 7 callersMethod_create_protocol
Create an ASGIProtocol instance for testing.
tests/test_asgi_http_scope.py:357
↓ 7 callersMethod_create_protocol
Create an ASGIProtocol instance for testing.
tests/test_asgi_websocket_protocol.py:425
↓ 7 callersMethod_handle_http_request
Handle a single HTTP request.
gunicorn/asgi/protocol.py:942
↓ 7 callersFunction_normalize_sockaddr
Normalize socket address to ASGI-compatible (host, port) tuple. ASGI spec requires server/client to be (host, port) tuples. IPv6 sockets retu
gunicorn/asgi/protocol.py:41
↓ 7 callersMethod_omits
(self, method, status)
tests/test_asgi_streaming.py:354
↓ 7 callersMethod_signal_handler
Handle signals.
gunicorn/dirty/arbiter.py:280
← previousnext →101–200 of 4,571, ranked by callers