nxt_router.h (444:4bf1dca6173c) nxt_router.h (507:fa714d76592b)
1
2/*
3 * Copyright (C) Igor Sysoev
4 * Copyright (C) NGINX, Inc.
5 */
6
7#ifndef _NXT_ROUTER_H_INCLUDED_
8#define _NXT_ROUTER_H_INCLUDED_

--- 69 unchanged lines hidden (view full) ---

78typedef nxt_int_t (*nxt_app_prepare_msg_t)(nxt_task_t *task,
79 nxt_app_request_t *r, nxt_app_wmsg_t *wmsg);
80
81
82struct nxt_app_s {
83 nxt_thread_mutex_t mutex; /* Protects ports queue. */
84 nxt_queue_t ports; /* of nxt_port_t.app_link */
85
1
2/*
3 * Copyright (C) Igor Sysoev
4 * Copyright (C) NGINX, Inc.
5 */
6
7#ifndef _NXT_ROUTER_H_INCLUDED_
8#define _NXT_ROUTER_H_INCLUDED_

--- 69 unchanged lines hidden (view full) ---

78typedef nxt_int_t (*nxt_app_prepare_msg_t)(nxt_task_t *task,
79 nxt_app_request_t *r, nxt_app_wmsg_t *wmsg);
80
81
82struct nxt_app_s {
83 nxt_thread_mutex_t mutex; /* Protects ports queue. */
84 nxt_queue_t ports; /* of nxt_port_t.app_link */
85
86 nxt_queue_t spare_ports; /* of nxt_port_t.idle_link */
87 nxt_queue_t idle_ports; /* of nxt_port_t.idle_link */
88 nxt_timer_t idle_timer;
89 nxt_work_t adjust_idle_work;
90 nxt_event_engine_t *engine;
91
86 nxt_queue_t requests; /* of nxt_req_app_link_t */
87 nxt_queue_t pending; /* of nxt_req_app_link_t */
88 nxt_str_t name;
89
92 nxt_queue_t requests; /* of nxt_req_app_link_t */
93 nxt_queue_t pending; /* of nxt_req_app_link_t */
94 nxt_str_t name;
95
90 uint32_t pending_workers;
91 uint32_t workers;
92 uint32_t max_workers;
96 uint32_t pending_processes;
97 uint32_t processes;
98 uint32_t idle_processes;
99
100 uint32_t max_processes;
101 uint32_t spare_processes;
102 uint32_t max_pending_processes;
93 uint32_t max_pending_responses;
94 uint32_t max_requests;
95
96 nxt_msec_t timeout;
97 nxt_nsec_t res_timeout;
103 uint32_t max_pending_responses;
104 uint32_t max_requests;
105
106 nxt_msec_t timeout;
107 nxt_nsec_t res_timeout;
108 nxt_msec_t idle_timeout;
98
99 nxt_app_type_t type:8;
100 uint8_t live; /* 1 bit */
101
102 nxt_queue_link_t link;
103
104 nxt_str_t conf;
105 nxt_app_prepare_msg_t prepare_msg;

--- 53 unchanged lines hidden ---
109
110 nxt_app_type_t type:8;
111 uint8_t live; /* 1 bit */
112
113 nxt_queue_link_t link;
114
115 nxt_str_t conf;
116 nxt_app_prepare_msg_t prepare_msg;

--- 53 unchanged lines hidden ---