Commit graph

513 commits

Author SHA1 Message Date
eidheim
b1d9476ff1 Client: added support for server-sent events, and improved the chunked transfer code. Also some cleanup of especially the client code, and added a few additional tests. 2019-06-23 12:41:32 +02:00
eidheim
6097d86cb5 Another fix related to #246 : correctly removed connection from connections list when connection should be closed 2019-06-21 19:27:49 +02:00
eidheim
dbd2287418 Further fix of #246 : corrected use of response streambuf after reconnect (wrong response object was used in Session::callback). Also closes connection when appropriate, and simplified Session::callback. 2019-06-21 19:08:43 +02:00
eidheim
a316310815 Fixes #246 : client's response object is now reset when attempting to resend request on read error 2019-06-21 14:52:17 +02:00
eidheim
c2a10cc72a Fixed indentation in last commit 2019-06-19 14:57:01 +02:00
David Wedderwille
a73ce8b148 add asio_compatibility.hpp to the destination directory 2019-06-19 12:07:43 +00:00
eidheim
45d39e3c18 Merge branch 'new_asio' of https://gitlab.com/eidheim/Simple-Web-Server 2019-06-14 20:14:56 +02:00
eidheim
1f699fc304 Related to #246 : added test where multiple clients sends posts concurrently to a server 2019-06-13 19:37:43 +02:00
eidheim
3fcf628657 Minor cleanup in send_from_queue 2019-06-03 12:12:33 +02:00
eidheim
045d4fce8d Remove SimpleWeb::post and added std::forward to SimpleWeb::get_socket_executor 2019-06-03 10:17:38 +02:00
eidheim
9ca86827d9 Unlocks send_queue_lock before calling callbacks in case send_from_queue is invoked in callbacks 2019-05-28 13:07:20 +02:00
eidheim
514a135e0c Improved set_timeout(): no longer keeps connection alive longer than necessary. 2019-05-27 21:13:28 +02:00
eidheim
1b5f062678 New asio: removed use of strand, and fixed steady_timer constructor call 2019-05-22 14:00:06 +02:00
eidheim
44c2f733dc New asio api: removed unnecessary SimpleWeb::timer_expires_after 2019-05-20 18:39:54 +02:00
eidheim
d6985ed62e Fixes #261: SimpleWeb::status_code(const std::string &) now only regards the status code number when searching for status code enum, and can also return undefined enums that can be cast to an integer value 2019-04-29 13:30:22 +02:00
eidheim
5087f5d3df Added support for new asio api 2019-04-10 11:07:33 +02:00
eidheim
ded57636dd Further improvements to the ASSERT-macro: replaced fprintf with std::cerr and added std::-prefix to abort 2019-03-28 10:56:16 +01:00
eidheim
e716cd9764 Improved ASSERT macro, and renamed tests/check.hpp to tests/assert.hpp 2019-03-23 13:46:31 +01:00
eidheim
7282a342b9 Merge branch 'tests_in_release' of https://gitlab.com/AndreyNautilus/Simple-Web-Server 2019-03-23 12:16:38 +01:00
eidheim
c14705c62b Replaced unique_lock with lock_guard where possible 2019-03-08 12:54:56 +01:00
eidheim
e9877639b2 Fixes #255: Made regex_orderable::str public 2019-03-05 10:00:38 +01:00
eidheim
02d1c9c198 Merge branch 'use_name_and_command_tags_in_add_test_function' of https://gitlab.com/AndreyNautilus/Simple-Web-Server 2019-02-14 19:38:15 +01:00
Andrey Potapov
5db5031558 done 2019-02-13 16:29:27 +01:00
Frachop
e70a3c40a3 make SimpleWeb::Server::Request methods const 2019-02-12 23:54:36 +01:00
Andrey Potapov
4f66df49a0 use NAME and COMMAND tags in add_test function 2019-02-08 15:30:42 +00:00
eidheim
5e8b99c02a Server now accepts IPv6 connections when Config::address is empty 2019-01-10 13:12:26 +01:00
eidheim
b7e5a37da4 Removed possibly unnecessary is_tcp_fast_open_supported-function 2019-01-10 12:57:38 +01:00
gavin.smith@coralbay.tv
0eb6269c70 Linux server-side TFO: Clean-up upon code review 2019-01-03 22:06:59 +00:00
gavin.smith@coralbay.tv
4d7f3729c3 Fixed compiler error. 2018-12-30 00:40:42 +00:00
gavin.smith@coralbay.tv
4328286e32 Fixed compiler error. 2018-12-30 00:33:32 +00:00
gavin.smith@coralbay.tv
7d43617993 Added support for TCP Fast Open in server when using Linux. 2018-12-30 00:25:11 +00:00
Ole Christian Eidheim
1654b3cd42 Merge branch 'patch-1' into 'master'
Update README.md, add links for examples

See merge request eidheim/Simple-Web-Server!232
2018-11-30 09:11:38 +00:00
NeroBurner
22a2b64a0e Update README.md, add links for examples 2018-11-29 21:33:02 +00:00
eidheim
e334a86fc2 Minor variable name change in CMakeLists.txt 2018-11-14 09:10:00 +01:00
Ole Christian Eidheim
3b2c84a9bc Merge branch 'fix_crosscompiling' into 'master'
Replace CHECK_INCLUDE_FILE_CXX() with CMake find_file()

See merge request eidheim/Simple-Web-Server!231
2018-11-14 08:07:43 +00:00
Antoine Villeret
6c548d517e Replace CHECK_INCLUDE_FILE_CXX() with CMake find_file()
the former doesn't work when cross-compiling
2018-11-13 11:42:50 +01:00
Ole Christian Eidheim
0dccc11544 Merge branch 'master' into 'master'
fixed compiling on never msvc with older language version (c++11/14)

See merge request eidheim/Simple-Web-Server!230
2018-10-23 05:42:47 +00:00
daMaex
4c2fac8c1e fixed compiling on never msvc with older language version (c++11/14) 2018-10-19 13:11:10 +02:00
eidheim
cfe98038ba Removed use of asio::socket::close due to segmentation fault when Config::thread_pool_size was larger than 1. See #239. 2018-09-21 09:24:19 +02:00
eidheim
0f8f1f515b Related to #150: added LIBRESSL_VERSION_NUMBER check to BIO_new_mem_buf in order to support libressl 2018-08-26 22:30:28 +02:00
eidheim
b8de3ae504 Removed unnecessary check 2018-08-01 09:24:12 +02:00
eidheim
f39f21b56f Minor cleanups 2018-07-29 22:27:10 +02:00
eidheim
1ae9f69b1f Added missing include 2018-07-23 21:35:16 +02:00
eidheim
56b1df1ee5 Moved SimpleWeb::string_view to utility.hpp, and made use of string_view in Server::Response::write 2018-07-12 08:43:07 +02:00
eidheim
0ae69bffb1 All handlers in send queue is now called on error 2018-07-11 08:41:33 +02:00
eidheim
ebe170b4b3 Minor parameter rename, added underscore at end due to move 2018-07-10 17:42:48 +02:00
eidheim
c5cfa5b86c Added underscore on constructor parameters that are moved 2018-07-10 17:29:27 +02:00
eidheim
69b34bc7c2 Merge branch 'sse' of https://gitlab.com/eidheim/Simple-Web-Server 2018-07-10 12:46:53 +02:00
eidheim
cc234506b1 Completed support for multiple sequential Server::Response::send operations 2018-07-10 12:39:15 +02:00
eidheim
8b75c14aef Fixes #231: added checks to getline calls in parse functions so that they can be used outside the Server/Client classes 2018-07-04 20:47:47 +02:00