[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.remoting

CAO remoting and Web gardens

John Aranha

9/24/2004 2:32:00 PM

I have come across an issue when using CAOs and enabling the Web garden on
the process model. If gardening is disabled, eveything works fine. If it
is enabled, the remote object is created and appears to marshal just fine,
however, any calls on the proxy result in the standard error,

System.Runtime.Remoting.RemotingException: Requested Service not found.

First, are CAOs supported under the Web garden process model? Second, if
supported, are there any special configurations that are required? Or any
known issues?

I get the same results on both of the following configurations:
Windows 2000 w/ .NET 1.1
Windows XP w/ .NET 1.1 SP1

Thanks,
Dolph Priest


5 Answers

Sam Santiago

9/24/2004 3:23:00 PM

0

I have never actually tried it, but I would deduce that it's not supported.
A Web Garden is logically like a web farm, but it's multiple processes on
one machine vs. a single process running on multiple machines. You have a
single URL that can be serviced by two (or more) app domains (processes).
Remoting is essentially an app domain to app domain communication mechanism.
You create a remote object, but when you invoke a method on it you have no
control over which app domain will service that request, so most likely the
method invocation is going to a different app domain than the one where the
object was created; therefore the error.

Here are some links with an excerpt from each:

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnpag/html/scalenetc...
"You should always test and evaluate whether Web gardens improve performance
for your scenario. They are not generally advocated as an option for most
applications."

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpguide/html/cpconperformanceapplicationpoolse...
"Because Web gardens enable the use of multiple processes, each process will
have its own copy of application state, in-process session state, caches,
and static data. Web gardens should not be used for all applications,
especially if they need to maintain state." <CAOs are stateful components>

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnpag/html/scalenetc...
"Consider the limited scalability offered by CAOs. CAOs are not generally
recommended, due to scalability limitations. Objects activated at the client
cause the client proxy reference to be bound to a specific server where the
server object was activated. This server affinity reduces the ability of
your application to scale, and it negatively impacts performance because
load on the individual server increases. When the server load increases,
there is no way to offload the calls from the client to another server in
the farm that has less load. If you have a single server solution, this is
not an issue. However, if you need to scale out and use a server cluster,
CAOs significantly limit scalability. CAOs do provide the benefit of
allowing the server object to maintain state across method calls. Generally,
it is better to design stateless objects for performance and scalability."

Thanks,

Sam
--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
<SolDel@mercer.com> wrote in message
news:uRTS$MkoEHA.2588@TK2MSFTNGP12.phx.gbl...
> I have come across an issue when using CAOs and enabling the Web garden on
> the process model. If gardening is disabled, eveything works fine. If it
> is enabled, the remote object is created and appears to marshal just fine,
> however, any calls on the proxy result in the standard error,
>
> System.Runtime.Remoting.RemotingException: Requested Service not
found.
>
> First, are CAOs supported under the Web garden process model? Second, if
> supported, are there any special configurations that are required? Or any
> known issues?
>
> I get the same results on both of the following configurations:
> Windows 2000 w/ .NET 1.1
> Windows XP w/ .NET 1.1 SP1
>
> Thanks,
> Dolph Priest
>
>


Ken Kolda

9/24/2004 3:34:00 PM

0

If you're using CAOs from within an IIS-based remoting app then you
shouldn't use web gardens. When you use a web garden you are instructing IIS
to spin up several distinct processes to handle your requests. Incoming
requests are then sent to these processes in a round robin fashion. Your CAO
will live in whatever process it was first instantiated in. If subsequent
requests come in for your CAO and those requests are sent to the wrong
process, the CAO can't be found so you get the "Requested service not found"
error.

Ken


<SolDel@mercer.com> wrote in message
news:uRTS$MkoEHA.2588@TK2MSFTNGP12.phx.gbl...
> I have come across an issue when using CAOs and enabling the Web garden on
> the process model. If gardening is disabled, eveything works fine. If it
> is enabled, the remote object is created and appears to marshal just fine,
> however, any calls on the proxy result in the standard error,
>
> System.Runtime.Remoting.RemotingException: Requested Service not
found.
>
> First, are CAOs supported under the Web garden process model? Second, if
> supported, are there any special configurations that are required? Or any
> known issues?
>
> I get the same results on both of the following configurations:
> Windows 2000 w/ .NET 1.1
> Windows XP w/ .NET 1.1 SP1
>
> Thanks,
> Dolph Priest
>
>


John Aranha

9/24/2004 6:19:00 PM

0

Thanks Ken.

I fully understand the concept of web gardens as relates to worker
processes. One thing that I failed to mention was that this works on four
servers in an NLB cluster. The fifth server is where we are having an
issue. I find it hard to believe that the first four servers work as a mere
coincidence - but I can find no other reason.

My observations indicate that when a CAO is marshaled, it uses the primary
IP address on the primary adapter. In an NLB environment this is typically
the machines individual public IP address - which provides the required
server affinity. My assumption was that there *may* be a similar mechanism
in the remoting infrastructure to supply process affinity so that subsequent
request for the same marshaled URI are routed to the same process (instead
of following the round robin distribution).

At this point, I have four machines that work, and two that do not. I am
looking for some empirical evidence that can explain the discrepancy. Am I
just lucky in the case of the four? I bet not.

Dolph

"Ken Kolda" <ken.kolda@elliemae-nospamplease.com> wrote in message
news:OTHPCwkoEHA.3900@TK2MSFTNGP10.phx.gbl...
> If you're using CAOs from within an IIS-based remoting app then you
> shouldn't use web gardens. When you use a web garden you are instructing
> IIS
> to spin up several distinct processes to handle your requests. Incoming
> requests are then sent to these processes in a round robin fashion. Your
> CAO
> will live in whatever process it was first instantiated in. If subsequent
> requests come in for your CAO and those requests are sent to the wrong
> process, the CAO can't be found so you get the "Requested service not
> found"
> error.
>
> Ken
>
>
> <SolDel@mercer.com> wrote in message
> news:uRTS$MkoEHA.2588@TK2MSFTNGP12.phx.gbl...
>> I have come across an issue when using CAOs and enabling the Web garden
>> on
>> the process model. If gardening is disabled, eveything works fine. If
>> it
>> is enabled, the remote object is created and appears to marshal just
>> fine,
>> however, any calls on the proxy result in the standard error,
>>
>> System.Runtime.Remoting.RemotingException: Requested Service not
> found.
>>
>> First, are CAOs supported under the Web garden process model? Second, if
>> supported, are there any special configurations that are required? Or
>> any
>> known issues?
>>
>> I get the same results on both of the following configurations:
>> Windows 2000 w/ .NET 1.1
>> Windows XP w/ .NET 1.1 SP1
>>
>> Thanks,
>> Dolph Priest
>>
>>
>
>


Sam Santiago

9/24/2004 6:44:00 PM

0

You might be luckier than you think. CAOs are not supported in an NLB
environment and most likely not in web gardens either. Check out this link:

INFO: Configurations That Microsoft Supports for Microsoft .NET Remoting
with Network Load Balancing
http://support.microsoft.com/default.aspx?scid=kb;en...

Even if you think it's working, I would not use a solution in an expected
reliable environment if all documentation is saying it's not supported.

Thanks,

Sam

--
_______________________________
Sam Santiago
ssantiago@n0spam-SoftiTechture.com
http://www.SoftiTe...
_______________________________
<SolDel@mercer.com> wrote in message
news:Ow5RsLmoEHA.1800@TK2MSFTNGP15.phx.gbl...
> Thanks Ken.
>
> I fully understand the concept of web gardens as relates to worker
> processes. One thing that I failed to mention was that this works on four
> servers in an NLB cluster. The fifth server is where we are having an
> issue. I find it hard to believe that the first four servers work as a
mere
> coincidence - but I can find no other reason.
>
> My observations indicate that when a CAO is marshaled, it uses the primary
> IP address on the primary adapter. In an NLB environment this is
typically
> the machines individual public IP address - which provides the required
> server affinity. My assumption was that there *may* be a similar
mechanism
> in the remoting infrastructure to supply process affinity so that
subsequent
> request for the same marshaled URI are routed to the same process (instead
> of following the round robin distribution).
>
> At this point, I have four machines that work, and two that do not. I am
> looking for some empirical evidence that can explain the discrepancy. Am
I
> just lucky in the case of the four? I bet not.
>
> Dolph
>
> "Ken Kolda" <ken.kolda@elliemae-nospamplease.com> wrote in message
> news:OTHPCwkoEHA.3900@TK2MSFTNGP10.phx.gbl...
> > If you're using CAOs from within an IIS-based remoting app then you
> > shouldn't use web gardens. When you use a web garden you are instructing
> > IIS
> > to spin up several distinct processes to handle your requests. Incoming
> > requests are then sent to these processes in a round robin fashion. Your
> > CAO
> > will live in whatever process it was first instantiated in. If
subsequent
> > requests come in for your CAO and those requests are sent to the wrong
> > process, the CAO can't be found so you get the "Requested service not
> > found"
> > error.
> >
> > Ken
> >
> >
> > <SolDel@mercer.com> wrote in message
> > news:uRTS$MkoEHA.2588@TK2MSFTNGP12.phx.gbl...
> >> I have come across an issue when using CAOs and enabling the Web garden
> >> on
> >> the process model. If gardening is disabled, eveything works fine. If
> >> it
> >> is enabled, the remote object is created and appears to marshal just
> >> fine,
> >> however, any calls on the proxy result in the standard error,
> >>
> >> System.Runtime.Remoting.RemotingException: Requested Service not
> > found.
> >>
> >> First, are CAOs supported under the Web garden process model? Second,
if
> >> supported, are there any special configurations that are required? Or
> >> any
> >> known issues?
> >>
> >> I get the same results on both of the following configurations:
> >> Windows 2000 w/ .NET 1.1
> >> Windows XP w/ .NET 1.1 SP1
> >>
> >> Thanks,
> >> Dolph Priest
> >>
> >>
> >
> >
>
>


Ken Kolda

9/24/2004 7:46:00 PM

0

If your client can access the web servers directly (as opposed to only
through a virtual IP that maps through a load balancer), the having a web
farm should work as you noted. A web garden is different though because
there are two processes that effectively share a single listener (IIS). Now
IIS doesn't know anything about remoting -- it just knows when it receives a
request to forward it to the to pass the request to the two processes in
round robin fashion -- it's not inspecting the requests' contents to see if
it's a remoting request and, if so, which process it should go to.

Ken


<SolDel@mercer.com> wrote in message
news:Ow5RsLmoEHA.1800@TK2MSFTNGP15.phx.gbl...
> Thanks Ken.
>
> I fully understand the concept of web gardens as relates to worker
> processes. One thing that I failed to mention was that this works on four
> servers in an NLB cluster. The fifth server is where we are having an
> issue. I find it hard to believe that the first four servers work as a
mere
> coincidence - but I can find no other reason.
>
> My observations indicate that when a CAO is marshaled, it uses the primary
> IP address on the primary adapter. In an NLB environment this is
typically
> the machines individual public IP address - which provides the required
> server affinity. My assumption was that there *may* be a similar
mechanism
> in the remoting infrastructure to supply process affinity so that
subsequent
> request for the same marshaled URI are routed to the same process (instead
> of following the round robin distribution).
>
> At this point, I have four machines that work, and two that do not. I am
> looking for some empirical evidence that can explain the discrepancy. Am
I
> just lucky in the case of the four? I bet not.
>
> Dolph
>
> "Ken Kolda" <ken.kolda@elliemae-nospamplease.com> wrote in message
> news:OTHPCwkoEHA.3900@TK2MSFTNGP10.phx.gbl...
> > If you're using CAOs from within an IIS-based remoting app then you
> > shouldn't use web gardens. When you use a web garden you are instructing
> > IIS
> > to spin up several distinct processes to handle your requests. Incoming
> > requests are then sent to these processes in a round robin fashion. Your
> > CAO
> > will live in whatever process it was first instantiated in. If
subsequent
> > requests come in for your CAO and those requests are sent to the wrong
> > process, the CAO can't be found so you get the "Requested service not
> > found"
> > error.
> >
> > Ken
> >
> >
> > <SolDel@mercer.com> wrote in message
> > news:uRTS$MkoEHA.2588@TK2MSFTNGP12.phx.gbl...
> >> I have come across an issue when using CAOs and enabling the Web garden
> >> on
> >> the process model. If gardening is disabled, eveything works fine. If
> >> it
> >> is enabled, the remote object is created and appears to marshal just
> >> fine,
> >> however, any calls on the proxy result in the standard error,
> >>
> >> System.Runtime.Remoting.RemotingException: Requested Service not
> > found.
> >>
> >> First, are CAOs supported under the Web garden process model? Second,
if
> >> supported, are there any special configurations that are required? Or
> >> any
> >> known issues?
> >>
> >> I get the same results on both of the following configurations:
> >> Windows 2000 w/ .NET 1.1
> >> Windows XP w/ .NET 1.1 SP1
> >>
> >> Thanks,
> >> Dolph Priest
> >>
> >>
> >
> >
>
>