Deleted
Added
1 2/* 3 * Copyright (C) Igor Sysoev 4 * Copyright (C) NGINX, Inc. 5 */ 6 7#ifndef _NXT_PORT_H_INCLUDED_ 8#define _NXT_PORT_H_INCLUDED_ --- 22 unchanged lines hidden (view full) --- 31 nxt_port_handler_t process_ready; 32 33 /* Process exit/crash notification. */ 34 nxt_port_handler_t remove_pid; 35 36 /* Stop process command. */ 37 nxt_port_handler_t quit; 38 |
39 /* Request headers. */ 40 nxt_port_handler_t req_headers; 41 42 /* Websocket frame. */ 43 nxt_port_handler_t websocket_frame; 44 |
45 /* Various data. */ 46 nxt_port_handler_t data; 47}; 48 49 50#define nxt_port_handler_idx(name) \ 51 ( offsetof(nxt_port_handlers_t, name) / sizeof(nxt_port_handler_t) ) 52 --- 19 unchanged lines hidden (view full) --- 72 _NXT_PORT_MSG_CHANGE_FILE = nxt_port_handler_idx(change_file), 73 _NXT_PORT_MSG_NEW_PORT = nxt_port_handler_idx(new_port), 74 _NXT_PORT_MSG_MMAP = nxt_port_handler_idx(mmap), 75 76 _NXT_PORT_MSG_PROCESS_READY = nxt_port_handler_idx(process_ready), 77 _NXT_PORT_MSG_REMOVE_PID = nxt_port_handler_idx(remove_pid), 78 _NXT_PORT_MSG_QUIT = nxt_port_handler_idx(quit), 79 |
80 _NXT_PORT_MSG_REQ_HEADERS = nxt_port_handler_idx(req_headers), 81 _NXT_PORT_MSG_WEBSOCKET = nxt_port_handler_idx(websocket_frame), 82 |
83 _NXT_PORT_MSG_DATA = nxt_port_handler_idx(data), 84 85 NXT_PORT_MSG_MAX = sizeof(nxt_port_handlers_t) 86 / sizeof(nxt_port_handler_t), 87 88 NXT_PORT_MSG_RPC_READY = _NXT_PORT_MSG_RPC_READY, 89 NXT_PORT_MSG_RPC_READY_LAST = _NXT_PORT_MSG_RPC_READY | NXT_PORT_MSG_LAST, 90 NXT_PORT_MSG_RPC_ERROR = _NXT_PORT_MSG_RPC_ERROR | NXT_PORT_MSG_LAST, --- 12 unchanged lines hidden (view full) --- 103 NXT_PORT_MSG_MMAP = _NXT_PORT_MSG_MMAP | NXT_PORT_MSG_LAST 104 | NXT_PORT_MSG_CLOSE_FD | NXT_PORT_MSG_SYNC, 105 106 NXT_PORT_MSG_PROCESS_READY = _NXT_PORT_MSG_PROCESS_READY 107 | NXT_PORT_MSG_LAST, 108 NXT_PORT_MSG_QUIT = _NXT_PORT_MSG_QUIT | NXT_PORT_MSG_LAST, 109 NXT_PORT_MSG_REMOVE_PID = _NXT_PORT_MSG_REMOVE_PID | NXT_PORT_MSG_LAST, 110 |
111 NXT_PORT_MSG_REQ_HEADERS = _NXT_PORT_MSG_REQ_HEADERS, 112 NXT_PORT_MSG_WEBSOCKET = _NXT_PORT_MSG_WEBSOCKET, 113 NXT_PORT_MSG_WEBSOCKET_LAST = _NXT_PORT_MSG_WEBSOCKET | NXT_PORT_MSG_LAST, 114 |
115 NXT_PORT_MSG_DATA = _NXT_PORT_MSG_DATA, 116 NXT_PORT_MSG_DATA_LAST = _NXT_PORT_MSG_DATA | NXT_PORT_MSG_LAST, 117} nxt_port_msg_type_t; 118 119 120/* Passed as a first iov chunk. */ 121typedef struct { 122 uint32_t stream; --- 66 unchanged lines hidden (view full) --- 189 uint32_t max_size; 190 /* Maximum interleave of message parts. */ 191 uint32_t max_share; 192 193 uint32_t app_pending_responses; 194 uint32_t app_responses; 195 nxt_queue_t pending_requests; 196 |
197 nxt_queue_t active_websockets; 198 |
199 nxt_port_handler_t handler; 200 nxt_port_handler_t *data; 201 202 nxt_mp_t *mem_pool; 203 nxt_event_engine_t *engine; 204 205 nxt_buf_t *free_bufs; 206 nxt_socket_t pair[2]; --- 91 unchanged lines hidden --- |