home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / sys / next / programm / 6176 < prev    next >
Encoding:
Text File  |  1992-09-15  |  2.3 KB  |  64 lines

  1. Newsgroups: comp.sys.next.programmer
  2. Path: sparky!uunet!spool.mu.edu!wupost!micro-heart-of-gold.mit.edu!snorkelwacker.mit.edu!thunder.mcrcim.mcgill.edu!homer.cs.mcgill.ca!samurai
  3. From: samurai@cs.mcgill.ca (Darcy BROCKBANK)
  4. Subject: Re: DIstributed Objects Problem (HELP!)
  5. Message-ID: <1992Sep15.215927.13958@cs.mcgill.ca>
  6. Sender: news@cs.mcgill.ca (Netnews Administrator)
  7. Organization: SOCS - Mcgill University, Montreal, Canada
  8. References: <1992Sep15.000616.1105@cs.mcgill.ca> <4987@rosie.NeXT.COM>
  9. Date: Tue, 15 Sep 1992 21:59:27 GMT
  10. Lines: 52
  11.  
  12. In article <4987@rosie.NeXT.COM> sam_s@NeXT.com writes:
  13. >samurai@cs.mcgill.ca (Darcy BROCKBANK) writes:
  14. >
  15. >> (... A bunch of stuff about distributed applications)
  16. >
  17. >You mentioned that you ran the server's connection, but you didn't mention
  18. >running the clients connection.  Let's see if I can make this clear.
  19. >
  20. >When you asked for the registered server object, you actually got a proxy
  21. >to that object.  In order to make that happen, a connection was created for
  22. >you automatically on the client side.  You can get this connection like this:
  23. >
  24. >    magicConnection = [myServerProxy connectionForProxy];
  25.  
  26.  
  27. [ stuff deleted ]
  28.  
  29. O Great Sam, Bringer of BackSpace, and Light of the People, you are
  30. absolutly correct!
  31.  
  32. I just added:
  33.  
  34. [[myServerProxy connectionForProxy] runFromAppKit];
  35.  
  36. And all my problems were solved!
  37.  
  38. Thanks a million...
  39.  
  40. - db
  41.  
  42. >
  43. >This connection will receive messages at its inPort, but how will it
  44. >send those messages to you?  It must have some "thread" of execution to
  45. >dispatch those messages to you.  You probably want to run that connection from
  46. >DPSclient ("runFromAppKit") so that the Objective-C messages are dispatched
  47. >from the main thread.  You could run the connection in a new thread, but then
  48. >when unsolicited messages came in (like those your server sends) you would
  49. >handle those messages in the client's connection's thread, and you don't
  50. >want multiple threads running in a NeXTstep app unless you really know
  51. >what you're doing.
  52. >
  53. >In other words, since you don't run the client connection, messages
  54. >arrive there but you never give control to the connection code to
  55. >do anything with those messages, so they just sit there at the port.
  56. >
  57. >-sam
  58. >
  59. >--
  60. >Opinions expressed herein are not those of my employer.  They're not even
  61. >mine.  They're probably wrong besides.  How did they get in here, anyway?
  62.  
  63.  
  64.