?
Solved

Best way to deploy a service.

Posted on 2006-04-14
4
Medium Priority
?
270 Views
Last Modified: 2008-02-01
I have an application that I want to start when ever the computer starts up.  This application will process Text Files in a given directory and upload the data to a SQL server database. What would be the best approach for deploying this application as I want as little user interaction as possible?  The only user interface will be a system tray Icon which will have a status context menu.

If I could use click once deployment I could hard code in the connection string to the database if the connection ever changes I just redeploy the application. Does clickonce issue a single Exe file that I could use in a bat file?

Another option would be to start the application passing the connection string as the parameter.  I would place the startup script in the Startup folder.

What about a windows service as an option?

Any guidance would be appreciated.

Thanks in advance,

Dan
0
Comment
Question by:DigitalDan3
  • 2
  • 2
4 Comments
 
LVL 37

Accepted Solution

by:
gregoryyoung earned 1000 total points
ID: 16455851
This definitely sounds like a windows service would be the best fit for you (doesn't need a user logged in)

I would include a front end app that communicates with the windows service to show its status, it could also allow for configuration (i.e. saves a connection string encrypted in the registry)

Cheers,

Greg
0
 
LVL 6

Assisted Solution

by:JRossi1
JRossi1 earned 1000 total points
ID: 16455890
Based on your description of the task, a Windows Service seems like the best way to go.  You can use the .Net NotifyIcon to show the application icon in the system tray.  Also, a windows service can be scheduled so you can set the process to run at a certain day, time etc....  

If you are using VS 2005( .NET 2.0) then one click deployment will work.  When the service starts, it can check for any updates.  You can configure the one-click deployment to perform a 'Silent Install'.  The user would be unaware of the update.
0
 
LVL 37

Expert Comment

by:gregoryyoung
ID: 16457889
JRossi:

Maybe I am missing something here.

You suggest that the service use a notifyicon? This is flat out bad practice (if it works at all, it requires interact with desktop to be enabled which is highly frowned upon due to security reasons)

As for "scheduling" windows services this is a highly non-standard practice .. most services are up and running on their own, handling any scheduling on their own or the task is implemented as a console app and then run from a scheduling service as it produces the same net effect without the overhead and management problems of an additional service.

As for click once deployment it doesn't support windows services (unless this has recently changed)

Can you bring up a reference for anything of this?


0
 
LVL 6

Expert Comment

by:JRossi1
ID: 16468676
Fair enough....   Concerning click-once deployment, here, changes are pushed to the clients using the installer tool on a scheduled basis.  I was under the impression that the Windows Services were developed using click-once deployment.  
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
Parsing a CSV file is a task that we are confronted with regularly, and although there are a vast number of means to do this, as a newbie, the field can be confusing and the tools can seem complex. A simple solution to parsing a customized CSV fi…
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
Loops Section Overview

850 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question