Run RavenDb in background, not as service

24 views
Skip to first unread message

Peter

unread,
Jun 11, 2010, 12:00:51 PM6/11/10
to ravendb
For now, my application starts up the console application of RavenDb
(but without a console window), and closes it when my application
exits.
The reason I'm doing this, is I would like to avoid installing RavenDb
as a service, due to my target audience (totally non-tech).
Yet, I'm not 100% comfortable with this. Are there any problems with
this? Is the console app the debug build of RavenDb, and does this
mean my app would run sub-optimally? Also, when my application exits,
I kill the process RavenDb.exe, but maybe RavenDb is still running/
processing things?

What are your thoughts? Possibly I could startup RavenDb from my own
managed code (but I'll have to update to VS2010 first then)?

Ayende Rahien

unread,
Jun 11, 2010, 12:08:39 PM6/11/10
to rav...@googlegroups.com
Is there a reason that you aren't using the embedded option?

Peter

unread,
Jun 11, 2010, 12:40:19 PM6/11/10
to ravendb
Thanks for the answer. I couldn't take this option, because I don't
have VS2010 yet (so no .NET 4 development also). But I could take my
chances and keep developing with the console app. I might have VS2010
when my app will be released.

Thanks for the answer.

Ayende Rahien

unread,
Jun 11, 2010, 1:06:46 PM6/11/10
to rav...@googlegroups.com
In that situation, then yes, running as console app would work.

Ayende Rahien

unread,
Jun 11, 2010, 1:07:04 PM6/11/10
to rav...@googlegroups.com
You might want to ensure that you close Raven gracefully, rather than forcefully, though

Peter

unread,
Jun 12, 2010, 12:01:07 PM6/12/10
to ravendb
Thanks, when I have VS2010, I'll change to the embedded option, but
for now I'm using it as documented op my blog (http://
petermorlion.blogspot.com/2010/06/running-ravendb-only-when-
your.html).

On 11 jun, 19:07, Ayende Rahien <aye...@ayende.com> wrote:
> You might want to ensure that you close Raven gracefully, rather than
> forcefully, though
>
>
>
> On Fri, Jun 11, 2010 at 8:06 PM, Ayende Rahien <aye...@ayende.com> wrote:
> > In that situation, then yes, running as console app would work.
>

Peter

unread,
Jun 12, 2010, 4:57:54 PM6/12/10
to ravendb
Actually, I'm struggling to close RavenDb gracefully. Kill does the
job, but that's kind of harsh, as you said. But Close() or
CloseMainWindow() only works when there is a GUI. Any ideas?

On 11 jun, 19:07, Ayende Rahien <aye...@ayende.com> wrote:
> You might want to ensure that you close Raven gracefully, rather than
> forcefully, though
>
>
>
> On Fri, Jun 11, 2010 at 8:06 PM, Ayende Rahien <aye...@ayende.com> wrote:
> > In that situation, then yes, running as console app would work.
>

Ayende Rahien

unread,
Jun 12, 2010, 7:51:22 PM6/12/10
to rav...@googlegroups.com
Close it by sending a \r\n on the standard input

Peter

unread,
Jun 14, 2010, 1:07:00 PM6/14/10
to ravendb
Thanks. I should've found that myself. D'oh!
Reply all
Reply to author
Forward
0 new messages