Renamed "go" application type to "external".

There's nothing specific to Go language.  This type of application object can
be used to run any external application that utilizes libunit API.
This commit is contained in:
Valentin Bartenev
2018-10-09 17:53:31 +03:00
parent 6c5e5f25ef
commit 029c1a9f50
17 changed files with 92 additions and 89 deletions

View File

@@ -15,9 +15,9 @@
typedef enum {
NXT_APP_EXTERNAL,
NXT_APP_PYTHON,
NXT_APP_PHP,
NXT_APP_GO,
NXT_APP_PERL,
NXT_APP_RUBY,
@@ -39,6 +39,12 @@ typedef struct {
typedef struct nxt_common_app_conf_s nxt_common_app_conf_t;
typedef struct {
char *executable;
nxt_conf_value_t *arguments;
} nxt_external_app_conf_t;
typedef struct {
char *home;
nxt_str_t path;
@@ -54,12 +60,6 @@ typedef struct {
} nxt_php_app_conf_t;
typedef struct {
char *executable;
nxt_conf_value_t *arguments;
} nxt_go_app_conf_t;
typedef struct {
char *script;
} nxt_perl_app_conf_t;
@@ -80,11 +80,11 @@ struct nxt_common_app_conf_s {
nxt_conf_value_t *environment;
union {
nxt_python_app_conf_t python;
nxt_php_app_conf_t php;
nxt_go_app_conf_t go;
nxt_perl_app_conf_t perl;
nxt_ruby_app_conf_t ruby;
nxt_external_app_conf_t external;
nxt_python_app_conf_t python;
nxt_php_app_conf_t php;
nxt_perl_app_conf_t perl;
nxt_ruby_app_conf_t ruby;
} u;
};
@@ -161,7 +161,7 @@ nxt_app_lang_module_t *nxt_app_lang_module(nxt_runtime_t *rt, nxt_str_t *name);
nxt_app_type_t nxt_app_parse_type(u_char *p, size_t length);
NXT_EXPORT extern nxt_str_t nxt_server;
extern nxt_app_module_t nxt_go_module;
extern nxt_app_module_t nxt_external_module;
NXT_EXPORT nxt_int_t nxt_unit_default_init(nxt_task_t *task,
nxt_unit_init_t *init);