1. 31 5月, 2012 2 次提交
  2. 30 5月, 2012 2 次提交
  3. 29 5月, 2012 1 次提交
  4. 28 5月, 2012 1 次提交
  5. 26 5月, 2012 7 次提交
  6. 25 5月, 2012 12 次提交
  7. 24 5月, 2012 3 次提交
  8. 23 5月, 2012 12 次提交
    • B
      std: Update timer for new kind rules · 8ec467d5
      Brian Anderson 提交于
      8ec467d5
    • J
    • J
      std: more work on uv tests to endure valgrind's machinations against them · b0b17521
      Jeff Olson 提交于
      - change port of tcp server test in uv_ll to avoid conflict w/ test in
      net::tcp
      - a few places the tcp::read fn is used in test w/ a timeout.. suspend
      use of the timeout from here on out.
      b0b17521
    • J
      std:: adding tcp::read fn as simple, blocking read operation, akin to write · c7656f67
      Jeff Olson 提交于
      also: read_future ala write_future .. woooooohooooooooo
      c7656f67
    • J
      c2ae062e
    • J
      std: several minor cleanups wrt codereview.. see extended comments · 9b103590
      Jeff Olson 提交于
      * there are a few places where I was experimenting w/ using `alt` in places
      where `if`/`else` would've sufficed. don't drink the koolaid!
      * I had an unneeded `else` structure (the `if` branch that preceeded
      concluded with a `fail` statement.. I added the `fail` later in the dev
      cycle for this branch, so I forgot to remove the `else` after doing so)
      * consistent wrt `prop_name: value` vs. `prop_name : value` in record decl
      and initialization
      * change an `alt` exp on an `ip_addr` to actually be exhaustive,
      instead of using a catch-all clause
      9b103590
    • J
    • J
      std: more docs and some methods for types in net::tcp · a40f550e
      Jeff Olson 提交于
      a40f550e
    • J
      std: ignoring timer test that seems to be race-failing b/c valgrind · a4b1e965
      Jeff Olson 提交于
      .. this test fails frequently, locally, when ran with the batch of other
      global_loop tests running due to how valgrind deals with multithreading
      in the test app. not sure what to do, here.
      a4b1e965
    • J
      std: splitting out tcp server API + tests · 6c6a47bf
      Jeff Olson 提交于
      - we now have two interfaces for the TCP/IP server/listener workflow,
      based on different user approaches surrounding how to deal with the
      flow of accept a new tcp connection:
      
      1. the "original" API closely mimics the low-level libuv API, in that we
      have an on_connect_cb that the user provides *that is ran on the libuv
      thread*. In this callback, the user can accept() a connection, turning it
      into a tcp_socket.. of course, before accepting, they have the option
      of passing it to a new task, provided they *make the cb block until
      the accept is done* .. this is because, in libuv, you have to do the
      uv_accept call in the span of that on_connect_cb callback that gets fired
      when a new connection comes in. thems the breaks..
      
      I wanted to just get rid of this API, because the general proposition of
      users always running code on the libuv thread sounds like an invitation
      for many future headaches. the API restriction to have to choose to
      immediately accept a connection (and allow the user to block libuv as
      needed) isn't too bad for power users who could conceive of circumstances
      where they would drop an incoming TCP connection and know what they're
      doing, in general.
      
      but as a general API, I thought this was a bit cumbersome, so I ended up
      devising..
      
      2. an API that is initiated with a call to `net::tcp::new_listener()` ..
      has a similar signature to `net::tcp::listen()`, except that is just
      returns an object that sort of behaves like a `comm::port`. Users can
      block on the `tcp_conn_port` to receive new connections, either in the
      current task or in a new task, depending on which API route they take
      (`net::tcp::conn_recv` or `net::tcp::conn_recv_spawn` respectively).. there
      is also a `net::tcp::conn_peek` function that will do a peek on the
      underlying port to see if there are pending connections.
      
      The main difference, with this API, is that the low-level libuv glue is
      going to *accept every connection attempt*, along with the overhead that
      that brings. But, this is a much more hassle-free API for 95% of use
      cases and will probably be the one that most users will want to reach for.
      6c6a47bf
    • J
      std: splitting out tcp server API WIP · e9c6416d
      Jeff Olson 提交于
      e9c6416d
    • J
      std: reworking how some net and libuv modules are exported in the rc · d02b3dff
      Jeff Olson 提交于
      .. turns out that, without the export, the modules aren't accessible
      outside of the crate, itself. I thought that, by importing some module
      into another (nesting it) and exporting from that nested module (which
      is, itself, exported from std.rc) that my mod would be in the build
      artifact. This doesn't appear to be the case. learning is fun!
      d02b3dff