-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problems with asynchronous model #2
Comments
Thanks for the report, i am working on it. |
I can answer questions and provide code review if you submit your changes as a pull request against your own repository's master or develop branch. |
I did a merge request for the asociated executor would be nice if you could have a look: |
I'm having a hard time understanding this code. It looks like you duplicated a significant amount of functionality of the Also, it looks like you are type-erasing the handler here:
Why the type-erasure? This is almost always a mistake. It seems like you are losing the associated allocator. Unless I am misreading it? I left some other comments in the pull request. Keep up your efforts! |
The problem is, that i don't do a listen as udp sockets don't provide this. Instead it does a async_receive_from apart from that it sets the cookie_generate and verify_callbacks (this could be done before passing the socket to async_accept). Not sure the async_receive_from can be done with the The |
What is a I also notice a lot of duplicated functionality in Maybe you can give me a little bit of an overview about how this all works, it would help me give a better code review. Also, since you're using
Personally I think requiring C++11 is fine, but if you're going to do that then you should trim back stuff which is only used for C++03 compatibility. Function template definitions don't need the
Finally, you have a misconfigured git on one of the machines you are using, your global git config email and username are not set correctly so some commits are missing a link to the GitHub user and also are not signed (they say "Stefan Damm"): |
DatagramSocketType is a underlying transport for the async operations like a UDP socket. Much of the Code is copied from asio classes e.g. the context shares nearly all code with the asio::ssl::context and there could be a common base class that was had all except the method enums and the constructor. There is really not more difference between the two. That's also why i kept the Here is a Summary of the changes the classes have compared to their asio counterparts
socket.hpp
acceptor.hpp
detail/engine.hpp
The diffs between the asio_dtls and asio classes |
NIce work, but this code has some defects. In particular, handler helpers passed to initiating functions lose the associated executor and associated allocator. For example, this code is wrong:
asio_dtls/include/asio/ssl/dtls/acceptor.hpp
Line 765 in 7eccc52
There are also other places which violate Asio preconditions. I suggest reading this composed operation tutorial:
https://www.boost.org/doc/libs/1_68_0/libs/beast/doc/html/beast/using_io/writing_composed_operations.html
The text was updated successfully, but these errors were encountered: