1
2/*
3 * Copyright (C) Max Romanov
4 * Copyright (C) Valentin V. Bartenev
5 * Copyright (C) NGINX, Inc.
6 */
7
8#ifndef _NXT_APPLICATION_H_INCLUDED_
9#define _NXT_APPLICATION_H_INCLUDED_
10
11
12typedef enum {
13 NXT_APP_PYTHON,
14 NXT_APP_PHP,
15 NXT_APP_GO,
16 NXT_APP_PERL,
17 NXT_APP_RUBY,
18
19 NXT_APP_UNKNOWN,
20} nxt_app_type_t;
21
22
23typedef struct nxt_app_module_s nxt_application_module_t;
24typedef struct nxt_app_module_s nxt_app_module_t;
25

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

54} nxt_go_app_conf_t;
55
56
57typedef struct {
58 char *script;
59} nxt_perl_app_conf_t;
60
61
62typedef struct {
63 nxt_str_t script;
64} nxt_ruby_app_conf_t;
65
66
67struct nxt_common_app_conf_s {
68 nxt_str_t name;
69 nxt_str_t type;
70 nxt_str_t user;
71 nxt_str_t group;
72
73 char *working_directory;
74
75 union {
76 nxt_python_app_conf_t python;
77 nxt_php_app_conf_t php;
78 nxt_go_app_conf_t go;
79 nxt_perl_app_conf_t perl;
80 nxt_ruby_app_conf_t ruby;
81 } u;
82};
83
84
85typedef struct {
86 nxt_str_t name;
87 nxt_str_t value;
88} nxt_app_header_field_t;

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

147
148struct nxt_app_wmsg_s {
149 nxt_port_t *port; /* where prepared buf will be sent */
150 nxt_buf_t *write;
151 nxt_buf_t **buf;
152 uint32_t stream;
153};
154
155
156struct nxt_app_rmsg_s {
149 nxt_buf_t *buf; /* current buffer to read */
157 nxt_buf_t *buf; /* current buffer to read */
158};
159
160
161nxt_inline u_char *
162nxt_app_msg_write_length(u_char *dst, size_t length);
163
164/* TODO asynchronous mmap buffer assignment */
165NXT_EXPORT u_char *nxt_app_msg_write_get_buf(nxt_task_t *task,

--- 147 unchanged lines hidden ---