• 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
Re: Several Questions
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Several Questions


  • Subject: Re: Several Questions
  • From: Chris Hanson <email@hidden>
  • Date: Sun, 31 May 2009 20:04:17 -0700

On May 30, 2009, at 11:18 PM, Ammar Ibrahim wrote:
On Sun, May 31, 2009 at 6:16 AM, Chris Hanson <email@hidden> wrote:

The best way to ensure your daemon or agent is always running is to have it
run via launchd.


Start by reading the launchd man page and the "Daemons and Agents" tech
note; these will give you an overview of how Mac OS X used launchd to manage
these types of on-demand and always-on services.

But my app is a "normal" Cocoa App, it's not a daemon or an agent.

It's still essentially an agent, just one that runs in the foreground, not the background.


You can use launchd to keep your app alive. That way you, don't have to worry about adding code to your application to do it, you just have to ensure the launchd property list is in the right place.

That will also make development of your application easier, because your application can run normally; you won't have to put a bunch of extra code into it to disable its keep-alive behavior during development.

  -- Chris

_______________________________________________

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: Several Questions
      • From: Todd Heberlein <email@hidden>
References: 
 >Several Questions (From: Ammar Ibrahim <email@hidden>)
 >Re: Several Questions (From: Kyle Sluder <email@hidden>)
 >Re: Several Questions (From: Ammar Ibrahim <email@hidden>)
 >Re: Several Questions (From: Chris Hanson <email@hidden>)
 >Re: Several Questions (From: Ammar Ibrahim <email@hidden>)

  • Prev by Date: Re: MSN preference
  • Next by Date: Re: Several Questions
  • Previous by thread: Re: Several Questions
  • Next by thread: Re: Several Questions
  • Index(es):
    • Date
    • Thread