Advice for ASP.NET to VB.NET service communications

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I was wondering if there was any advice out there or best practices regarding
ASP.NET communicating with a VB.NET service. I need to send some simple
commands to a VB.NET service I built, what is the recommended way of doing
this? Is there a way to use web services to do this or is that backwards??
Any advice would be greatly appreciated.

TIA,
Blax...
 
Web services are certainly an option, as they are a form of interface.
Remoting is a better "web service" option for this type of communication, as
it does not tie you to HTTP.

You can also aim at Enterprise Services, if you are more comfortable with
COM+, but realize you will force a bit of interop into the scenario (although
it is hidden from you).

As MS moves towards SOA, you will see the web service idea, both ASMX and
Remoting types of services, becomming more common as an interface.


---

Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA

***************************
Think Outside the Box!
***************************
 
Thank you for the information, I guess I am just unclear on how this works. I
do not understand how an asp.net site can communicate with a service (
service as in services.msc or net stop service_name) that is running on a
server using a webservice. Would the webservice need to communicate with the
service via a winsock or tcp port connection??

Thank you,
Blax...
 
with any interprocess communication, there are only a few real options.
One is for process A (the asp.net site) to put an artifact in a place where
process B (the web service) can find it.
This could mean having the aspnet app drop an xml file to a file share.
Alternatively, you could write to a database table.

Another method is for the windows service to listen on a TCP port and have
the web service throw a message to the port.
This is my least favorite method.

Another way (which I like) is using MSMQ. The ASPNET site could throw a
message to a message queue that the windows service will monitor.

I really don't know what your windows service does, or why you need to
communicate, so I'm speaking in generalities. If you provide more info on
the business problem, that may help...

--
--- Nick Malik [Microsoft]
MCSD, CFPS, Certified Scrummaster
http://blogs.msdn.com/nickmalik

Disclaimer: Opinions expressed in this forum are my own, and not
representative of my employer.
I do not answer questions on behalf of my employer. I'm just a
programmer helping programmers.
--
 
Ahh, that helps tremendously, thank you. I have implemented a test using SQL
in the mannor you are describing.

Thanks,
Blax.
 
Back
Top