<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns="http://purl.org/rss/1.0/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:syn="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/">
  <channel rdf:about="http://blog.gmane.org/gmane.comp.lib.boost.asio.user">
    <title>gmane.comp.lib.boost.asio.user</title>
    <link>http://blog.gmane.org/gmane.comp.lib.boost.asio.user</link>
    <description/>
    <syn:updatePeriod>hourly</syn:updatePeriod>
    <syn:updateFrequency>1</syn:updateFrequency>
    <syn:updateBase>1901-01-01T00:00+00:00</syn:updateBase>
    <items>
      <rdf:Seq>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5259"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5251"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5239"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5233"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5228"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5218"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5217"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5215"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5214"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5210"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5207"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5201"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5198"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5188"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5187"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5179"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5177"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5172"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5155"/>
        <rdf:li rdf:resource="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5142"/>
      </rdf:Seq>
    </items>
    <image rdf:resource="http://gmane.org/img/gmane-25t.png"/>
    <textinput rdf:resource=""/>
  </channel>
  <image rdf:about="http://gmane.org/img/gmane-25t.png">
    <title>Gmane</title>
    <url>http://gmane.org/img/gmane-25t.png</url>
    <link>http://gmane.org</link>
  </image>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5259">
    <title>Socket MT safety</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5259</link>
    <description>&lt;pre&gt;From: Igor R &amp;lt;boost.lists&amp;lt; at &amp;gt;gm...&amp;gt; - 2012-05-23 17:10

That was kind of misunderstanding. As far as I remember, I meant that


OK, I see.

So, may I just protect all calls to the socket methods with mutex, without
using strands to serialize the calls of completition handlers? I really
want my read and write handlers to work concurrently in different threads.

There is a statement in asio manual which make me unsure:


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/_______________________________________________
asio-users mailing list
asio-users-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f&amp;lt; at &amp;gt;public.gmane.org
https://lists.sourceforge.net/lists/listinfo/asio-users
___________________&lt;/pre&gt;</description>
    <dc:creator>Nikki Chumakov</dc:creator>
    <dc:date>2012-05-23T17:32:09</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5251">
    <title>Socket MT safety</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5251</link>
    <description>&lt;pre&gt;Hi,

Would like to ask just for clarification.

Assuming my code (including competition handlers) is MT-safe

- can I call basic_socket's async_read and async_write methods from
two different threads for the same socket instance without
synchronization?

- can I call "async_read" (or "async_write") and "cancel" methods from
different threads?

- can I call "async_read" (or "async_write") and "close" methods from
different threads?

- can I call "close" and "cancel" methods from different threads?

Regards,
Nikki

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
asio-users mailing list
asio-users-5NWGOfrQmneRv+LV9MX5uipxl&lt;/pre&gt;</description>
    <dc:creator>Nikki Chumakov</dc:creator>
    <dc:date>2012-05-23T13:51:57</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5239">
    <title>Segmentation fault (core dumped)</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5239</link>
    <description>&lt;pre&gt;I keep getting this error every so often when my application exits. Is this a boost::asio bug? To me it looks like it since the crash happens within boost::asio (segmentation fault), but I could be doing something wrong.


---------------------------------

Program terminated with signal 11, Segmentation fault.
#0  0x00007f50d717165a in boost::asio::detail::task_io_service::wake_one_idle_thread_and_unlock (this=0x20bad90, lock=...) at /usr/include/boost/asio/detail/impl/task_io_service.ipp:461
461        first_idle_thread_ = idle_thread-&amp;gt;next;
(gdb) bt
#0  0x00007f50d717165a in boost::asio::detail::task_io_service::wake_one_idle_thread_and_unlock (this=0x20bad90, lock=...) at /usr/include/boost/asio/detail/impl/task_io_service.ipp:461
#1  0x00007f50d71716e0 in boost::asio::detail::task_io_service::wake_one_thread_and_unlock (this=0x20bad90, lock=...) at /usr/include/boost/asio/detail/impl/task_io_service.ipp:472
#2  0x00007f50d71715d5 in boost::asio::detail::task_io_service::post_deferred_completio&lt;/pre&gt;</description>
    <dc:creator>Amir Taaki</dc:creator>
    <dc:date>2012-05-18T13:17:19</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5233">
    <title>Boost/Asio "short read" error</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5233</link>
    <description>&lt;pre&gt;Hi,
I have problem with asio - sometimes server returns "short read" error.
I'm using client/server from the examples, I have boost 1.49, Windows 7 64 bit (application is 64 bit).
Please write me - is it just a bug or wrong implemented example inside of boost because the error occurs not every time.
How to protect my application against the error?
I tried to ask in boost mailing list but without result.
It is extremely important to me to determine what cause the error.
Best regards,
Marcin Głogowski

Dom Maklerski Banku Ochrony Środowiska Spółka Akcyjna
ul. Marszałkowska 78/80 / 00-517 Warszawa

wpisana w Rejestrze Przedsiębiorców prowadzonym przez
Sąd Rejonowy dla m. st. Warszawy XII Wydział Gospodarczy Krajowego Rejestru Sądowego
pod numerem: KRS 0000048901 / NIP 526-10-26-828

Kapitał zakładowy w wysokości 21.551.200zł wpłacony w całości.

P - Nie drukuj tej wiadomości, jeśli to nie jest konieczne.
------------------------------------------------------------------------------
Live Secur&lt;/pre&gt;</description>
    <dc:creator>Marcin Głogowski</dc:creator>
    <dc:date>2012-05-16T09:55:46</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5228">
    <title>thread::interrupt and asio::ios_service::run</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5228</link>
    <description>&lt;pre&gt;Hello all,

Sorry if it is very basic, jsut could not find an answer. Does
io_service::run supports boost::thread::interrupt?

I wrote small example which i expected to work, but it does not
(prints "interrupting" and exits, second thread does not exit at all):

#include &amp;lt;boost/thread.hpp&amp;gt;
#include &amp;lt;boost/asio.hpp&amp;gt;
#include &amp;lt;iostream&amp;gt;

void hello_timer (boost::system::error_code const &amp;amp;ec) { std::cerr &amp;lt;&amp;lt;
"timer\n"; }

void ios_run (boost::asio::io_service *ios)
{
   try
   {
      ios-&amp;gt;run ();
      std::cerr &amp;lt;&amp;lt; "thread quit\n";
   }
   catch (std::exception const &amp;amp;e)
   {
      std::cerr &amp;lt;&amp;lt; "exception: " + std::string (e.what ()) + "\n";
   }
}

int main ()
{
   boost::asio::io_service ios;
   boost::asio::deadline_timer dt (ios);
   dt.expires_from_now (boost::posix_time::minutes (15));
   dt.async_wait (hello_timer);
   boost::thread t (boost::bind (ios_run, &amp;amp;ios));
   sleep (1);
   std::cerr &amp;lt;&amp;lt; "interrupting\n"; t.interrupt (); sleep (1);
   return 0;
}

--------------------------------------------------&lt;/pre&gt;</description>
    <dc:creator>kir</dc:creator>
    <dc:date>2012-05-15T22:50:00</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5218">
    <title>creating a match object that stops at a characterother than a newline</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5218</link>
    <description>&lt;pre&gt;Hi

How do you create a match functor that stops at a character other than
a newline? I tried this

class DetectTerminator
{
    public:
        explicit DetectTerminator() {}

        template &amp;lt;typename Iterator&amp;gt;
            std::pair&amp;lt;Iterator, bool&amp;gt; operator()(
                    Iterator begin, Iterator end) const
            {
                Iterator i = begin;
                while (i != end)
                {
                    if ('\n' == *i || '?' == *i)
                    {
                        BOOST_LOG_TRIVIAL(info) &amp;lt;&amp;lt; "detected " &amp;lt;&amp;lt; int(*i);
                        return std::make_pair(i, true);
                    }
                    else
                    {
                        i++;
                    }
                }
                return std::make_pair(i, false);
            }
};
namespace boost { namespace asio {
  template &amp;lt;&amp;gt; struct is_match_condition&amp;lt;DetectTerminator&amp;gt;
    : public boost::true_type {};
} }


but it doesn't callback to the read completion handler when a '&lt;/pre&gt;</description>
    <dc:creator>Sashan Govender</dc:creator>
    <dc:date>2012-05-13T10:21:16</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5217">
    <title>Can we mix synchronous accept, connect and handshake (ssl) with async read and write on the same io_service</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5217</link>
    <description>&lt;pre&gt;Dear Chris,

Our use case requires us to build the timeout in the read and write calls
and therefore we wrote them as async_read and async_write.  However, at the
higher level where we perform accept and handshake (we are using ssl), we
are still using the synchonous version of accept and handshake of the
ssl::stream class.  There is a singleton io_service in this case.  So, our
flow goes like:

