Mercurial > hg > nginx-vendor-current
comparison src/core/ngx_cycle.h @ 0:f0b350454894 NGINX_0_1_0
nginx 0.1.0
*) The first public version.
author | Igor Sysoev <http://sysoev.ru> |
---|---|
date | Mon, 04 Oct 2004 00:00:00 +0400 |
parents | |
children | 46833bd150cb |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:f0b350454894 |
---|---|
1 | |
2 /* | |
3 * Copyright (C) Igor Sysoev | |
4 */ | |
5 | |
6 | |
7 #ifndef _NGX_CYCLE_H_INCLUDED_ | |
8 #define _NGX_CYCLE_H_INCLUDED_ | |
9 | |
10 | |
11 #include <ngx_config.h> | |
12 #include <ngx_core.h> | |
13 | |
14 | |
15 struct ngx_cycle_s { | |
16 void ****conf_ctx; | |
17 ngx_pool_t *pool; | |
18 | |
19 ngx_log_t *log; | |
20 ngx_log_t *new_log; | |
21 | |
22 ngx_array_t listening; | |
23 ngx_array_t pathes; | |
24 ngx_list_t open_files; | |
25 | |
26 ngx_uint_t connection_n; | |
27 ngx_connection_t *connections; | |
28 ngx_event_t *read_events; | |
29 ngx_event_t *write_events; | |
30 | |
31 ngx_cycle_t *old_cycle; | |
32 | |
33 ngx_str_t conf_file; | |
34 ngx_str_t root; | |
35 }; | |
36 | |
37 | |
38 typedef struct { | |
39 ngx_flag_t daemon; | |
40 ngx_flag_t master; | |
41 | |
42 ngx_int_t worker_processes; | |
43 | |
44 ngx_uid_t user; | |
45 ngx_gid_t group; | |
46 | |
47 ngx_str_t pid; | |
48 ngx_str_t newpid; | |
49 | |
50 #if (NGX_THREADS) | |
51 ngx_int_t worker_threads; | |
52 size_t thread_stack_size; | |
53 #endif | |
54 | |
55 } ngx_core_conf_t; | |
56 | |
57 | |
58 typedef struct { | |
59 ngx_pool_t *pool; /* pcre's malloc() pool */ | |
60 } ngx_core_tls_t; | |
61 | |
62 | |
63 ngx_cycle_t *ngx_init_cycle(ngx_cycle_t *old_cycle); | |
64 ngx_int_t ngx_create_pidfile(ngx_cycle_t *cycle, ngx_cycle_t *old_cycle); | |
65 void ngx_delete_pidfile(ngx_cycle_t *cycle); | |
66 void ngx_reopen_files(ngx_cycle_t *cycle, ngx_uid_t user); | |
67 ngx_pid_t ngx_exec_new_binary(ngx_cycle_t *cycle, char *const *argv); | |
68 | |
69 | |
70 extern volatile ngx_cycle_t *ngx_cycle; | |
71 extern ngx_array_t ngx_old_cycles; | |
72 extern ngx_module_t ngx_core_module; | |
73 extern ngx_uint_t ngx_test_config; | |
74 #if (NGX_THREADS) | |
75 extern ngx_tls_key_t ngx_core_tls_key; | |
76 #endif | |
77 | |
78 | |
79 #endif /* _NGX_CYCLE_H_INCLUDED_ */ |