Sönke Ludwig
2625397f91
Use asyncAwaitAny instead of asyncAwait to work around linker error.
2017-11-25 15:27:17 +01:00
Boris-Barboris
6634cbc645
switch to asyncAwait
2017-11-25 15:27:17 +01:00
Boris-Barboris
55e7866497
implement tcp connect timeout
2017-11-25 15:27:17 +01:00
Sönke Ludwig
db449e3cb3
Fix implementation of TCPListener.bindAddress.
2017-09-28 23:52:39 +02:00
Sönke Ludwig
9fe9783443
Convert Waitable from struct to pure template to avoid heap closures.
...
Also fixes a case where ThreadLocalWaiter.emitSingle overlaps a call to .emit.
2017-09-27 16:41:11 +02:00
Sönke Ludwig
8895f62a49
Fix parameter name.
2017-09-15 15:58:35 +02:00
Sönke Ludwig
333643d48e
Add interface_address parameter to UDPConnection.addMembership.
2017-09-15 15:54:59 +02:00
Sönke Ludwig
2d0576a5fe
Implement the UDP multicast support methods.
2017-09-03 18:15:52 +02:00
Sönke Ludwig
7e1d6a7323
Add listenUDP overload taking a NetworkAddress.
2017-09-03 15:54:17 +02:00
Sönke Ludwig
f81c9175df
Mention that TCPListenOptions.distribute is deprecated.
2017-07-20 18:48:08 +02:00
Sönke Ludwig
d39bbf19c0
Avoid extra exception and allow toString of unspecified NetworkAddress values.
2017-07-19 14:50:20 +02:00
Sönke Ludwig
d7b2173cb3
Implement TCPListener.stopListening and fix the vibe.core.net.1726 test.
...
The test fix follows the fix in the vibe.d repository: rejectedsoftware/vibe.d#f960427e5974c176c58b516647895a2af4ea181b
2017-07-18 11:55:39 +02:00
Sönke Ludwig
ca2f9dbe91
Add UDP multicast declarations matching rejectedsoftware/vibe.d#1806 .
...
The actual functionality still needs to be implemented in eventcore.
2017-07-08 10:44:42 +02:00
Sebastian Wilzbach
04b3575c14
Remove deprecated stdc import
2017-07-03 00:39:41 +02:00
Sönke Ludwig
01ed0a43de
Adjust for eventcore 0.8.12.
2017-06-27 01:11:50 +02:00
Sönke Ludwig
e3f9d07e58
Don't store local/remote address for UDP connections.
...
Errored out due to the space requirements of UNIX addresses.
2017-03-10 23:00:43 +01:00
Sönke Ludwig
5fd9fc4007
Always compute TCPConnection.xxxAddress on demand.
...
Storing the network addresses becomes too expensive with UNIX socket support.
2017-03-10 21:06:18 +01:00
Sönke Ludwig
ed8b33786b
Compile fixes.
2017-03-10 20:07:04 +01:00
Sönke Ludwig
1edfc88e63
Add UNIX address type support to NetworkAddress.
2017-03-10 19:53:40 +01:00
Sönke Ludwig
72913575f4
Fix error message.
2017-01-30 22:52:36 +01:00
Sönke Ludwig
b7e996cd8c
Let TCPConnection.peek() handle closed connections gracefully.
2017-01-30 17:27:43 +01:00
Sönke Ludwig
2dccd43277
Let TCPConnection.waitForData amd leastSize act gracefully on closed connections.
2017-01-30 12:04:21 +01:00
Sönke Ludwig
ac811ba501
Remove buggy NetworkAddress.toUnknownAddress.
...
UnknownAddress is not large enough to hold either IPv6 or UDS addresses.
2017-01-30 11:40:11 +01:00
Sönke Ludwig
d2629ef053
Don't throw on read error in TCPConnection.waitForData.
2017-01-30 11:29:01 +01:00
Sönke Ludwig
4c9b6c0fb8
Properly check return value of createDatagramSocket.
2017-01-30 11:19:51 +01:00
Sönke Ludwig
84a21f7e9d
Add compatibility overloads for listenTCP.
2017-01-30 09:19:08 +01:00
Sönke Ludwig
96b798200c
Make more network methods nothrow.
...
TCPConection properties and NetworkAddress.to(Address)String have been marked nothrow.
2017-01-29 20:19:38 +01:00
Sönke Ludwig
798f0ef446
Implement support for TCPListenOptions.reusePort.
2017-01-27 22:51:17 +01:00
Sönke Ludwig
5249c1c4c6
Fix infinite recursion in TCPConnection.(local/remote)Address properties.
2017-01-26 13:58:14 +01:00
Sönke Ludwig
2acc60934f
Add IOMode parameters to stream read/write methods.
2017-01-19 00:36:32 +01:00
Sönke Ludwig
9d4e8086ff
Make the callback type the first argument to Waitable!().
2017-01-16 00:23:37 +01:00
Sönke Ludwig
964d72f3b5
Fix handling of scoped callback parameters in eventcore callbacks.
2017-01-16 00:20:35 +01:00
Sönke Ludwig
f3c84d497e
Fix bind address handling for connectTCP.
2017-01-15 23:17:14 +01:00
Sönke Ludwig
24b940039d
Implement UDPConnection.canBroadcast/localAddress.
2017-01-15 22:19:41 +01:00
Sönke Ludwig
f015662a94
TCPConnection and async improvements.
...
- asyncAwaitAny now takes the callback type, so that parameter storage classes are handled correctly
- Implement TCPConnection.remoteAddress/localAddress
- Implement TCPConnection.tcpNoDelay, keepAlive and readTimeout
- Implement timeout handling for TCPConnection.waitForData
2017-01-15 20:59:36 +01:00
Sönke Ludwig
79656a80df
Fix safety error on Windows.
2016-12-19 16:16:50 +01:00
Sönke Ludwig
2d37e550bd
Safe-ify net module, and extend functionality.
...
- Custom bind address for outgoing stream connections
- reusePort flag
- Full OutputStream interface for TCPConnection.
2016-11-02 20:58:00 +01:00
Sönke Ludwig
0ee42c4243
Add vibe.d 0.7.x compatible stream definitions.
...
In contrast to 0.7.x, streams can now be either of class, struct or interface type.
2016-10-26 13:11:28 +02:00
Sönke Ludwig
4db9b3f100
Implement DNS lookups and partially implement UDP.
2016-10-25 00:27:51 +02:00
Sönke Ludwig
c08f101549
Update for eventcore 0.5.0 and the latest DMD beta.
2016-10-24 08:22:49 +02:00
Sönke Ludwig
e294d24a4b
Update for latest eventcore version.
2016-10-05 14:40:29 +02:00
Sönke Ludwig
4c6f26bd00
Add a minimalistic duck typing based stream representation.
2016-06-18 10:00:02 +02:00
Sönke Ludwig
3b0e4e0452
Big refactoring step.
...
- Moves a lot of stuff from vibe.core.core to vibe.core.task
- Introduces TaskScheduler to unify the scheduling process
- Refines how tasks are scheduled and processed (can push to the front of the task queue and uses a marker task to keep track of the spot up to which to process)
- Start to add proper support for task interrupts and timeouts by properly cancelling in-flight async operations
- Work on ManualEvent - still not functional for the shared case
- Implement proper IP address parsing in NetworkAddress
2016-06-14 08:01:03 +02:00
Sönke Ludwig
ba48a6f43a
Use BatchBuffer instead of FixedRingBuffer for TCP read.
2016-04-10 17:17:15 +02:00
Sönke Ludwig
21619e8a30
Add allocation-less overloads of NetworkAddress.to(Address)String.
...
(cherry picked from commit 997d78ad36bfee853daefe663e3a54314a652b19)
2016-04-10 14:40:39 +02:00
Sönke Ludwig
7e2d1dd038
Initial commit.
...
The library is able to support simple TCP servers in the current state. The API is still mostly compatible with mainline vibe.d, but the driver systen has been replaced by the eventcore library and sockets/files/timers/... are now structs with automatic reference counting instead of GC collected classes. The stream interfaces have been removed for now.
2016-03-01 20:30:42 +01:00