apache/serf/5ec118afea1e7306bc43913631f046e55c2b1502 [SERF-211] Finalize the asynchronouse resolver API. This adds a private
interface for waking the context from a poll, so that the resolver can
signal when results are available.
* serf.h
(serf_context_create_ex): Make the docstring a docstring.
(serf_address_resolved_t,
serf_address_resolve_async,
serf_connection_created_t,
serf_connection_create_async): Remove the experimental comments
and fix some typos in the docstrings.
* serf_private.h
(SERF_IO_WAKEUP_PIPE): New constant for the io baton type.
(serf_context_t::wakeup): New member.
(serf__context_wakeup): New prototype.
* src/context.c: Include <apr_atomic.h>
(WAKEUP_LOOPBACK, WAKEUP_FAMILY): New constants.
(serf__context_wakeup_t): New struct for the self-pinging wakeup socket.
(init_wakeup, process_wakeup): New private helper functions.
(serf__context_wakeup): Implement here.
(serf_context_create_ex): Initialize the wakeup socket.
(serf_event_trigger): Process the wakeup signal.
* src/resolve.c: Remove the experimental/todo top-level comment.
(resolve): Tweak log message.
(push_resolve_result): Wake the context when a new result is available.
(serf__process_async_resolve_results): Return immediately if the async
resolver was not properly initialized. Add debug logging.
git-svn-id: https://svn.apache.org/repos/asf/serf/trunk@1931128 13f79535-47bb-0310-9956-ffa450edef68
4 files changed