Re: Multithread safety



Alexander Nickolov wrote:
> That is of course true. Scalability at least is unimportant for
> clients,

I used to think so too but now I am not so sure. Once upon a time a client
meant a desktop application that occasionally grabbed some info from server.
Now I find "clients" simultaneously opening few dozen connections for
various purposes. At some point the number of threads in the client becomes
too big.

> however, whereas portability might be important.
> While I agree the code won't be 100% platform independent,
> it's much easier to port code based on puire BSD APIs than
> one based on the extended WinSock functions and concepts.

This is true but up to a point. There are two kinds of porting: tweaking
existing code with #ifdefs or providing a new implementation of a
"networking layer". Sticking to BSD helps with the first way but this
approach is flawed to begin with. It is fast in the beginning but very hard
to maintain. It also forces you to the lowest common denominator everywhere
(not just with sockets). Using the second way you are not constarained to
BSD. In my experience I found it easier to abstract the "networking layer"
and re-wrtie it for each platform group. But then I only had to support
Windows-Unix portability.

> Then again, portability is not important for a lot of folks anyway...

Yeah. Especially to the "client" folks.


--
Eugene
http://www.gershnik.com



.



Relevant Pages

  • Re: Multithread safety
    ... up to 64 simultaneous sockets present no problem in the ... BSD model since a single thread can handle them for I/O. ... At some point the number of threads in the client ... whereas portability might be important. ...
    (microsoft.public.win32.programmer.networks)
  • Re: Future of lisp?
    ... The JVM doesn't ship with the current version of either Mac OS X or iOS, so two of the most influential platforms out there cannot run clojure code out of the box. ... So much for widespread portability. ... No one who had a clear eyed view of the client space would have targetted a langauge at the jvm. ...
    (comp.lang.lisp)
  • Off: vpnc haxx
    ... This won't be exactly bsd specific topic but I saw others posted about vpnc so I think some of you have a clue about cisco devices and ios;) ... So I have a cisco vpn router somewhere. ... As I saw this is impossible in windows and in linux or in bsd I can use a vpnc connect script that's true to modify the tunnel parameters but here is a little problem, if I modify it then everything will be unaccessible in the vpn, like the router does not accept my traffic from that point. ... Ok so if I have 2 client on this subnet they can reach each other via encrypted tunnel. ...
    (freebsd-net)
  • Off: vpnc haxx
    ... vpnc so I think some of you have a clue about cisco devices and ios;) ... So I have a cisco vpn router somewhere (where I don't have admin ... As I saw this is impossible in windows and in linux or in bsd I can use ... Ok so if I have 2 client on this subnet they can reach each other via ...
    (freebsd-net)
  • Re: portknocking packages
    ... It now works with ipfw firewalls on BSD systems, and the fwknop client ... Geoff Galitz wrote: ...
    (Security-Basics)