Commit Graph

403 Commits

Author SHA1 Message Date
Arvid Norberg 7251575d98 This patch does: (#633)
1. simplifies and regularizies creation of listen sockets based on the listen
   interfaces setting.
2. simplifies and improves the behavior of UDP sockets, which are now explicitly
   opened per listen interface
3. transitions udp tracker, DHT and uTP socket manager over to using the new
   udp sockets
4. greatly simplified udp_socket to only wrap a single underlying socket (as
   opposed to one IPv4 and IPv6 socket)
5. improved behavior of bind-to-device
6. introduce an array_view type to make udp packet passing code simpler
7. simplify and make setting of DF flag more robust
8. simplify and regularize port mapping of listen sockets
2016-04-24 15:26:28 -04:00
arvidn 04a3c04075 merged RC_1_1 into master 2016-04-20 08:08:05 -04:00
arvidn 774ea740b4 make session_time return uint16_t 2016-04-14 19:22:27 -04:00
arvidn fd4a46342f merge RC_1_1 into master 2016-03-30 00:33:29 -04:00
arvidn 7649610807 fix test_optimistic_unchoking sim 2016-03-27 18:40:53 -04:00
arvidn 96e2693d13 merge RC_1_1 into master 2016-03-19 16:02:46 -04:00
arvidn f7c9062019 deprecate more parts of explicit cache as well as fixing typos of TORRENT_NO_DEPRECATE preprocessor tests 2016-03-19 07:54:29 -04:00
arvidn 3c98868f6c deprecate explicit cache feature 2016-03-18 12:15:03 -04:00
arvidn 77ce318a84 merged RC_1_1 into master 2016-03-17 00:46:05 -04:00
arvidn 317eb2fe2a remove unused disk allocation code 2016-03-16 20:13:28 -04:00
arvidn 6d85c7c5f0 merge RC_1_1 into master 2016-03-08 01:10:48 -05:00
arvidn 442979c318 support filtering which parts of session state are loaded by load_state() 2016-03-06 16:35:49 -05:00
Steven Siloti b52027a02a set enable_dht to true in session::start_dht(entry)
This function needs to enable the dht to match its semantics in pre 1.1 versions
2016-02-26 19:22:28 -08:00
arvidn 0b173c6651 merged RC_1_1 2016-02-23 23:48:29 -05:00
arvidn d8b88ba381 include protocol in portmap_alert 2016-02-21 19:16:00 -05:00
arvidn cdfdbfd6aa fix port mapping for SSL UDP socket 2016-02-21 17:40:27 -05:00
arvidn cc8066bf11 properly deprecated adding torrents by http url 2016-02-21 11:31:42 -05:00
arvidn 6d77000ab0 deprecate ssl_listen setting. instead ssl sockets are specified by an 's' suffix of the port in listen_interfaces. 2016-02-12 15:46:12 -05:00
arvidn 887e79eb22 improve support for listening on multiple sockets and interfaces, with the listen_interfaces setting 2016-02-12 15:44:17 -05:00
arvidn d1e4b57ad4 rename a few members of session_impl to be more descriptive 2016-02-08 18:15:47 -05:00
arvidn ae7058e119 remove the timestamps and file sizes from the resume data. This makes saving resume data alot cheaper, since it doesn't have to go via the disk thread. It also removes an old-standing API usage issue where there was easily a race condition introduced between saving resume data and pausing a torrent. 2016-02-06 15:50:55 -05:00
arvidn 3a4f957b63 Merge branch 'RC_1_1' 2016-02-02 02:02:24 -05:00
arvidn 88b7e3768f add sim test for optimistic unchoke round-robin distribution 2016-02-01 20:28:30 -05:00
arvidn f2ce2284da optimize the optimistic unchoke logic. extend the API for extensions to be able to affect the order of optimistic unchokes 2016-02-01 20:28:22 -05:00
Alden Torres 9f3d13281f Documentation typos 2016-02-01 15:00:46 -05:00
arvidn e113e8cdf3 minor cleanup of listen sockets 2016-01-31 19:40:31 -05:00
arvidn 297b8943d0 move the DHT rate limiter into the dht_tracker class and remove the rate_limited_udp_socket type. This further simplifies the udp socket (preparing for moving it into the listen_socket structure) 2016-01-18 14:34:41 -05:00
arvidn 505ae508f4 mark up some override functions and fix other clang warnings 2015-12-13 19:44:42 -05:00
arvidn 98c3b75b55 use more efficient (in-place) handler allocation for udp async_read and session second_tick 2015-11-28 00:57:44 -05:00
Steven Siloti 1f13343a70 const correctness 2015-11-22 10:02:26 -08:00
arvidn fba0762353 fix some msvc warnings 2015-11-19 19:01:54 -05:00
arvidn 76821f138f fix gcc attribute order issue 2015-10-18 00:46:01 -04:00
arvidn 08e2bf7835 mark up some more functions with override and silence a few more warnings in boost headers 2015-10-17 10:02:37 -04:00
arvidn 81ee9d5d4e make appveyor build the python binding installer for windows 2015-10-12 21:09:19 -04:00
Alden Torres 62b24d8b67 Add set_dht_storage to session API. 2015-10-02 09:00:07 -04:00
arvidn 8cf8e65861 turn linked_list into a template to improve type safety and remove some casts 2015-08-20 02:02:46 +02:00
arvidn ffa870d280 fixed some GCC warnings 2015-08-20 01:33:20 +02:00
arvidn 347d976a70 since starting the DHT can be delayed now, also cache dht nodes added while waiting 2015-08-18 23:35:27 +02:00
arvidn cc4368b45a attempt to postpone DHT until all outstanding dht router name lookups complete 2015-08-18 22:56:00 +02:00
Alden Torres b303a36ac2 Removed unnecessary full namespace reference to udp::endpoint in new dht_direct_request feature.
Add default value to userdata argument in dht_direct_request.
Minor spelling fix.
2015-08-12 00:49:09 -04:00
Steven Siloti 86fd8c3048 enable arbitrary direct dht requests and extension dht requests
If you're wondering why I used an alert for handling responses but not requests,
it's because the former was easy to do that way but the latter would have
involved some major refactoring or kludging. The DHT node is written with the
(IMO reasonable) assumption that all responses will be generated immediately, so
there was no way to easily accommodate getting a response asynchronously via
an alert.
2015-08-10 20:33:04 -07:00
Arvid Norberg 27c5a28637 Merge pull request #70 from thomas-yuan/master
Call callback function immediately when get data for mutable data.
2015-08-08 21:51:18 -04:00
Thomas e51b61870a Call callback function immediately when get mutable data. 2015-08-08 20:28:53 -04:00
arvidn 72286eb0dc minor asio.ssl abstraction cleanup. update libsimulator with build fix. only run simulator on one of the build variants on travis, since the simulator does not support ssl 2015-08-08 16:19:44 -04:00
Steven Siloti e6b3df3696 pass torrent_handle by const ref in the plugin api 2015-07-25 09:57:55 -07:00
Steven Siloti fbc67b4e21 switch to torrent_handle in plugin api 2015-07-23 19:52:23 -07:00
Alden Torres a856ae6e9b Added dht_get_peers and dht_announce at session level.
Refactored dht_put_item to dht_put_immutable_item in session_impl since the get operations are not overloaded (consistency).
Added allow_threading_guard to add_dht_node python binding.
Making dht_put_item in session returns a zeroed hash if TORRENT_DISABLE_DHT (avoid unnecessary calculation and it's more consistent).
Added missing DHT operations to the python binding.
Added missing allow_threading_guard to add_dht_node in the python binding.
2015-07-12 10:37:16 -04:00
Alden Torres fcac7140f8 Added dht_get_peers and dht_announce at session_impl level. 2015-07-01 15:30:08 -04:00
arvidn 94d6e06c97 first step in making opening all the listen sockets a bit more reliable 2015-06-29 23:10:09 -04:00
arvidn 5cb095f6d2 support using 0 disk threads (to perform disk I/O in network thread) 2015-06-14 16:00:04 -04:00