Posts: 42
Threads: 8
Joined: Mar 2018
Reputation:
1
03-20-2018, 10:00 PM
(This post was last modified: 03-20-2018, 10:00 PM by davenovo.)
Hello. 2 questions.
I know that you do not recommend deploying the Intraweb standalone server. There is also a web page here that describes deploying as a windows service.
I have 2 questions.
1. Is the window service as described above ok for production use? If not, what are the limitation I should be aware of?
2. Does this take exclusive control over the port to which its bound. i.e. I have a webserver using http.sys directly. It only handles requests if the request matches the URL it is serving. Otherwise, it passes the request along to anyone else listening to the same port. Does the webserver built into the Intraweb windows service described above behave in the same way?
Posts: 1,136
Threads: 37
Joined: Mar 2018
Reputation:
30
Location: Limassol, Cyprus
Services are suitable for deployment. You can use the non service too, but the issue is that it does not auto start and requires a use to log in to Windows. A service can auto start and does not require a user to log into the server.
By default it will listen on all IPs on the port you specify, but so do IIS and Apache etc. If you want it to listen only on a single IP (or specific multiple) you need to set the bound IPs - off the top of my head they are properties of the ServerController.
Posts: 1,136
Threads: 37
Joined: Mar 2018
Reputation:
30
Location: Limassol, Cyprus
You can also deploy IntraWeb on IIS, but the deployment is more complicated to set up.
Posts: 42
Threads: 8
Joined: Mar 2018
Reputation:
1
In my understanding, when IIS listens to port 80, it somehow takes exclusive control of that port, so other applications will not get http requests to that port. So if You have IIS on port 80, you cannot have anything else on that computer listening to port 80. Does the Intraweb service behave the same way, or does the Intraweb service allow other applications to listen and respond on port 80?
Posts: 1,136
Threads: 37
Joined: Mar 2018
Reputation:
30
Location: Limassol, Cyprus
As I said previously it can do both.
IIS can be configured to listen on specific IPs rather than all, and so can IntraWeb and I mentioned how above as well.
Posts: 42
Threads: 8
Joined: Mar 2018
Reputation:
1
I am not sure you are understanding my question.
I understand that you can configure IIS and/or Intraweb to listen to specific ports, or listen to all ports. That is 100% clear. You said it many times.
However, my understanding is that once IIS is configured to listen to port 80 (as an example) it blocks other applications from listening to port 80. Thus, if you have IIS running on port 80, you need to have other applications on that same machine listening on other ports. Thus, if IIS is running on port 80, and you want to have other webservers listening on that machine, you have to have them use ports other than port 80. Which means opening up non-standard ports, which system admins dont like.
I understand you can configure Intraweb to listen to whatever port you want. BUT, if you have configured intraweb running as a windows service to listen to port 80 (via the servercontroller as you mentioned) does it block other applications from listening to port 80?
Posts: 2,261
Threads: 196
Joined: Mar 2018
Reputation:
86
Location: Auckland, New Zealand
03-21-2018, 07:18 AM
(This post was last modified: 03-21-2018, 08:35 PM by Alexandre Machado.)
(03-21-2018, 12:22 AM)davenovo Wrote: I am not sure you are understanding my question.
I understand that you can configure IIS and/or Intraweb to listen to specific ports, or listen to all ports. That is 100% clear. You said it many times.
However, my understanding is that once IIS is configured to listen to port 80 (as an example) it blocks other applications from listening to port 80. Thus, if you have IIS running on port 80, you need to have other applications on that same machine listening on other ports. Thus, if IIS is running on port 80, and you want to have other webservers listening on that machine, you have to have them use ports other than port 80. Which means opening up non-standard ports, which system admins dont like.
I understand you can configure Intraweb to listen to whatever port you want. BUT, if you have configured intraweb running as a windows service to listen to port 80 (via the servercontroller as you mentioned) does it block other applications from listening to port 80?
You are correct.
Also, a port is exclusive so IntraWeb will block any other applications from using that port to receive requests, just like IIS does. You can, however, configure IIS to redirect all incoming requests to some specific web site to your IW application with runs as a service, listening to another port.
Posts: 1,136
Threads: 37
Joined: Mar 2018
Reputation:
30
Location: Limassol, Cyprus
Davenovo,
You are confusing ports with IPs. Please reread my response.
Posts: 42
Threads: 8
Joined: Mar 2018
Reputation:
1
Hello,
It seems that Alexandre answered my question
Quote:Also, a port is exclusive so IntraWeb will block any other applications from using that port to receive requests
By his answer I understand that if Intraweb is listening on port 80, it will block other applications from listening on port 80. I definately dont understand what IP has to do with this. In general, as I understand it (and I may be wrong) a webserver does not know which IP a request will be coming from so it listens on all IP on a certain port. I will need that behaviour.
Other Delphi webservers, like TMS sparkle, plug into Http.sys. Somehow, that allows it to only handle port 80 (from all IP addresses) for URLs that it cares about. If it does not care about the URL being requested, it just ignores it, and other services plugged into http.sys can handle the request. That way, you can have a lot of independent TMS Sparkle webservers all listening to port 80 and handling the requests that they care about.
I dont want to have to have my end users to configure IIS. That is why I want to use the standalone server. However, I want to have several applications web applications on the same computer. An intraweb app for the website, a TMS XData app for the REST services. Thus, I am trying to figure out a way to get them all to work together. If intraweb takes over port 80 exclusively, then this will be more difficult.
Posts: 42
Threads: 8
Joined: Mar 2018
Reputation:
1
For further clarification, here is some info on HTTP.Sys (from https://www.mikeplate.com/2011/11/06/sto...n-windows/)
First of all, the way http.sys works on newer Windows versions is a very useful feature. The reason behind http.sys is to have a single system service that listens on the all-important port 80 and be a mediator to different applications and services in the system that might like to handle incoming requests on port 80 but for different urls. What an integrated Windows application does, is use a Windows API for registering its own urls and then have them directed to itself. At the same time, there can be other applications also getting incoming requests to port 80 but for different registered urls.
So I am wondering if there is a way make intraweb register itself with HTTP.SYS and only register a certain URL, instead of blocking the entire port 80.
|