Should I make my application a service or a console application? [closed] - c#

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
I am planning to write a web server in c# that will run on my computer. I've heard that windows services are good for such tasks because they can start on startup and because they run in the background and don't interfere with your work. The only problem with this is that I would like to see the activity on my web server through a terminal. I don't think services can do this, but it's not a big problem because I'm sure there is a way to make the service run the server and create a separate console application to interface with the server service.
My question is, why bother? Can't I just have a console application run everything and also handle the terminal interface? The only reason I would consider using a service is if it offers some kind of performance boost. Does it?

Windows service - is not about performance boost. Your choice depends on what is the main goal of your service. If it's just an utility app and you plan to start and stop it manually perhaps console app will be good for you, else IMHO you should consider windows service that store logs and/or push events + console/wpf/winforms or any other appropriate kind of application for monitoring purposes.

Related

Best method for sending bulk sms and email. Whether a cron or a scheduler service [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 1 year ago.
Improve this question
I want to send Email and SMS in bulk in c# MVC. So, method would be better, cron in a web application or separate scheduler service for it?
I have a web application running already. So, should I integrate the cron in the web app itself or create a new scheduler service for it.
I want to use the best method in terms of reliability, speed and load of data.
its better to make separate service for that for the below reasons :
1- Maintainability : If there is a problem in sending mails or SMS you know where you need to check without going to your main solutions.
2- Availability & Scalability : You can scale this Module only or if any thing happens to your main app, your mailing and sms will still be working.
3- Separation of Concerns : SMS and Emailing is considered to be a cross cutting functionality that it will be used in alot of places in system, so it is better to have it in one separate place.
4- I/O latency : like this you will avoid any latency or any performance effects on your main business domain.

c# notify a running process [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
Is it possible to somehow notify a running process from the "outside"?
I have a C# program that theoretical runs forever. And I would like to notify it to trigger some action manually. It would be best, if this solution is possible on Windows and Linux (mono).
EDIT:
The solution should work without a user interface
My program is, as for now, a part of web service. On initializing, a new Theread is created, which uses the Task class to stay alive
Take your forever-running-process and let it provide a webservice other processes can call.
You might use any cross-plattform webservice framework like WebApi or ServiceStack to achieve this via HTTP calls. This will even work over the internet (if the machines can reach each other).
There are dozens of approaches. You could also use named pipes for example, or put commands into a database (the other process has to query regularly) or - if you're fearless enough - write/read files to communicate. Be creative ...

Building a server API with .NET [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I know ASP.NET Web API is the big thing now, but isn't it mainly for client consumed services (browser apps, mobile apps etc.)? I need to develop a server side API that is called by other servers in my app to perform operations, not retrieve models of data, but RPC calls, for example, UpdateCache(), CalculateAtomicExplosion(), SendNotification(), FindTheRabbit(). I used to do these things with WCF, but I see it's slowly becomes replaced by Web API, but is Web API designed for that task? Will I be able to bind a remote service and call it with a proxy class like I used to with WCF / asmx? Communicate with CLR objects? etc..
What's the best practice on completing this task with current technologies?
Thanks!

I Have a windows form application in C# and want to publish it in a LAN via ASP.NET ?? [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I have made a C# Windows Forms application and connected it with Microsoft SQL Server.
I want to allow all machines in the LAN to use the program and connect to the SQL server but without having to set up the program on all the machines.
I wondered if I can do this with ASP.NET.
How do I do it? Are there any tutorials for this sort of task?
Anything on the difference between web forms, MVC Web API .. ETC.
It's very easy! Create an empty Web Forms project, drag controls onto it in the same manner you did with your desktop application. Then add your code, objects, logic, etc => see what you've got in the browser and if you like that publish it to the server and guess what?...RIGHT! Now it's accessible over the network without any need to install the desktop version.
Hope that answers your question.

Best way to communicate with a 3rd system via xml [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I am looking for the best way to implement, let's say a middle tier.
In the company I working for, we have two systems written with different programming languages. Each one must communicate with a third system via xml (rest and soap).
The first thing that came in my mind was to create a web application which would accept the calls from our internal systems but I stopped this implementation as I faced some issues regards the soap serialization (How could I do this?).
Except this I thought of WCF but I don't know if it is an appropriate solution for my case.
So, I would like to know which is the best way to implement this.
I'll appreciate any comment
Thanks
You should use WCF for the middle-tier since it provides you with everything you need.
Serialization
Interoperability with Other Web Services Platforms
Interaction with Applications built on other technologies, such as J2EE application servers, that support standard Web services. These applications can be running on Windows machines or on machines running other operating systems.
Security
SOAP All Version and REST
Bindings
Protocols
Discovery

Categories

Resources