AppleTalk to Carbon networking transition advice?
AppleTalk to Carbon networking transition advice?
- Subject: AppleTalk to Carbon networking transition advice?
- From: David Sinclair <email@hidden>
- Date: Wed, 1 Feb 2006 12:34:37 -0800
Hi.
I am upgrading an ancient project that uses AppleTalk networking to
communicate between a server and client applications over a local
area network. I'd like to seek your advice on the best solution.
A bit more info about the situation: There are multiple clients that
connect to the server. The clients mostly send binary structured
(not text) requests to the server and receive binary structures in
return, though sometimes the server initiates a send to a client.
The data transferred is anything from a few bytes to a megabyte or so
-- currently the AppleTalk code splits large blocks into the smaller
packets required by AppleTalk, and caches and re-assembles them on
the other side. There are typically about 3 network requests when
opening windows or performing actions on the client, so a persistent
connection may be helpful -- but being able to recover from
disconnections would be nice.
This project is a Classic one being Carbonized (yes, years late!).
We were originally going to upgrade to Open Transport, to maintain
Mac OS 9 compatibility, but are now thinking about dropping that and
using CFNetwork or similar modern API. The apps use Carbon Events
(but presumably I'd be able to call GetCFRunLoopFromEventLoop() to
access the CFRunLoop, if needed).
Ideally I'd like to use Bonjour, and I currently think that socket
streams would be the best way to transfer the data, but I'd like to
ask you networking experts on the best approach for our needs.
Connecting over a LAN is all that is required, but if connection over
the internet is an option, that would be a nice bonus. Security is
not a big concern at this point, as the data is already encrypted.
Apart from the AppleTalk experience, I've also used NSStream in
Cocoa, and CFStream in Carbon, but I wouldn't call myself an expert
by any stretch, so I'd appreciate any advice you can provide.
I was also wondering if there is any suitable sample code available
for Mac OS X server/client networking? I've found a few snippets,
but nothing that really shows server/client communication of the
nature I need.
Thanks!
--
David Sinclair, Dejal Systems, LLC - email@hidden
Custom Mac OS X development - http://www.dejal.com/consulting/
Site change and failure monitor tool - http://www.dejal.com/simon/
Plus other useful Mac products - http://www.dejal.com/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden