Hi all,
at the moment i am developing an app which is sort of an interface to
copy data from one database to another and it shall run as a service.
As there are several databases the app must be installed and run in
multiple instances with the configuration data (database, login, etc.)
stored in an app.config file.
Up to now I was concerned with Windows CE apps only so both running an
app as service and running multiple instances of an app is new to me. I
figured out how to create and install a single service app, but now I
don't know how to "multiply" it. I imagine that every app must have its
proper name, so do I have to compile as many instances of my app with
different names as I will need? Or is there a way to "configure" my
single app in a way that I can run it more than once, each being an own
service for windows? And how could I manage the setup then, because
Microsoft's service app sample only shows serveral instances running as
one service, but every instance must be a service of its own.
Any help is appreciated, thanks!
Regards
Roland 4 2050
Roland,
As a suggestion, would it not be better to have a multithreaded application?
There would be one config file (or registry hive etc), containing your
different configurations. When the service starts, it would first load the
config into a queue, then create N threads (where N is the number of
databases you want to read from). Each thread would then take the next
configuration block of the queue, and process to copy that database.
This would mean that you could easily stop and start the threads via a
global "running" flag which you simply set to false. Similarly, starting the
process would kick off all the threads to do your work.
It would be one application, installed at one location, running as one
process with many threads.
If you need more help with ideas for implementing this, let me know.
hope that helps and good luck.
Daniel.
"Roland Riess" <ce******@gmx.n et> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. .. Hi all,
at the moment i am developing an app which is sort of an interface to copy data from one database to another and it shall run as a service. As there are several databases the app must be installed and run in multiple instances with the configuration data (database, login, etc.) stored in an app.config file.
Up to now I was concerned with Windows CE apps only so both running an app as service and running multiple instances of an app is new to me. I figured out how to create and install a single service app, but now I don't know how to "multiply" it. I imagine that every app must have its proper name, so do I have to compile as many instances of my app with different names as I will need? Or is there a way to "configure" my single app in a way that I can run it more than once, each being an own service for windows? And how could I manage the setup then, because Microsoft's service app sample only shows serveral instances running as one service, but every instance must be a service of its own.
Any help is appreciated, thanks!
Regards Roland
Hi Daniel,
I don't know why but your answer reached me only now, more than one day
later (as well as my own post in this newsgroup, by the way).
Thanks for your reply, but the "design" of several independent services
is a customer request, so I have no choice - even if your solution was
rather convincing to me!
Regards
Roland
Dan Bass schrieb: Roland,
As a suggestion, would it not be better to have a multithreaded application?
There would be one config file (or registry hive etc), containing your different configurations. When the service starts, it would first load the config into a queue, then create N threads (where N is the number of databases you want to read from). Each thread would then take the next configuration block of the queue, and process to copy that database.
This would mean that you could easily stop and start the threads via a global "running" flag which you simply set to false. Similarly, starting the process would kick off all the threads to do your work.
It would be one application, installed at one location, running as one process with many threads.
If you need more help with ideas for implementing this, let me know.
hope that helps and good luck.
Daniel.
"Roland Riess" <ce******@gmx.n et> wrote in message news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
Hi all,
at the moment i am developing an app which is sort of an interface to copy data from one database to another and it shall run as a service. As there are several databases the app must be installed and run in multiple instances with the configuration data (database, login, etc.) stored in an app.config file.
Up to now I was concerned with Windows CE apps only so both running an app as service and running multiple instances of an app is new to me. I figured out how to create and install a single service app, but now I don't know how to "multiply" it. I imagine that every app must have its proper name, so do I have to compile as many instances of my app with different names as I will need? Or is there a way to "configure" my single app in a way that I can run it more than once, each being an own service for windows? And how could I manage the setup then, because Microsoft's service app sample only shows serveral instances running as one service, but every instance must be a service of its own.
Any help is appreciated, thanks!
Regards Roland
Hmm, it's not really a desirable windows operation. Another tier that
resides with a different company in a project I'm working on tried this and
it proved more a hassle than it was worth.
Still, it can be done with only one service install. You just need to create
N amount of service entries in the registry ( myService1, myService2 etc
etc ) with their own config. Then you need to ensure that the service you're
using isn't accessing any shared global data which could be accessed by
multiple services when you're only expecting one to access it...
I tried these too and there were a few ideas that came up straight away http://groups.google.co.uk/groups?hl...ows+service%22 http://www.google.co.uk/search?q=run...n&start=0&sa=N http://www.dotnet247.com/247referenc...48/242835.aspx
good luck!
"Roland Riess" <ce******@gmx.n et> wrote in message
news:O0******** ******@TK2MSFTN GP09.phx.gbl... Hi Daniel,
I don't know why but your answer reached me only now, more than one day later (as well as my own post in this newsgroup, by the way).
Thanks for your reply, but the "design" of several independent services is a customer request, so I have no choice - even if your solution was rather convincing to me!
Regards Roland
Dan Bass schrieb: Roland,
As a suggestion, would it not be better to have a multithreaded application?
There would be one config file (or registry hive etc), containing your different configurations. When the service starts, it would first load the config into a queue, then create N threads (where N is the number of databases you want to read from). Each thread would then take the next configuration block of the queue, and process to copy that database.
This would mean that you could easily stop and start the threads via a global "running" flag which you simply set to false. Similarly, starting the process would kick off all the threads to do your work.
It would be one application, installed at one location, running as one process with many threads.
If you need more help with ideas for implementing this, let me know.
hope that helps and good luck.
Daniel.
"Roland Riess" <ce******@gmx.n et> wrote in message news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
Hi all,
at the moment i am developing an app which is sort of an interface to copy data from one database to another and it shall run as a service. As there are several databases the app must be installed and run in multiple instances with the configuration data (database, login, etc.) stored in an app.config file.
Up to now I was concerned with Windows CE apps only so both running an app as service and running multiple instances of an app is new to me. I figured out how to create and install a single service app, but now I don't know how to "multiply" it. I imagine that every app must have its proper name, so do I have to compile as many instances of my app with different names as I will need? Or is there a way to "configure" my single app in a way that I can run it more than once, each being an own service for windows? And how could I manage the setup then, because Microsoft' s service app sample only shows serveral instances running as one service, but every instance must be a service of its own.
Any help is appreciated, thanks!
Regards Roland
Hi Dan,
sorry for the delay but I was busy as I had to finish my "multiple
service" app by today. Finally I opted for a script installation
solution which I found through one of your links. A modified installer
class allows to enter parameters for the setup like service name, user
and password, so that the same code assembly can be used for all
services. The different servers and databases that must be accessed can
be configured by an app.exe.config for each service which may have
identical names as every service is installed in its own directory.
This may not always be a perfect solution but it is just what I need.
Here is the link for everybody that might have the same problem: http://www.codeproject.com/dotnet/Sc...iceInstall.asp
Thanks again for your help!
Regards
Roland
Dan Bass schrieb: Hmm, it's not really a desirable windows operation. Another tier that resides with a different company in a project I'm working on tried this and it proved more a hassle than it was worth.
Still, it can be done with only one service install. You just need to create N amount of service entries in the registry ( myService1, myService2 etc etc ) with their own config. Then you need to ensure that the service you're using isn't accessing any shared global data which could be accessed by multiple services when you're only expecting one to access it...
I tried these too and there were a few ideas that came up straight away
http://groups.google.co.uk/groups?hl...ows+service%22
http://www.google.co.uk/search?q=run...n&start=0&sa=N
http://www.dotnet247.com/247referenc...48/242835.aspx
good luck!
"Roland Riess" <ce******@gmx.n et> wrote in message news:O0******** ******@TK2MSFTN GP09.phx.gbl...
Hi Daniel,
I don't know why but your answer reached me only now, more than one day later (as well as my own post in this newsgroup, by the way).
Thanks for your reply, but the "design" of several independent services is a customer request, so I have no choice - even if your solution was rather convincing to me!
Regards Roland
Dan Bass schrieb:
Roland,
As a suggestion, would it not be better to have a multithreaded applicatio n?
There would be one config file (or registry hive etc), containing your different configurations. When the service starts, it would first load the config into a queue, then create N threads (where N is the number of databases you want to read from). Each thread would then take the next configuratio n block of the queue, and process to copy that database.
This would mean that you could easily stop and start the threads via a global "running" flag which you simply set to false. Similarly, starting the process would kick off all the threads to do your work.
It would be one application, installed at one location, running as one process with many threads.
If you need more help with ideas for implementing this, let me know.
hope that helps and good luck.
Daniel.
"Roland Riess" <ce******@gmx.n et> wrote in message news:%2***** ***********@TK2 MSFTNGP09.phx.g bl...
Hi all,
at the moment i am developing an app which is sort of an interface to copy data from one database to another and it shall run as a service. As there are several databases the app must be installed and run in multiple instances with the configuration data (database, login, etc.) stored in an app.config file.
Up to now I was concerned with Windows CE apps only so both running an app as service and running multiple instances of an app is new to me. I figured out how to create and install a single service app, but now I don't know how to "multiply" it. I imagine that every app must have its proper name, so do I have to compile as many instances of my app with different names as I will need? Or is there a way to "configure" my single app in a way that I can run it more than once, each being an own service for windows? And how could I manage the setup then, because Microsoft 's service app sample only shows serveral instances running as one service, but every instance must be a service of its own.
Any help is appreciated, thanks!
Regards Roland
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Ken Lindner |
last post by:
I have a need to become familiar with SQL Server 2000 for work.
Needless to say I am new to SQL Server any version, but not IT in
general. My employer has provided me with the SQL Server 2000
Personal disk from the SQL Server 2000 Enterprise kit as this is
reported here on the MSDN web site to be the version that is supported
on Windows XP. In fact so many of you kind people confess to having
succeeded in doing it.
I have tried...
|
by: Vlad |
last post by:
Is there any way to install multiple instances of the same windows service
designed with VS.NET 2003? I tried copying the binaries into a separate
folder and then copying registry entries for the original service under a
new name but the SCM complains that the executable does not have this
service implemented.
Please note that I need to have distinct instances of executables installed
not merely multiple windows services defined within...
|
by: Mike |
last post by:
Looking to find any information on how to properly configure multiple
instances of DB2. This is on Win2k db2 ver 7.2. I am basically looking
for information on how the multiple instance settings should
configured to work, how memory is shared or not, etc. I can not seem
to find any good links to this information.
Thanks,
Mike
|
by: alexs |
last post by:
Chaps,
I'm having a small problem installing db2 on a Red Hat Enterprise
server (version 4)
Basically I installed DB2 V8.1 , applied fixpak 5 and then the 2.6
kernel specific fixpak 9 update. I then created the the administration
instance and some "user" instances
db2admin start works just fine but whenever I try and run db2start in
one of the "user" instances I get an SQL1024C error message.
|
by: J |
last post by:
hi,
I'm having a problem installing a service created in vb.net 2003 on a
windows 2000 server. I have installed the service on a few XP machines with
out any problems...but the 2 servers (win 2000 server sp4) I have triend
have the same error (both are on diffrent domains and have framework v1.1
installed; 1 is a domain controler, the other is not)
An exception occurred during the Install phase.
System.ComponentModel.Win32Exception:...
| |
by: Andrea Vincenzi |
last post by:
Help me please, I'm totally stuck!
My Visual Studio 2003 debugger stopped working after I installed
Windows XP Service Pack 2. Here is what happens (with any project,
even a "Hello, world" message): the first time I open a project and
try to start it in debug mode, Visual Studio hangs before executing
the first line of code. The only way to stop it is to kill the process
using the Task Manager.
If I open the same project a second time and...
|
by: John |
last post by:
I currently have a Windows Service that runs Transactions that are very
Processor/Memory Intensive. I have a requirement to deploy multiple
instances of the Web service on the Same server. Each Instance needs to
run in its own process.
My current approach to this is to put all the logic into a separate
"Worker" assembly and install it into the GAC. I'm then going to create
Multiple Windows Services (i.e. MyService1, MyService2 etc..)...
|
by: vijaykumars |
last post by:
+-----------------------------------------------------------------------------+
Summaries:
+-----------------------------------------------------------------------------+
Installation Summary
--------------------
Name Level Part Event Result
-------------------------------------------------------------------------------
db2_08_01.essg 8.1.1.64 USR APPLY ...
|
by: =?Utf-8?B?RWxpb3Ro?= |
last post by:
I try to install Windows Services but it show this error during the
installation process, "Insufficient System resources exist to complete the
requested service."
I created this Services in VB 2005.
I has other Windows Services installed on this machine. I try to install in
other computer with the same specification and its is OK.
Specification
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |