Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Re: win32 service code


  • From: "Magnus Hagander" <mha(at)sollentuna(dot)net>
  • To: "Claudio Natoli" <claudio(dot)natoli(at)memetrics(dot)com>, "PgSql-Win32" <pgsql-hackers-win32(at)postgresql(dot)org>
  • Subject: Re: win32 service code
  • Date: Fri, 28 May 2004 11:29:57 +0200
  • Message-id: <6BCB9D8A16AC4241919521715F4D8BCE34BB59(at)algol(dot)sollentuna(dot)se>

> My 2c,
I'll add mine as well..

> > 1) Separate binary "pgservice.exe" that will CreateProcess() the 
> > postmaster.exe.
> > Advantages: Zero impact on postmaster code. Simple to do.
> > Disadvantages: Adds a platform-specific binary.
> 
> My preference. Personally, I think we should make this pg_ctl.

That sounds like a good idea.

> > 2) Include in postmaster doing an extra CreateProcess().
> > Advantages: No extra binary. Low impact on postmaster code.
> > Disadvantages: Two postmaster.exe:s. running (confusing? overhead?)
>  
> This is what I've currently got. I pretty much hate seeing 
> two postmaster.exe/s running.

In my opinion, this is the worst idea.

> > 3) Include in postmaster but running on a separate thread 
> (not process 
> > as
> (2))
> > Advantages: No extra binary. No extra process. Most integration.
> > Disadvantages: Probably larger impact on postmaster code.
> 
> IMHO, the worst of all options.

Since there is only very little stuff gonig on in a different thread, I
don't think this is the worst idea at all. For me, 1 and 3 are about as
good.

> I'm itching to throw this code somewhere :-)

Yay :-)

From what I can read of the people that post it, it seems option 1 is
probably the most popular one. So unless someone objects, I suggest you
move down that path :-)
(It shouldn't be that much work moving yuor stuff from postmaster,
AFAICS)


//Magnus




Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group