Thanks. I willl try that.
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun
2008 15:32:29 -0400> Subject: RE: Singleton in Tomcat 6.0 not working> > I
think the Tomcat support in Eclipse WTP is pretty reasonable, but it isn't
perfect. For ex
MAIL PROTECTED]
> Sent: Thursday, June 05, 2008 2:24 PM
> To: Tomcat Users List
> Subject: RE: Singleton in Tomcat 6.0 not working
>
>
> By the way, I was using the Eclipse 3.3, it integrated the Tomcat
> development tool. It was the Eclipse add that line to the server.xml.
> May
:03 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
From: ktou Ho [mailto:[EMAIL PROTECTED]> > Subject: RE: Singleton in Tomcat 6.0
not working> >> > Did you mean I should just remove this element> >
from the server.xml?> > You should never have put
It works. You are the best :>
Thanks a lot.
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun
2008 13:15:03 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
From: ktou Ho [mailto:[EMAIL PROTECTED]> > Subject: RE: Single
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> Did you mean I should just remove this element
> from the server.xml?
You should never have put it in there, so definitely remove it. If you need to
set the reloadable attribute
I changed the package name. (by only removed the compay name), as I am not
supposed to expose the source code.
Sorry about that.
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun
2008 13:08:14 -0500> Subject: RE: Singleton in Tomcat 6.0 not workin
Did you mean I should just remove this element from the server.xml?
Thanks
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun
2008 12:55:58 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
From: ktou Ho [mailto:[EMAIL PROT
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> -- Filter---
> public class ElwinFilter implements Filter
> -- web.xml -
>
> Elwin Filter
>
> com.elwin.IMeraFilter
>
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> Context from the server.xml
> source="org.eclipse.jst.jee.server:ROOT"/>
Right there is a problem: the path attribute should be "", not &quo
And yes, both have the call.
I double checked, both trace log are exact the same.
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun
2008 12:30:53 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
From: ktou Ho [mailto:[EMAIL PROT
ache.org> Date: Thu, 5 Jun
2008 12:30:53 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
From: ktou Ho [mailto:[EMAIL PROTECTED]> > Subject: RE: Singleton in Tomcat 6.0
not working> >> > I got twice of the following:> > ==> >
ilter
com.elwin.IMeraFilter
Elwin Filter
/*
---
> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun 2008
> 12:23:03 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > > From:
> ktou Ho [mailto:[EMAIL PROTECTED]> >
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> I got twice of the following:
> ==
> com.elwin.sql.RemoteDBConnections.(RemoteDBConnections.java:22)
Let's double-check here: both traces include the call f
rom: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Thu, 5 Jun
2008 12:11:24 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
From: ktou Ho [mailto:[EMAIL PROTECTED]> > Subject: RE: Singleton in Tomcat 6.0
not working> >> > Have you tried to p
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> I tried to change the web app to other name, it works fine
> now. (only one instance). Look like it is the "ROOT" cause
> all problem. Any one know why the ROOT is being
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> Have you tried to put in it the "ROOT"?
Yes, I've tried putting it in ROOT, and I get only a single instance, using
Tomcat 6.0.16 under JDK 1.6.0_06.
For more informati
I tried to change the web app to other name, it works fine now. (only one
instance). Look like it is the "ROOT" cause all problem. Any one know why the
ROOT is being called twice?
Thanks
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Subject: RE:
Singleto
) line: 39
DelegatingMethodAccessorImpl.invoke(Object, Object[]) line: 25
Method.invoke(Object, Object...) line: 597
Bootstrap.start() line: 288
Bootstrap.main(String[]) line: 413
--
> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Subject: Re: Singleton
> in Tomcat
I got two objects:
[EMAIL PROTECTED]
and
[EMAIL PROTECTED]
Thanks
Elwin
> Date: Thu, 5 Jun 2008 17:06:00 +0200> From: [EMAIL PROTECTED]> To:
> users@tomcat.apache.org> Subject: Re: Singleton in Tomcat 6.0 not working> >
> ktou Ho wrote:> > The problem I am
- Original Message -
From: "Mikolaj Rydzewski" <[EMAIL PROTECTED]>
To: "Tomcat Users List"
Sent: Thursday, June 05, 2008 5:06 PM
Subject: Re: Singleton in Tomcat 6.0 not working
ktou Ho wrote:
The problem I am facing is the Singleton is not working at all
ktou Ho wrote:
The problem I am facing is the Singleton is not working at all in the servlet. I tried to synchnozed the constructor or make it static. I still get two instances of the objects. How can I solve the problem?
Is anyone able to reproduce this?
public class RemoteDBConnections
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> Get some hints from this link
> http://books.google.com/books?id=bgMKmsXVbTAC&pg=PA304&vq=sing
> leton&dq=tomcat+6+singleton+not+working&source=gbs_search_s&si
>
Hello,
Is there any particular reason you can't just use ServletContext
Attribute instead of a static singleton?
Greetings, Lilianne E. Blaze
ktou Ho wrote:
Hi,
I am using Tomcat 6.0.16 with JDK 1.6. I created a web application and deployed it as ROOT. (I removed the default ROOT which comes
ird...
Still don't know why this happend...
Thanks
Elwin
> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Subject: Re: Singleton
> in Tomcat 6.0 not working> Date: Thu, 5 Jun 2008 04:44:54 +0200> > > -
> Original Message - > From: "Cal
Not it doesn't. It is a test class only contains the constructor and the
getInstance() method.
Thanks
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Wed, 4 Jun
2008 19:38:09 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > >
Fr
- Original Message -
From: "Caldarale, Charles R" <[EMAIL PROTECTED]>
To: "Tomcat Users List"
Sent: Thursday, June 05, 2008 4:18 AM
Subject: RE: Singleton in Tomcat 6.0 not working
From: Johnny Kewl [mailto:[EMAIL PROTECTED]
Subject: Re: Singleton in Tom
> From: Johnny Kewl [mailto:[EMAIL PROTECTED]
> Subject: Re: Singleton in Tomcat 6.0 not working
>
> Doing
> RemoteDBConnections obj = new RemoteDBConnections().getInstance();
> would make 2 counters
Except the constructor is private, so the above can't be done outside of t
- Original Message -
From: "ktou Ho" <[EMAIL PROTECTED]>
To:
Sent: Thursday, June 05, 2008 12:14 AM
Subject: Singleton in Tomcat 6.0 not working
Hi,
I am using Tomcat 6.0.16 with JDK 1.6. I created a web application and
deployed it as ROOT. (I removed the default ROOT which comes w
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> I print out the counter in the constructor. ( I also using a
> debugger check, my filter got call twice also).
Do you have any subclasses of the class with the singleton? If
> So you're seeing two print lines from the constructor, the first with a value
> of 0, the second with a value of 1? Is that correct?
Yes.
Elwin> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Wed, 4 Jun
2008 18:33:33 -0500> Subject: RE: Singleton in
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> I print out the counter in the constructor. ( I also using a
> debugger check, my filter got call twice also).
So you're seeing two print lines from the constructor, the first wit
ut the in the server.xml under
> TOMCAT/conf ?! I only have one, and it is
Thanks
Elwin
> From: [EMAIL PROTECTED]> To: users@tomcat.apache.org> Date: Wed, 4 Jun 2008
> 18:21:12 -0500> Subject: RE: Singleton in Tomcat 6.0 not working> > > From:
> ktou Ho [mailto
> From: ktou Ho [mailto:[EMAIL PROTECTED]
> Subject: RE: Singleton in Tomcat 6.0 not working
>
> I deploy the web app as ROOT.war to TOMCAT/webapps, (I
> removed the old ROOT first for sure). And I am pretty sure, I
> didn't deploy twice.
How do you know you're
; To:
> users@tomcat.apache.org> Subject: Re: Singleton in Tomcat 6.0 not working> >
> > ktou Ho wrote:> > Hi,> > I am using Tomcat 6.0.16 with JDK 1.6. I created a
> web application and deployed it as ROOT.> How did you deploy you app as ROOT?
>
ktou Ho wrote:
Hi,
I am using Tomcat 6.0.16 with JDK 1.6. I created a web application and deployed
it as ROOT.
How did you deploy you app as ROOT? It sounds like your app is deploying twice.
Mark
-
To start a new topic, e-m
The problem is where someone stated earlier in the load of
pam.conf. So different question:
How does one either modify web.xml or read a config file from within
the WEB-INF directory?
Thanks
Thomas
On Apr 12, 2007, at 7:45 PM, Thomas Polliard wrote:
Ok, so if the constructor is empty it
Ok, so if the constructor is empty it works fine, but as soon as you
put something in the constructor it fails.
Code:
package net.digitalassembly.auth;
import java.util.ArrayList;
import java.util.List;
import java.util.Properties;
import java.io.FileInputStream;
import java.io.IOException;
im
It looks like the problem is in this snippet of code:
On 4/11/07, Thomas Polliard <[EMAIL PROTECTED]> wrote:
Check if you placed pam.conf under /WEB-INF/classes/ --- I think
that's where Properties files are loaded from.
private String pamConfigFile = "pam.conf"; // Static file for all
I tried a smaller version of your code since I don't have the
dependent Classes as follows:
\MyProject\WEB-INF\classes\net\digitalassembly\auth\Pam.class
--
Calendar example worked (with page import java.util.Calendar) :)
This is the Pam.java class the class compiles to
WEB-INF/classes/net/digitalassembly/auth/Pam.class
package net.digitalassembly.auth;
import java.util.ArrayList;
import java.util.List;
import java.util.Properties;
import java.io.F
There's no trick to getting it to load.
There must be something wrong in the class, like incorrect package
name or incorrect package directory structure etc.
Try this small test,
<%
Calendar calendar = Calendar.getInstance();
%>
<%=calendar.getFirstDayOfWeek()%>
In the Pam class check if the p
41 matches
Mail list logo