I need to implement a system where I can verify the number of running copies of my app on a local network against a site license. I thought DO might be a good way to implement this.

So what I'm thinking is the following. I'd appreciate it if someone with experience of DO could help me fill in a few details, like what objects and methods I might use. I have read the DO programming guide, but so far some of the concepts are not quite clear as I have little experience on network coding.

1. Each app has a server that vends an object that can supply info like the site license ID it is running under.

2. Each app sets up a client that can discover automatically all current servers above on the network.

3. The client asks each server for its site ID, and counts up those that match the current app's. If the count exceeds the license terms, the app quits. Actually this last step I'm probably pretty good with, it's the first two that I'm not so sure about.

----

So far:

For 1). I've read about vending an object, but I'm unclear whether [NSConnection defaultConnection] is adequate or whether I need to allocate NSSocketPorts or what. I'm also unsure what sort of string I should be using for names, and precisely what needs to be registered. Where are these names used, are they ever displayed to the user and how much effort do I need to put into ensuring they'd be unique on the network?

For 2). I can see how a single end-to-end remote object call works in general but in my case I have multiple servers all vending the same (or equivalent) object, and I need to interrogate them as a collection. I haven't come across anything so far in the docs that addresses this scenario. How do I get an enumeration of all appropriate servers?

Any sample code that is anything close to what I need would be gratefully received. It's also the case that once I know which classes I need to be looking at, the docs for those classes will probably give me much more to go on. I'm just lacking a roadmap that says which ones to look at and which ones are unsuitable.

Thanks for any help,

--Graham


_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to