- start the main event loop by calling io_service.run() with some dummy
work so it never exits the loop
- call accept which is blocked waiting for the next incoming message
- once the message arrives, we create a new socket of type
boost::asio::ssl::stream&amp;lt;boost::asio::ip::tcp::socket&amp;gt; that embeds this
singleton io_service and pass the newly created socket to the worker thread
- Inside this worker thread, we
    * perform handshake() on the ssl context with the caller and then,
    * call async_read and async_write with their corresponding handlers
properly implemented (thread safe) and the worker thread is then bloc&lt;/pre&gt;</description>
    <dc:creator>Rene Zhu</dc:creator>
    <dc:date>2012-05-11T19:22:38</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5215">
    <title>boost::asio over SocketCAN</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5215</link>
    <description>&lt;pre&gt;Hello,

I was thinking of making use of boost asio to read data from a Socket CAN [1].
There's nothing fancy going on in &amp;lt;linux/can.h&amp;gt;, and the device should
behave like a raw socket.

Looking at the basic_socket interface it seems that I can make use of
basic_raw_socket::assign [2] to assign the native socket created with

socket( PF_CAN, SOCK_RAW, CAN_RAW );

This is what I have so far

namespace can {
class CanSocket {
public:
typedef boost::asio::ip::basic_endpoint&amp;lt;CanSocket&amp;gt; endpoint;
typedef boost::asio::ip::basic_resolver_query&amp;lt;CanSocket&amp;gt; resolver_query;
typedef boost::asio::ip::basic_resolver_iterator&amp;lt;CanSocket&amp;gt; resolver_iterator;
typedef boost::asio::basic_raw_socket&amp;lt;CanSocket&amp;gt; socket;
typedef boost::asio::ip::basic_resolver&amp;lt;CanSocket&amp;gt; resolver;

CanSocket()
: _protocol( CAN_RAW )
, _family( PF_CAN )
{
}

static CanSocket v4()
{
return CanSocket();
}
static CanSocket v6();
int type() const;
int protocol() const;
int family() const;

friend bool operator&lt;/pre&gt;</description>
    <dc:creator>Alin Rus</dc:creator>
    <dc:date>2012-05-06T00:29:33</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5214">
    <title>Using asio from within a node.js module</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5214</link>
    <description>&lt;pre&gt;I've got a middleware library that I use to communicate with a server using
 both synchronous and asynchronous socket IO.  I've had really good luck
with this architecture, embedding the middleware in multithreaded C++/Qt 
applications and python; however, I'm really struggling getting it to work
with the middleware lib loaded in a node.js module.

The node community hasn't been very responsive to my queries, so I'm hoping 
 the asio community can shed some light on this.
 
First of all, I'm using boost::asio 1.47.0 on Red Hat Linux with gcc 4.6.1
and node.js 0.6.12. The first problem I have is that asio routinely seg
faults (but not always) when constructing a basic_io_stream socket.  The
op_queue ends up with gargage pointers in back_.  If it doesn't crash, then
the queue never processes handlers.  I'm pretty sure there is some
threading issue at play here, but I'm not having much luck narrowing it
down.

I've tried a single threaded such that there is only one io_service in the
node module with hopes of j&lt;/pre&gt;</description>
    <dc:creator>Stephen Bowline</dc:creator>
    <dc:date>2012-05-04T16:23:52</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5210">
    <title>Asio's HTTP example server slow w/ SSL?</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5210</link>
    <description>&lt;pre&gt;(originally addressed to the code's author, but asio-users moderation 
ate the CC'd version)

Here is a JSON-RPC skeleton HTTP server based upon Boost.Asio example 
http::server3:

     git://github.com/jgarzik/rpcsrv.git

http::server3 was updated to support HTTP/1.1, uploaded content and JSON 
encode/decode.  After that, SSL support was added, using Boost.Asio 
server.cpp example code.

ApacheBench shows 24,000 reqs/second for HTTP.  Impressive!

ApacheBench shows 200 reqs/second for HTTPS (SSL).  Even though the HTTP 
server is using 10 threads, CPU usage is only 50%.

Has anyone heard of this problem before?  rpcsrv.git is based entirely 
upon Boost.Asio example code -- though I admit I probably did something 
stupid and broke it all

Any thoughts or SSL tips/tricks?

Thanks, and kudos on well done http::server3 example code,

     Jeff



------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's se&lt;/pre&gt;</description>
    <dc:creator>Jeff Garzik</dc:creator>
    <dc:date>2012-05-03T20:42:22</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5207">
    <title>no io_service::wrap(f) ... why?</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5207</link>
    <description>&lt;pre&gt;Hi!

Why is there only a strand::wrap(f) and not an io_service::wrap(f) in the API? That'd be a really useful thing to have.

Every so often you need to call a handler but want to have it dispatched to another io_service. Such a thing is possible using a wrapper and argument forwarding, but I'm just wondering why it was included for strand and not io_service.


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
asio-users mailing list
asio-users-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f&amp;lt; at &amp;gt;public.gmane.org
https://lists.sourceforge.net/lists/listinfo/asio-users
_______________________________________________
Using Asio? List your proj&lt;/pre&gt;</description>
    <dc:creator>Amir Taaki</dc:creator>
    <dc:date>2012-04-26T13:45:23</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5201">
    <title>async_read: illegal instruction</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5201</link>
    <description>&lt;pre&gt;Hi everyone

Since having updated to boost version 1.48, I am experiencing severe  
runtime errors when relying on asynchronous operations. Please consider  
the following code (the important bit is located in ServerReceive’s  
operator() ):

=== main.cpp ================================
#include &amp;lt;boost/asio/ip/tcp.hpp&amp;gt;
#include &amp;lt;boost/asio/write.hpp&amp;gt;
#include &amp;lt;boost/asio/read.hpp&amp;gt;
#include &amp;lt;boost/exception/all.hpp&amp;gt;
#include &amp;lt;boost/lexical_cast.hpp&amp;gt;
#include &amp;lt;boost/thread.hpp&amp;gt;

using namespace boost;
using namespace boost::asio;
using namespace boost::posix_time;
using namespace boost::system;
using namespace std;

namespace {

const char * const CONNECTION_UNAVAILABLE("error.connection-unavailable");
const char * const RESOLVE_ERROR("error.resolve");
struct host_name;
struct port_value;

ip::tcp::endpoint createEndpoint(const string &amp;amp;hostName, unsigned int  
port) {
io_service ioService;
ip::tcp::resolver resolver(ioService);
ip::tcp::resolver::query query(hostName, lexical_cast&amp;lt;string&amp;gt;(port),  
ip::tcp::&lt;/pre&gt;</description>
    <dc:creator>Pascal Kesseli</dc:creator>
    <dc:date>2012-04-23T09:25:56</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5198">
    <title>io_service post handler copy performance</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5198</link>
    <description>&lt;pre&gt;When I test io_service performance(windows),
I find the Handler copy 4 times by call stack.
Can I pass 1 and 4 handler by reference in stead of by value?
If no, any reason? thanks!

1 and 2 is post call

1.
template &amp;lt;typename Handler&amp;gt;
void win_iocp_io_service::post(Handler handler)  // here handler copy

2.
completion_handler(Handler&amp;amp; h)
    : operation(&amp;amp;completion_handler::do_complete),
      handler_(BOOST_ASIO_MOVE_CAST(Handler)(h))  // here handler_ copy
{
}

3 and 4 is call when complete

3.
static void do_complete(io_service_impl* owner, operation* base,
      const boost::system::error_code&amp;amp; /*ec*/,
      std::size_t /*bytes_transferred*/)
  {
    // Take ownership of the handler object.
    completion_handler* h(static_cast&amp;lt;completion_handler*&amp;gt;(base));
    ptr p = { boost::addressof(h-&amp;gt;handler_), h, h };

    BOOST_ASIO_HANDLER_COMPLETION((h));

    // Make a copy of the handler so that the memory can be deallocated
before
    // the upcall is made. Even if we're not about to make an upcall, a
    //&lt;/pre&gt;</description>
    <dc:creator>he keding</dc:creator>
    <dc:date>2012-04-20T07:16:27</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5188">
    <title>Hanging dead connections.</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5188</link>
    <description>&lt;pre&gt;Hello.
Sometimes TCP connection isn't closed on server side even after client
application closing. Client computer reboot does not help, connection will
hang endlessly.
Is there something to do with it, adjust some settings?
------------------------------------------------------------------------------
Better than sec? Nothing is better than sec when it comes to
monitoring Big Data applications. Try Boundary one-second 
resolution app monitoring today. Free.
http://p.sf.net/sfu/Boundary-dev2dev_______________________________________________
asio-users mailing list
asio-users-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f&amp;lt; at &amp;gt;public.gmane.org
https://lists.sourceforge.net/lists/listinfo/asio-users
_______________________________________________
Using Asio? List your project at
http://think-async.com/Asio/WhoIsUsingAsio
&lt;/pre&gt;</description>
    <dc:creator>Slav</dc:creator>
    <dc:date>2012-04-17T15:01:58</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5187">
    <title>test boost example server3: sometimes lost the requestdata</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5187</link>
    <description>&lt;pre&gt;Hi,

   I had encouraged an issue when I used the asio example server3, would
you please help me to analyze what's happen in this case, the case like
this:

*******************************************************

   Client code:

              Main()

              {

                     creat();

                     Bind();

                     Listen();

                     Accept();

                     While( true)

                     {

                            Send_request();

                            Recv_response();

                            //Process_response();

}

              }

******************************************************

       Well, when I start the client, we could send some requests to the
server and we also could receive the responses. But, some minutes later,
the client block in the recv() API in recv_response() function. While this
time , we use the tcpdump to capture the package at both the server side and
client side, we found that the client had already sen&lt;/pre&gt;</description>
    <dc:creator>zhongwang huang</dc:creator>
    <dc:date>2012-04-16T01:25:46</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5179">
    <title>asio: read or write with timeout?</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5179</link>
    <description>&lt;pre&gt;Been using ASIO for the past 18 months or so, works great on Linux,
Windows, and Mac, so for that I thank you!  Using it a bit for things like
name resolution, but mostly using it for UDP, TCP, and SSL sockets.

All the socket read + writes used so far in this app are of this style:

http://www.boost.org/doc/libs/1_49_0/doc/html/boost_asio/reference/basic_stream_socket/read_some/overload2.html
http://www.boost.org/doc/libs/1_49_0/doc/html/boost_asio/reference/basic_stream_socket/write_some/overload2.html

Problem is when network connectivity interrupts communication between
clients and servers.  App needs to jump in and do some recovery long before
the 13 or 15 minute timeout finally takes effect.  So I'm now looking
though the reference docs thinking: "there's probably an override for those
methods that takes some kind of timeout value...  Maybe takes an absolute
boost::posix_time::ptime or better yet a simple relative
boost::posix_time::time_duration as a "timeout" parameter.

But I cannot find anything of&lt;/pre&gt;</description>
    <dc:creator>Stéphane Charette</dc:creator>
    <dc:date>2012-04-14T08:29:13</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5177">
    <title>asio::deadline_timer does not call the handler if Ichange the time back</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5177</link>
    <description>&lt;pre&gt;This simple code does not call the handler print () if I change the time back.
Is this normal?
How can I fix this behavior?

#include &amp;lt;iostream&amp;gt;
#include &amp;lt;boost/asio.hpp&amp;gt;

void print(const boost::system::error_code&amp;amp; /*e*/) {
   std::cout &amp;lt;&amp;lt; "Hello, world!" &amp;lt;&amp;lt; std::endl;
}

int main() {
   boost::asio::io_service io;

   boost::asio::deadline_timer t(io, boost::posix_time::seconds(5));
   t.async_wait(print);

   io.run();
   return 0;
}

http://liveworkspace.org/code/5e35baafe00a0a7a47f51347a92d9110

Thanks.

&lt;/pre&gt;</description>
    <dc:creator>niXman</dc:creator>
    <dc:date>2012-04-14T07:49:19</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5172">
    <title>Relax CompletionHandler copy-constructable requirement</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5172</link>
    <description>&lt;pre&gt;A natural fit to execute tasks asynchronously is via io_service::post.
Asio already supports moveable handlers and is on its way to integrate
nicely with C++11. Ideally, I would like to do this:

    template &amp;lt;typename F&amp;gt;
    std::future&amp;lt;typename std::result_of&amp;lt;F()&amp;gt;::type&amp;gt;
    schedule(F f)
    {
        typedef typename std::result_of&amp;lt;F()&amp;gt;::type result_type;
        std::packaged_task&amp;lt;result_type&amp;gt; task(f);
        std::future&amp;lt;result_type&amp;gt; future = task.get_future();

        io_service_.post(std::move(task)); // Impossible,
CompletionHandler requires copy-contruction.

        return std::move(future);
    }

Are there any plans to relax the CompletionHandler copy-constructable
requirement? For example, I could imagine on overload for
io_service::post that takes an rvalue reference. This would ensure
backwards compatibility while supporting idioms like shown above.

    Matthias

------------------------------------------------------------------------------
Better than sec? Nothing is better than sec when i&lt;/pre&gt;</description>
    <dc:creator>Matthias Vallentin</dc:creator>
    <dc:date>2012-04-11T18:41:43</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5155">
    <title>reusing SSL sessions in ASIO sockets</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5155</link>
    <description>&lt;pre&gt;I have  a C++ app that connects to FTP-Secure servers.  Some of these
servers seem to expect the clients to re-use/share/resume (?) the SSL
session between the control and data connections.  This way the server
doesn't have to perform the expensive SSL handshake on every connection.  I
have my client code working on Linux, but I suspect I haven't done it
right.  When the same code runs on a Mac, it doesn't work at all.  The 2nd
connection fails to establish, getting stuck in the SSL handshake.

I'm definitely not an expert with OpenSSL nor ASIO, so I'm hoping someone
more knowledgable will be able to point out my mistake.

To illustrate the problem, I've written a sample app that shows this
problem.  The sample source is available here:
http://charette.no-ip.com:81/asio-openssl/

Here is how I setup the SSL CTX:

C::C( void ) :
        ioservice( 2 ),
        sslcontext( ioservice, boost::asio::ssl::context::sslv23 ), // only
use 1 SSL context
        sslControlSocket( ioservice, sslcontext ),
        sslDat&lt;/pre&gt;</description>
    <dc:creator>Stéphane Charette</dc:creator>
    <dc:date>2012-04-08T04:52:47</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5142">
    <title>Detecting TCP disconnection...</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5142</link>
    <description>&lt;pre&gt;
I'm using the asynchronous facility of boost::asio 1.48 on Linux.  My 
question is: if I have an idle TCP connection (no sends and receives) 
and the connection suddenly goes down, how would the endpoints (sender 
or receiver) know?  In other words, does the io_service know that the 
connection went down?

Thanks much



------------------------------------------------------------------------------
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here 
http://p.sf.net/sfu/sfd2d-msazure
_______________________________________________
asio-users mailing list
asio-users-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f&amp;lt; at &amp;gt;public.gmane.org
https://lists.sourceforge.net/lists/listinfo/asio-users
_______________________________________________
Using Asio? List your project at
http://think-async.com/Asio/WhoIsUsingAsio

&lt;/pre&gt;</description>
    <dc:creator>barcaroller</dc:creator>
    <dc:date>2012-04-01T15:45:26</dc:date>
  </item>
  <item rdf:about="http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5133">
    <title>boost asio overhead/scalability</title>
    <link>http://comments.gmane.org/gmane.comp.lib.boost.asio.user/5133</link>
    <description>&lt;pre&gt;Hi,

I have been trying to look at how much overhead boost asio introduces
and how it scales to multiple cores.

Essentially, I have written a small test program that just
sends/receives 4-byte packets between a datagram unix-domain
socketpair (this is on a quad-core Intel i7-2600K &amp;lt; at &amp;gt; 3.4 Ghz with
hyperthreading enabled and Linux 3.0). I am comparing a simple
blocking recv/send version (1 thread per socketpair) with a
hand-written edge-triggered epoll loop, a simple async I/O abstraction
library (using edge-triggered epoll) and boost asio (1.46) when
increasing the number of worker threads.

I have run this with 1 socketpair and 16 socketpairs (to get some
concurrency in the latter case):

- http://www.editgrid.com/export/sheetobject/41780862.png
- http://www.editgrid.com/export/sheetobject/41780860.png

As there isn't any concurrency when there is only a single socketpair,
I don't expect any speedup when increasing the number of threads, but
with boost asio I am seeing a very significant slowdown here. And e&lt;/pre&gt;</description>
    <dc:creator>Christof Meerwald</dc:creator>
    <dc:date>2012-03-25T16:55:34</dc:date>
  </item>
  <textinput rdf:about="http://search.gmane.org/?group=$group=gmane.comp.lib.boost.asio.user">
    <title>Search Engine</title>
    <description>Search the mailing list at Gmane</description>
    <name>query</name>
    <link>http://search.gmane.org/?group=$group=gmane.comp.lib.boost.asio.user</link>
  </textinput>
</rdf:RDF>

