• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Long Time Dealy When getting Vended Object
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Long Time Dealy When getting Vended Object


  • Subject: Long Time Dealy When getting Vended Object
  • From: Kiran Kumar S <email@hidden>
  • Date: Wed, 22 Apr 2009 11:44:23 +0530

Hi,

Really going mad, it is taking long time response when i am trying to get vended Object from the remote machine which doesn't exist in the network. .
I am facing same long time delay(more than 60 sec) when i am trying to get vended object from the remote machine which gone to sleep.
Below is the code


-(id)serverObject {
id serverObject = nil;
@try{
serverObject = [[self serverConnection] rootProxy];
}@catch(NSException *exception) {
serverObject = nil;
[self destroyConnection];
}
return serverObject;
}
-(NSConnection *)serverConnection {
if(!serverConnection) {
NSString *webAppURLString = [[NSUserDefaults standardUserDefaults] objectForKey:kPXWebAppURL];
NSString *host = nil;
if(!(webAppURLString && [webAppURLString length] > 0)) {
host =[[NSProcessInfo processInfo] hostName];
} else {
host = [[NSURL URLWithString:webAppURLString] host];
}
NSSocketPort *port = [[NSSocketPort alloc] initRemoteWithTCPPort:PORT_NUMBER host:host];
serverConnection = [[NSConnection alloc] initWithReceivePort:nil sendPort:port];
[serverConnection setDelegate:self];
[serverConnection setRequestTimeout:1.0f];
[serverConnection setReplyTimeout:1.0f];
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(handleConnectionDied:) name:NSConnectionDidDieNotification object:serverConnection];
[port release];
}
return serverConnection;
}



Please help me out in this

Regards
SKiranKumar
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Long Time Dealy When getting Vended Object
      • From: Ken Thomases <email@hidden>
  • Prev by Date: Really big files and encodings
  • Next by Date: Which is the event that when the mouse move out of the window area would response?
  • Previous by thread: Re: Really big files and encodings
  • Next by thread: Re: Long Time Dealy When getting Vended Object
  • Index(es):
    • Date
    • Thread