Home
last modified time | relevance | path

Searched refs:port (Results 1 – 25 of 56) sorted by last modified time

123

/unit/docs/
H A Dunit-openapi.yaml29 with a TCP port as the control socket."
43 - url: http://{server}:{port}
48 port:
1235 match any host IP addresses) and a port."
1262 addresses) and a port."
4373 and a port number, such as `127.0.0.1:80` or `*:443`."
5830 description: "Target IP address and optional port of the request."
5860 description: "Source IP address and optional port of the request."
/unit/src/
H A Dnxt_router.c813 tmcf->port = port; in nxt_router_conf_data_handler()
3133 port->main_app_port = port; in nxt_router_app_prefork_ready()
3145 &app->name, port->pid, port->id); in nxt_router_app_prefork_ready()
3625 engine->port = port; in nxt_router_thread_start()
4021 port = engine->port; in nxt_router_thread_exit_handler()
4514 port->main_app_port = port; in nxt_router_app_port_ready()
4703 port->pid, port->id, in nxt_router_app_port_release()
4820 port->pid, port->id); in nxt_router_app_port_close()
4831 &app->name, port->pid, port->id, in nxt_router_app_port_close()
4931 &app->name, port->pid, port->id); in nxt_router_adjust_idle_timer()
[all …]
H A Dnxt_main_process.c418 nxt_port_t *port; in nxt_main_new_port_handler() local
422 port = msg->u.new_port; in nxt_main_new_port_handler()
424 if (port != NULL in nxt_main_new_port_handler()
431 port->queue = mem; in nxt_main_new_port_handler()
629 nxt_port_t *port; in nxt_main_process_created_handler() local
641 process = port->process; in nxt_main_process_created_handler()
699 nxt_port_t *port; in nxt_main_process_whoami_handler() local
736 port->pair[0] = -1; in nxt_main_process_whoami_handler()
780 nxt_port_t *port; in nxt_main_process_port_create() local
789 process = port->process; in nxt_main_process_port_create()
[all …]
H A Dnxt_application.c599 nxt_port_t *port; in nxt_proto_start_process_handler() local
661 port = nxt_runtime_port_find(rt, msg->port_msg.pid, in nxt_proto_start_process_handler()
664 if (nxt_fast_path(port != NULL)) { in nxt_proto_start_process_handler()
665 nxt_port_socket_write(task, port, NXT_PORT_MSG_RPC_ERROR, in nxt_proto_start_process_handler()
689 nxt_port_t *port; in nxt_proto_quit_children() local
693 port = nxt_process_port_first(process); in nxt_proto_quit_children()
769 nxt_port_t *port; in nxt_proto_sigchld_handler() local
837 port = NULL; in nxt_proto_sigchld_handler()
842 port = nxt_process_port_first(process); in nxt_proto_sigchld_handler()
851 if (port != NULL) { in nxt_proto_sigchld_handler()
[all …]
H A Dnxt_runtime.c497 nxt_port_t *port; in nxt_runtime_stop_app_processes() local
524 nxt_port_t *port; in nxt_runtime_stop_all_processes() local
1671 nxt_port_t *port; in nxt_runtime_process_add() local
1698 port->pid = process->pid; in nxt_runtime_process_add()
1768 nxt_port_t *port; in nxt_runtime_process_port_create() local
1788 nxt_port_use(task, port, -1); in nxt_runtime_process_port_create()
1790 return port; in nxt_runtime_process_port_create()
1808 rt->port_by_type[port->type] = port; in nxt_runtime_port_add()
1810 nxt_port_use(task, port, 1); in nxt_runtime_port_add()
1828 if (rt->port_by_type[port->type] == port) { in nxt_runtime_port_remove()
[all …]
H A Dnxt_runtime.h119 void nxt_runtime_port_remove(nxt_task_t *task, nxt_port_t *port);
H A Dnxt_router.h91 nxt_port_t *port; member
247 void nxt_router_app_port_close(nxt_task_t *task, nxt_port_t *port);
H A Dnxt_php_sapi.c934 char *p, *url, *port; in nxt_php_do_301() local
956 port = nxt_unit_sptr_get(&r->local_port); in nxt_php_do_301()
958 && !(r->tls && strcmp(port, "443") == 0) in nxt_php_do_301()
959 && !(!r->tls && strcmp(port, "80") == 0)) in nxt_php_do_301()
962 p = nxt_cpymem(p, port, r->local_port_length); in nxt_php_do_301()
H A Dnxt_unit.h136 int (*add_port)(nxt_unit_ctx_t *, nxt_unit_port_t *port);
140 nxt_unit_port_t *port);
152 ssize_t (*port_send)(nxt_unit_ctx_t *, nxt_unit_port_t *port,
157 ssize_t (*port_recv)(nxt_unit_ctx_t *, nxt_unit_port_t *port,
231 int nxt_unit_process_port_msg(nxt_unit_ctx_t *ctx, nxt_unit_port_t *port);
250 char **name, uint32_t *name_length, char **port, uint32_t *port_length);
/unit/tools/
H A Dsetup-unit107 Print an available TCP port.
711 | read -r port;
774 | sed 's/8080/$port/' \\
810 Print an available TCP port.
856 int32_t port;
858 port = get_free_port();
859 if (port == -1)
862 printf("%d\n", port);
871 int32_t port;
875 port = -1;
[all …]
H A DREADME.md84 …p://…`*URI* | For remote TCP control sockets, the URI may include the protocol, hostname, and port.
/unit/src/nodejs/unit-http/
H A Dhttp_server.js490 port: 80
H A Dunit.cpp33 nxt_unit_port_t *port; member
51 ctx(c), port(p), ref_count(0), scheduled(false), stopped(false) in port_data_t()
62 rc = nxt_unit_process_port_msg(ctx, port); in process_port_msg()
471 Unit::add_port(nxt_unit_ctx_t *ctx, nxt_unit_port_t *port) in add_port() argument
479 if (port->in_fd != -1) { in add_port()
480 if (fcntl(port->in_fd, F_SETFL, O_NONBLOCK) == -1) { in add_port()
494 data = new port_data_t(ctx, port); in add_port()
496 err = uv_poll_init(loop, &data->poll, port->in_fd); in add_port()
511 port->data = data; in add_port()
526 if (port->data != NULL && ctx != NULL) { in remove_port()
[all …]
/unit/test/unit/
H A Dhttp.py17 port = kwargs.get('port', 8080)
49 connect_args = addr if sock_type == 'unix' else (addr, port)
/unit/test/
H A Dtest_upstreams_rr.py51 def get_resps(req=100, port=8080): argument
55 status = client.get(port=port)['status']
68 def get_resps_sc(req=100, port=8080): argument
82 resp = client.http(to_send, raw_resp=True, raw=True, port=port)
225 resps = get_resps_sc(req=30, port=8090)
237 resps = get_resps_sc(req=30, port=8090)
252 r_two = sum_resps(r_two, get_resps(req=10, port=8090))
H A Dtest_tls.py17 def add_tls(application='empty', cert='default', port=8080): argument
85 def remove_tls(application='empty', port=8080): argument
699 add_tls(port=8081)
703 assert client.get_ssl(port=8081)['status'] == 200, 'listener #2'
H A Dtest_routing.py1582 port = sock.getsockname()[1]
1583 return (sock, port)
1585 sock, port = sock_port()
1592 sock, port = sock_port()
1599 sock, port = sock_port()
1606 sock, port = sock_port()
1659 return client.get(sock_type='ipv6', port=8081)
1770 return client.get(sock_type='ipv6', port=8081)
1820 assert client.get(port=8081)['status'] == 404, '1 ipv4'
1824 assert client.get(port=8081)['status'] == 404, '0 ipv4'
[all …]
H A Dtest_client_ip.py42 (addr, port) = address[sock_type]
47 port=port,
55 assert client.get(port=8081)['body'] == '127.0.0.1', 'ipv4 default'
57 client.get(sock_type='ipv6', port=8082)['body'] == '::1'
65 assert client.get(port=8081)['body'] == '127.0.0.1', 'ipv4 default 2'
67 client.get(sock_type='ipv6', port=8082)['body'] == '::1'
H A Dtest_forwarded_header.py32 port = 8081 if sock_type == 'ipv4' else 8082
42 return client.get(sock_type=sock_type, port=port, headers=headers)[
H A Dtest_tls_tickets.py49 def connect(ctx=None, session=None, port=8080): argument
75 def set_tickets(tickets=True, port=8080): argument
125 set_tickets(TICKET2, port=8081)
156 set_tickets(TICKET, port=8081)
157 set_tickets(TICKET2, port=8082)
160 _, _, reused = connect(ctx, sess, port=8081)
162 _, _, reused = connect(ctx, sess, port=8082)
165 sess, ctx, _ = connect(port=8081)
169 sess, ctx, _ = connect(port=8082)
181 _, _, reused = connect(ctx, sess, port=8082)
[all …]
H A Dtest_unix_abstract.py51 (addr, port) = address[sock_type]
56 port=port,
H A Dtest_status_tls.py29 assert client.get_ssl(port=8081)['status'] == 200
H A Dtest_status.py63 assert client.get(port=8081)['status'] == 200
72 assert client.get(port=8082)['status'] == 503
88 sock = client.get(port=8081, no_recv=True)
139 port=8081,
H A Dtest_routing_tls.py29 assert client.get_ssl(port=8081)['status'] == 201, 'https'
/unit/
H A DREADME.md127 Now Unit accepts requests at the specified IP and port, passing them to the

123