summaryrefslogtreecommitdiffstats
path: root/src/web_server.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/web_server.h')
-rw-r--r--src/web_server.h26
1 files changed, 6 insertions, 20 deletions
diff --git a/src/web_server.h b/src/web_server.h
index 41dcfcf09..aa293695d 100644
--- a/src/web_server.h
+++ b/src/web_server.h
@@ -6,11 +6,12 @@
#define WEB_PATH_DATASOURCE "datasource"
#define WEB_PATH_GRAPH "graph"
-#define LISTEN_PORT 19999
-#define LISTEN_BACKLOG 100
+#ifndef API_LISTEN_PORT
+#define API_LISTEN_PORT 19999
+#endif
-#ifndef MAX_LISTEN_FDS
-#define MAX_LISTEN_FDS 100
+#ifndef API_LISTEN_BACKLOG
+#define API_LISTEN_BACKLOG 4096
#endif
typedef enum web_server_mode {
@@ -24,23 +25,8 @@ extern WEB_SERVER_MODE web_server_mode;
extern WEB_SERVER_MODE web_server_mode_id(const char *mode);
extern const char *web_server_mode_name(WEB_SERVER_MODE id);
-
extern void *socket_listen_main_multi_threaded(void *ptr);
extern void *socket_listen_main_single_threaded(void *ptr);
-extern int create_listen_sockets(void);
-extern int is_listen_socket(int fd);
-
-#ifndef HAVE_ACCEPT4
-extern int accept4(int sock, struct sockaddr *addr, socklen_t *addrlen, int flags);
-
-#ifndef SOCK_NONBLOCK
-#define SOCK_NONBLOCK 00004000
-#endif /* #ifndef SOCK_NONBLOCK */
-
-#ifndef SOCK_CLOEXEC
-#define SOCK_CLOEXEC 02000000
-#endif /* #ifndef SOCK_CLOEXEC */
-
-#endif /* #ifndef HAVE_ACCEPT4 */
+extern int api_listen_sockets_setup(void);
#endif /* NETDATA_WEB_SERVER_H */