Hi all, i have a COM+ component that works great from ASP.NET but in
ASP the objects are not released in Windows 2003, the same code runs
ok on my testing machine (Windows XP), I'm using the framework version
1.1.4322.573, every time i create an object the activated column in
the component services snap in adds one, but it never release it, here
is the code of my component.
[Guid("D22B554F-FE25-45af-B80C-80ACD8CE3DB6")]
[ClassInterface(ClassInterfaceType.None)]
[ProgId("CNBV_SAIT_AUTENTICA.ValidateUserServiced")]
[ObjectPooling(MinPoolSize = 5,MaxPoolSize = 50)]
[JustInTimeActivation(true)]
[ComVisible(true)]
[EventTrackingEnabled(true)]
public class ValidateUserServiced: ServicedComponent,IValidateUser{
protected override bool CanBePooled() {
return(true);
}
[SecurityPermission(SecurityAction.Demand, ControlPrincipal=true,
UnmanagedCode=true)]
[AutoComplete(true)]
public bool IsValidD(string userId, string password,string domain){
if(General.IsEmpty(userId)){
throw new
ArgumentNullException("userId",General.stringManag er.GetString(
"userIdArgumentNullException",
CultureInfo.CurrentUICulture));
}
if(General.IsEmpty(password)){
throw new
ArgumentNullException("password",General.stringMan ager.GetString(
"passwordArgumentNullException",
CultureInfo.CurrentUICulture));
}
if(General.IsEmpty(domain)){
throw new
ArgumentNullException("domain",General.stringManag er.GetString(
"domainArgumentNullException", CultureInfo.CurrentUICulture));
}
IntPtr token= IntPtr.Zero;
try{
token= IntPtr.Zero;
if(!NativeMethods.LogOnUser(userId, General.GetDomain(domain),
password,
General.LOGON32_LOGON_INTERACTIVE,
General.LOGON32_PROVIDER_DEFAULT, ref token)){
return(false);
}
return(true);
}
finally{
if(!token.Equals(IntPtr.Zero)){
NativeMethods.CloseHandle(token);
}
}
}
}
Here is the code i use to call the component:
Public Function ValidaUsuario(usuario,password)
Dim ObjValida
on error resume next
Set
objValida=Server.CreateObject("CNBV_SAIT_AUTENTICA .ValidateUserServiced")
ValidaUsuario=objValida.IsValidDG(usuario, password,
Application("Dominio"),Application("Grupo"))
if Err.Number <0 then
ValidaUsuario = -3
Err.Clear
end if
set objValida=nothing
End Function
As you can see, I use JITA, autocomplete, on my machine this code runs
ok, but in windows 2003 the activated objects get to 50 and never go
down (application debugging is disabled in IIS), thanks in advanced.
Juan Zamudio 2 1834
Juan,
Not only is your post unrelated to the C# language, it's not even related to
ASP.NET - its about classic ASP. There is a newsgroup for that, but it's not
this one.
good luck!
Peter
--
Recursion: see Recursion
site: http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
bogMetaFinder: http://www.blogmetafinder.com
"jmzl666" wrote:
Hi all, i have a COM+ component that works great from ASP.NET but in
ASP the objects are not released in Windows 2003, the same code runs
ok on my testing machine (Windows XP), I'm using the framework version
1.1.4322.573, every time i create an object the activated column in
the component services snap in adds one, but it never release it, here
is the code of my component.
[Guid("D22B554F-FE25-45af-B80C-80ACD8CE3DB6")]
[ClassInterface(ClassInterfaceType.None)]
[ProgId("CNBV_SAIT_AUTENTICA.ValidateUserServiced")]
[ObjectPooling(MinPoolSize = 5,MaxPoolSize = 50)]
[JustInTimeActivation(true)]
[ComVisible(true)]
[EventTrackingEnabled(true)]
public class ValidateUserServiced: ServicedComponent,IValidateUser{
protected override bool CanBePooled() {
return(true);
}
[SecurityPermission(SecurityAction.Demand, ControlPrincipal=true,
UnmanagedCode=true)]
[AutoComplete(true)]
public bool IsValidD(string userId, string password,string domain){
if(General.IsEmpty(userId)){
throw new
ArgumentNullException("userId",General.stringManag er.GetString(
"userIdArgumentNullException",
CultureInfo.CurrentUICulture));
}
if(General.IsEmpty(password)){
throw new
ArgumentNullException("password",General.stringMan ager.GetString(
"passwordArgumentNullException",
CultureInfo.CurrentUICulture));
}
if(General.IsEmpty(domain)){
throw new
ArgumentNullException("domain",General.stringManag er.GetString(
"domainArgumentNullException", CultureInfo.CurrentUICulture));
}
IntPtr token= IntPtr.Zero;
try{
token= IntPtr.Zero;
if(!NativeMethods.LogOnUser(userId, General.GetDomain(domain),
password,
General.LOGON32_LOGON_INTERACTIVE,
General.LOGON32_PROVIDER_DEFAULT, ref token)){
return(false);
}
return(true);
}
finally{
if(!token.Equals(IntPtr.Zero)){
NativeMethods.CloseHandle(token);
}
}
}
}
Here is the code i use to call the component:
Public Function ValidaUsuario(usuario,password)
Dim ObjValida
on error resume next
Set
objValida=Server.CreateObject("CNBV_SAIT_AUTENTICA .ValidateUserServiced")
ValidaUsuario=objValida.IsValidDG(usuario, password,
Application("Dominio"),Application("Grupo"))
if Err.Number <0 then
ValidaUsuario = -3
Err.Clear
end if
set objValida=nothing
End Function
As you can see, I use JITA, autocomplete, on my machine this code runs
ok, but in windows 2003 the activated objects get to 50 and never go
down (application debugging is disabled in IIS), thanks in advanced.
Juan Zamudio
Peter Bromberg [C# MVP] wrote:
Juan,
Not only is your post unrelated to the C# language, it's not even related to
ASP.NET - its about classic ASP. There is a newsgroup for that, but it's not
this one.
good luck!
Peter
I thought because of the component being developed in C# maybe i could
get help here, what i was thinking, asking a question in a forum of C#
about a component developed in C#, silly me.
Juan Zamudio This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Santa |
last post by:
I am using Fritz Onion's "Asynchronous Pages" approach as mentioned in
the article http://msdn.microsoft.com/msdnmag/issues/03/06/Threading/default.aspx
to increase the performance of my ASPX...
|
by: Ken |
last post by:
Timeout expired. The timeout period elapsed prior to obtaining a connection
from the pool. This may have occurred because all pooled connections were in
use and max pool size was reached.
This...
|
by: M.Ob |
last post by:
Hello...
I am having issues with my asp.net apps not releasing memory. The
memory usage for the process w3p.exe continues to grow to it's
allowable limit and does not drop until the app pool is...
|
by: ExclusiveResorts |
last post by:
Can the CallContext be used reliably for storing request specific data?
We are developing an application library that uses the CallContext to keep
an IdentityMap (hashtable of business objects...
|
by: pjdouillard |
last post by:
Hello all,
Here is the context of my problem:
We have an ASP.NET 1.1 application that has its own application pool
setup and that runs under the identity of a NT Domain service account
(this...
|
by: DraguVaso |
last post by:
Hi,
I had an error concerning the connection-pool: "Timeout expired. The
timeout period elapsed prior to obtaining a connection from the pool. This
may have occurred because all pooled...
|
by: JoeSep |
last post by:
Hi!
Is it correct/safe to define a connection pool in the string
"sqlConnectionString" of the "sessionState" section of Web.config?
- The application is developed using AspNet 1.1 in a Windows...
|
by: one |
last post by:
Hi,
Was wondering if you could help me out with regards to a server that
I'm trying to troubleshoot...
Basically we have a windows 2003 load-balanced server that has got
sharepoint and mcms...
|
by: Vlad Hrybok |
last post by:
Hi all,
I recently installed 64 bit version of Vista hoping to make it my primary
development setup. I was able to do work with IIS7 and ASP.NET 2.0/Visua
Studio 2005 combo, but hit a roadblock...
|
by: Juan Zamudio |
last post by:
Hi all, i have a COM+ component that works great from ASP.NET but in
ASP the objects are not released in Windows 2003, the same code runs
ok on my testing machine (Windows XP), I'm using the...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
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,...
|
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...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
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...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
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...
| |