Re: java.lang.ClassCircularityError
Caldarale, Charles R wrote: According to the bug report, this is only fixed in Mustang (6.0), not 5.0 (aka 1.5). Ooh, my bad (misread of the fixed release..). Thanks.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: java.lang.ClassCircularityError
Jagadeesha T wrote: I am using Tomcat 5.0 with JBoss 3.2.6. In a very rare cases I got the error as java.lang.ClassCircularityError(myclass). Does anybody know wahy this error is coming. There seems to be a well-known Java bug (1.3.x and 1.4.x, fixed in 1.5) that affects JBoss 3.x: http://bugs.sun.com/bugdatabase/view_bug.do;:YfiG?bug_id=4699981 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running Tomcat as Non-Root under Linux listen for port 80
NoKideen wrote: is there anybody know how to do this ? Running Tomcat as Non-Root under Linux listen for port 80 Google is your friend: http://www.google.com/search?q=linux+port+80+non-root - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tomcat con pooling to Oracle RAC
Frank W. Zammetti wrote: Yep, I had a coworker suggest using the OCI driver as well... And you have to use the right JDBC driver as well. At least up to the 9.* timeframe, Oracle used to release two JDBC drivers: one was a thin-only driver with its "JDBC" distribution, and one was the full "thick" driver, both of which were approximately the same size, and both called ojdbc14.jar. (Just to confuse things). But the thin-only driver could not use the OCI library. I'm not sure if the situation has changed in 10.*. I do know that the JDBC driver in the Oracle InstantClient distribution is a full thick-and-thin driver, and comes bundled with the OCI libraries to boot.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: load-on-startup servlet needs access
Darren Govoni wrote: How can I have my servlet loaded on startup, but after the web server is up and running? Not possible? Well, you can always start a thread that does this initialization, and return. Then, when the full Tomcat initialization is complete, your thread will run to completion (assuming it's doing a GET or POST from that instance itself..) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Question for Tomcat Developers - How to Plug In Encryption for JDBC passwords
George Sexton wrote: If you really want to do this, then you will need to have your application startup have a method that permits an operator to enter in the password for the JDBC information at startup. Whatever - the key is to be able to insert an application-defined processing step between the reading of the DBCP properties, and sending the username and password to the JDBC driver. This additional step could be: * nothing (cleartext username and password) * trivial decryption of a trivially encrypted string (not cryptographically safe, but Dilbert's-boss-safe). * True encrypted strings that require a password-protected opening of a private-key file to decrypt. * True password-protected external storage of encrypted data. Whatever. The key is to be able to do a two-way processing of the username, password, and other sensitive data (even the JDBC url). A tool to "encode" the data into the JDBC properties, and a code callback to "decode" the properties when reading them from the file. How easy is this to do? Where would such a hook go? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Benefits of running Tomcat as a daemon with JSVC
Mladen Turk wrote: Behrang Saeedzadeh wrote: What are the benefits of running an application like Tomcat with as a daemon (with JSVC) vs. running it like a normal application? In one sentence: Running as non-root on port < 1024 In another sentence, starting up the service automatically on system startup. That's the big one. We actually run Tomcat as a non-root user, but we need to start it up automatically on system startup. On Windows, too - the same rationale. Making it start up as a service means you don't have to log in and start it up manually each time. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Someone is using Tomcat for spreading spam?
Susan Hoddinott wrote: Everytime I resubscribe to the user list I am bombarded with Spam. So use an NNTP interface to the list, like I'm doing (on news.gmane.org). It's sometimes a little less convenient to use, but the benefits are that I don't have to flood my mailbox with the messages, and I don't have to deal with spam. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Hyperthreading and Java (was RE: Tale of two servers)
Peter Crowther wrote: >>From: Graham Reeds [mailto:[EMAIL PROTECTED] >>Also disable HyperThreading in the BIOS on the new Dell. HT >>and Java is not a happy combination. Interesting... do you have any recommended reading on that, Graham? Love these urban-legend types of warnings ("don't flash your headlights..."). I think Graham is referring to a bug in the 1.4.2 line of JVMs where under certain circumstances, the HotSpot compiler trips over the garbage collector, and causes mysterious VM aborts. I believe there have been fixes in 1.4.2_06 and 1.4.2_07, and also in 1.5.0_01. It's triggered more easily in an HT or MP machine, but the important thing is that it can also be tripped on non-HT, single-processor machines (though much more rarely). - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Capitalizing names OT
David Short wrote: Does anyone know if there is an equivalent to the Oracle Initcap() function? I am trying to write a database independent name capitalization routine. In what language? Java? public static String initCap(String s) { return (s == null || s.length() == 0) ? s : s.substring(0,1).toUpperCase() + s.substring(1); } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [OT]File size with DOS batch commands
Srinivas Rao Ch wrote: Can somebody help me in finding the size of a file (and last modified date also)with DOS batch commands only? Try the site http://www.jsiinc.com/reghack.htm. Among the thousands of FAQs there are common script requests like this, with canned scripts to do the work which you can adapt to your needs. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: How to access s from Servlet.init()?
QM wrote: Which init() overload do you use? init() init( ServletConfig ) Using the latter, you should be able to call: ServletConfig#getServletContext() --> getInitParameter() Hah. Thank you! Yes, I mean the latter version. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
How to access s from Servlet.init()?
I'd like to configure a set of web-app-level parameters for use by both Java-based Servlets, and JSP pages. I thought of setting these up as s at the level in web.xml. For JSPs, all is cool: <%= application.getInitParameter("foo") %> returns these parameters. For Servlets, how do I get at them from the init() method? (I need them there!). I find that calling config.getInitParameter() doesn't return these (where "config" is the parameter to init() - it only returns the actual s configured within the ). Also, this.getServletConfig() is null, and this.getServletContext() throws an NPE from within javax.servlet.GenericServlet. (All this with Tomcat 5.0.27). How do I get at a from within Servlet.init()? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Definitive os.name list (was Re: [OT] Request an app test (free beer!))
Frank W. Zammetti wrote: I'm working on something for which I need to know what the os.name property on various OS's is. FAQ. See http://www.tolstoy.com/samizdat/sysprops.html. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: deleteOnExit() doesn't work in Tomcat on temp files
Noel J. Bergman wrote: Instead, use the PhantomReference-based code that I contributed to Jakarta Commons. The main reason why people (misguidedly) use deleteOnExit() is to be able to generate temporary files that you can return URLs for (e.g. you generate a .PDF report, and generate an HTTP redirect to /foobar.pdf). And of course, have those files be cleaned up later. You want to wait for a little while before deleting the file (5 or 10 minutes, or some other configurable timeout), to allow the user to do things like reload the URL. Also, some browsers (Mozilla in particular) reload the URL when you Print a page. I'm not sure a reference-based cleanup would be appropriate, unless it's possible to somehow force a reference to be kept for such a period, and then magically cleaned up. This is why I suggested an explicit cleanup thread where you could register the files you have generated, and have it clean them up after a few minutes. I know it's bad to start up threads like this, but in the absence of anything better (that I know of), ... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: deleteOnExit() doesn't work in Tomcat on temp files
[EMAIL PROTECTED] wrote: I am using Tomcat 5.5 on WindowsXP. Tomcat is installed as a "service", Somehow when Tomcat is installed as a Windows service, the shutdown doesn't go through the orderly steps (i.e. servlet destroy()s aren't called, and I suspect the process is just *killed* instead of being made to exit normally). You may want to have a separate mechanism to delete these temp files instead of waiting for the tomcat exit, anyway. If your Tomcat process lives a long time, you may run out of temp file space - you should have a separate thread or something, and queue up your files to be deleted by that thread, based on some aging criteria.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [dbcp] Call Oracle stored procedure via DBCP?
Sergey Karpov wrote: During a call of stored procedure through DBCP there is a mistake of reduction of type: java.lang.ClassCastException That's because you're assuming that dbcp returns you a naked vendor JDBC Connection object. It doesn't - it returns you a pooled connection wrapper with forwarding methods. Ditto for CallableStatements. If you really needed to get the underlying object, you'd have to look at the JavaDoc for DBCP. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: redirect catalina.out
Shapira, Yoav wrote: swallowOutput is not a Context attribute, it's a Logger attribute: change your context.xml to fix that. Really? That's not what the doc says (or the source either). Just tested on 5.0.2x. (At least, I defined a in my , and standard output went to the log file configured for the webapps). - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Content-disposition for file downlaod with Mozilla/Firefox
David Wall wrote: Content-Disposition: attachment;filename="Some Agreement 2004-11-15.doc" This is the correct fix: format the header as per RFC 2231. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: JAVA_OPTS
Mufaddal Khumri wrote: As far as what the -server option will do for you , that depends on your VM vendor. The Sun JRE distributions typically don't include a server VM, so "-server" will give an error. You'll have to download the JDK, and run the JRE that is embedded within it (.../j2sdk1.4/jre). - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Anyone knows how to deal with mail session -security error for TC5.5.4
David Lee wrote: 2. catalina.policy: grant codeBase "file:${catalina.home}/webapps/javaxml2/WEB-INF/classes/UpdateItemServle t.class" { Shouldn't you be giving those permissions (except the Oracle one :-) to mail.jar, rather than your servlet class? That's what is actually making the reference, isn't it? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Running tomcat 5.0 as a service in Windows OS
Pramod Jain wrote: a) with tomcat5w.exe, I go to startup tab and enter: start -config "C:\abc\my_server.xml" b) In Windows Services editor I go to Apache-Tomcat -> Properties -> Start Parameters and enter: start -config "C:\abc\my_server.xml" Don't use double-quotes - those will be passed literally to Tomcat, and it will try to open a file name with an embedded double-quote. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Forum instead of mailist!!
Andoni wrote: That's excellent. If I unsubscribe can I still read these? Can I reply? Yes, you can reply. The first time you try to reply, gmane.org will send you an autoreply. You have to reply to the auto-reply to authenticate your mail address, and then you're up and running. That's how I'm posting now.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Weird Red Hat Enterprise Startup
Shapira, Yoav wrote: Any JVM switch to make an internal JVM crash "disappear" is cruising for a bruising. Fully understood. Most likely, it's missing OS-level patches for your system. True, except that for the Linux case, we are running on one of the supported OSes (RH EL 3.0WS, stock), and there's no mention of any required patches for Linux. Still get the crash. In our case, it was readily triggered by a particularly large output from a JSP - a table with ~1500 rows, which was a pathological case - and we have workarounds for this particular symptom. But there have been other unexplained crashes, too, and we have found open bugs in the Sun JDC bug database referring to crashes like this on Linux.. So yes, once again: -server is a band-aid (just one of many), it's not guaranteed to fix anything at all (could even make things worse) - it just shifts the problem around under the blanket. It's just one thing to try, and *if it "works" in your case*, use it as a temporary workaround. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Weird Red Hat Enterprise Startup
Mike Cherichetti (Renegade Internet) wrote: Another exception has been detected while we were handling last error. Dumping information about last error: ERROR REPORT FILE = (N/A) PC= 0x This is the Java VM aborting. You'll probably find core.* files littered in the Tomcat directory from java. I've been running into this same problem with Java 1.4.2_0x (including _05) on Red Hat EL 3.0. One (not guaranteed or foolproof) workaround is to run java with the "-server" option (you'll have to pass it in via the JAVA_OPTS env variable or something). This made the crash go away in our setup. You can also play with the heap params and see if that helps. The crash is in some GC processing that kicks in at the wrong moment.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using XInclude in tomcat's config files
Pawson, David wrote: Does your parser support xml:base? "My parser"? We're talking about the xerces parser embedded in Tomcat, reading the configuration files for Tomcat and its webapps (not a parser used by an application hosted by Tomcat). If there's any way to control the instantiation or behavior of that parser, I'd like some pointers. Anyway, thanks for the help and suggestions so far. Looks like a bit more research is needed, alas.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using XInclude in tomcat's config files
Pawson, David wrote: Try an entity instead of xinclude? Not many parsers are good for xinclude as yet (a mainly uninformed statement). Entity resolution is easier if the parser is setup correctly. Oh, that's what we are doing now, but entity resolution doesn't have a concept of relative paths. I.e. if you have a file called "/path/to/foo.xml", which does an entity include of "file:../somewhere/params.dtd", then the path is not interpreted in relation to its including file (i.e. as "/path/to/../somewhere/params.dtd"), but instead in relation to "$cwd" (i.e. it's literally opened as "../somewhere/params.dtd"). This makes it nearly useless, as you are *forced* to "cd" to "/path/to" before you can process the "foo.xml" file. On the other hand, if you use absolute path names, that makes it difficult to move the files around. All in all, entity includes are inflexible and a terrific pain to work with. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using XInclude in tomcat's config files
Shankar Unni wrote: Haven't tried it, but have you set the: org.xml.sax.parser=org.apache.xerces.parsers.XIncludeParserConfiguration Ah. No. Thanks for that clue. Let me go back at it.. Alas, that didn't help. I tried setting both org.xml.sax.parser and org.apache.xerces.xni.parser.XMLParserConfiguration (the latter one being the one described in the Xerces XInclude FAQ at http://xml.apache.org/xerces2-j/faq-xinclude.html) on the java command line to "org.apache.xerces.parsers.XIncludeParserConfiguration", but neither seems to have had the least effect. The http://www.w3.org/2003/XInclude"/> is completely ignored in my server.xml, and it is as if this directive weren't even present. (The file contains a root element for insertion into the that I've declared in server.xml). Anything else I can try? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using XInclude in tomcat's config files
Robert Koberg wrote: Haven't tried it, but have you set the: org.xml.sax.parser=org.apache.xerces.parsers.XIncludeParserConfiguration Ah. No. Thanks for that clue. Let me go back at it.. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Using XInclude in tomcat's config files
Shankar Unni wrote: Is it possible to configure Tomcat to be able to use XInclude to include fragments of XML into Tomcat's own configuration files (server.xml, the various webapp web.xml's, etc.)? Bump? No one's tried this yet? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Strings in VARCHAR or BLOB
[EMAIL PROTECTED] wrote: The maximum string size for varchar2 is 8000K. I suggest you use LOB (CLOB or NCLOB) datatypes. This is all oracle-specific. Other DBs have different limits. MySQL has a 255-char limit for Varchar (not varchar"2", which is also Oracle-specific, as is "NCLOB"). Bottom line: don't try to store web pages as varchars. Keep using CLOBs. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Using XInclude in tomcat's config files
Is it possible to configure Tomcat to be able to use XInclude to include fragments of XML into Tomcat's own configuration files (server.xml, the various webapp web.xml's, etc.)? If so, can anyone point me at any HOWTOs or helpful messages? I've tried searching the archives, but everything I see is about deploying applications that need to use xinclude.. Thanks! - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]