comp.lang.java.programmer http://groups-beta.google.com/group/comp.lang.java.programmer [EMAIL PROTECTED]
Today's topics: * jsp web application development - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/f2b936f5b357d080 * "static" prefix - to parallel "this" prefix - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/f5dde10882ac2157 * Can Java Programmer Learn C++ Quickly? - 2 messages, 2 authors http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/7c7a28aa864e41ec * Sockets - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/edecab678cd31cd6 * Obfuscation of 3rd art jars and distribution legal issues - 2 messages, 2 authors http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/db0dc7b834250179 * A little optimization question: Local var allocation - 5 messages, 3 authors http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/a6b24661ed590053 * URL and FileNotFoundException - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/c1d75866a1a811a6 * Threads and modal dialog behaviour question - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/7a5f146a46cb92ad * ActiveX Container in Java - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/188085b06e48f3d1 * Java2D Direct3D usage disabled by J2D_D3D env - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/1436e957128d44c3 * can't find class file - 2 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/41f61eb9d8c24f1c * Stubs and Skeleton Eclipse - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/28950846f584e84b * Thread and Listener - 2 messages, 2 authors http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/79e41b9865d2cf15 * Struts and Timeout in Validator - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/d651e24002f4ba14 * JSF version of JSTL forEach? - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/12c3510dbb3c55d4 * [OT] Using hobby source code in your job ? - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/a60dfe865a7807c4 * How to access session beans from within a message bean? - 1 messages, 1 author http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/8d9a452f382c487 ============================================================================== TOPIC: jsp web application development http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/f2b936f5b357d080 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 9:33 am From: Sudsy claydn wrote: <snip> > I would like to take it a bit further and remove this from the jsp page. So > I have a Connect function, a Disconnect function and a RunQuery function, > which I can call from the jsp page. > > But what is the best way to do this? Would it be in a Bean ? Does anyone > have an sample code I could look at which shows simply how to connect to the > database this way and run a query against it ? You use tags. Fortunately, a lot of the work has already been done. Take a look at the sql tags, part of Sun's JSTL package: <http://java.sun.com/products/jsp/jstl/1.1/docs/tlddocs/index.html> -- Java/J2EE/JSP/Struts/Tiles/C/UNIX consulting and remote development. ============================================================================== TOPIC: "static" prefix - to parallel "this" prefix http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/f5dde10882ac2157 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 2:28 pm From: Tim Tyler Tim Tyler <[EMAIL PROTECTED]> wrote or quoted: > Chris Uppal <[EMAIL PROTECTED]> wrote or quoted: > > Tim Tyler wrote: > > > Suggested syntax would be "static.var" and "static.method()" - > > > instead of today's "ClassName.var" and "ClassName.method()". > > [...] > > > Has this been suggested before? > > > > > > Does it make sense to you? > > > > > > Are there any other proposals to deal with the same issue? > > > > Yes, yes, and yes, respectively ;-) > > > > Alex Hunsley posted a similar suggestion (maybe identical) a few months ago; > > see this thread (sorry about the URL, but it seems that Google is in the > > process of switching how the Google groups work): > > > > http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/4ceda7465055571c [...] > > (in case the URL stops working, the thread's title is "Good idea or full it > > it?") > > > > Personally, I like the idea but think it would work still better with a > > different keyword such as 'thisClass', see my post in the above thread for > > details. > > The idea of eliminating constructor names is appealing. > > However, I'm not sure what syntax would be best for that. Something regular would be best - IMO. I think I favour a Smalltalk-style factory method: ClassName c = ClassName.new(); // construct... class ClassName { ClassName new() { ... } // constructor... } This is more regular than having dedicated constructor syntax - I would think. I doesn't deal with the class name, though - unless you allow: "static new()". Of course Java is far too frozen for this sort of thing as well. -- __________ |im |yler http://timtyler.org/ [EMAIL PROTECTED] Remove lock to reply. ============================================================================== TOPIC: Can Java Programmer Learn C++ Quickly? http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/7c7a28aa864e41ec ============================================================================== == 1 of 2 == Date: Tues, Dec 7 2004 9:36 am From: "John C. Bollinger" Chris Uppal wrote: > It's a lot of fun to program in C++, there are so /many/ > intellectual challenges. I just don't think its a particularly good choice > for > writing programs in... Now there's one for the quote file. :-) John Bollinger [EMAIL PROTECTED] == 2 of 2 == Date: Tues, Dec 7 2004 9:14 am From: Andy Hill "Rhino" <[EMAIL PROTECTED]> wrote: >I realize that this is not entirely a Java question but I am hoping that >some of the people reading this newsgroup are Java programmers who went on >to learn C++. > >I am giving some thought to applying for some jobs that want people with >Java and C++ experience. I have been writing Java for several years and am >fluent enough that I don't have to post questions here very often. I have no >real C++ experience and not much C experience for that matter. > >However, the core Java statements are "borrowed" from C and C++ has often >been called "C with classes". It seems to me that it shouldn't take very >long to get up to speed on C++ if I am already fluent with Java and have at >least some knowledge of C. Then again, I understand that Java and C++ use >classes a bit differently; for instance C++ allows multiple inheritance >while Java allows only single inheritance but allows for multiple interfaces >as compensation. I'm not sure how long it would take to get fluent with >multiple inheritance after several years with Java. > >I'd be very curious to know how long it took people here who were fluent in >Java to get fairly fluent in C++ if they started with approximately the same >skills I have today. > The basic languages are quite similar -- you shouldn't have any real trouble *reading* c++ code from the get-go. The multiple-inheritance thing isn't much of a bugaboo... it's not used all that much anyhow. The big problems are that (1) The libraries are very different between java and c++, and learning to "think" in terms of the STL takes time (2) The garbage collector in java lets you get sloppy with memory management...no such luck in c++ At a rough guess, it'd take you about 6 months, working with c++ every day, to become what I'd consider "fluent" in c++ (i.e., when confronted with a design problem, be able to sketch out the system design and bang out the code without having to consult the manual every fifteen minutes). If the job is mostly maintenance programming, then that's a horse of a different color -- you should be able to do useful work almost immediately (i.e., you can figure out c++ while you're figuring out the existing system and the existing set of development tools). ============================================================================== TOPIC: Sockets http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/edecab678cd31cd6 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 3:35 pm From: Michael Borgwardt FunkyKarma wrote: >>>The content doesn't matter. >> >>Yes, it does. Otherwise, there is no communication. > > Idiotic response - arguing for arguing sake. Pot, meet Kettle. >>>On the >>>receiving end you just have to know what bytes were written onto the wire. >> >>And you DON'T KNOW that with a struct! Because it uses compiler- and platform >>dependant padding, endianness and data type sizes. > > You can know all the stuff that you are referring to above. Sure, but what are you going to *do* with that knowledge? How do you get it to the receiving end? Are you seriously proposing a communication protocol that is based on first negotiating endianness and padding of structs in the following communication? You definitely can't use structs in *that* process - so why use them at all? > I'm not saying > it's a good idea to do something like writeToSocket (&someStruct, sizeof > (someStruct)) It's a *very bad* idea. > ... I'm just saying it's possible. You were saying that it is not a problem, and it is. ============================================================================== TOPIC: Obfuscation of 3rd art jars and distribution legal issues http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/db0dc7b834250179 ============================================================================== == 1 of 2 == Date: Tues, Dec 7 2004 9:44 am From: "John C. Bollinger" [EMAIL PROTECTED] wrote: > I am thinking of using a 3rd party jar for a personal project - I am > curious, given that I will pay for this library I will need to > distribute it with my aplication for my app to run. > Whats to stop someone downloading my application and just stealing the > 3rd party jar? Nothing. > Also, I dont think the class files in the 3rd party jar are obfuscated, > what are the legal implications of obfuscating someone elses commercial > jar? It depends on the license governing your use and distribution of it. > I am guessing its all going to be down to the individual license > agreements but are there any general guidelines or websites with info > on these legal matters? There probably are, but I can't point you to specific ones. Google is your friend. > I am particularly keen to know how one is expected to distribute an > application which includes a 3rd party jar the developer payed for! As above, it depends on the license. The "standard" license may not include any distribution rights at all, in which case users would have to obtain their own licenses. Or you might have rights to distribute it freely. You might be able to come to an agreement with the licensor of the 3rd-party jar to act as an agent for them to license their jar to your clients and distribute it. Their are boundless possibilities. The only sure answer is to read the license and discuss its terms with the licensor. It may be in your best interest to involve an attorney. I am not one. John Bollinger [EMAIL PROTECTED] == 2 of 2 == Date: Tues, Dec 7 2004 8:39 am From: Chris Smith <[EMAIL PROTECTED]> wrote: > I am thinking of using a 3rd party jar for a personal project - I am > curious, given that I will pay for this library I will need to > distribute it with my aplication for my app to run. > Whats to stop someone downloading my application and just stealing the > 3rd party jar? In the end, the answer is that you should do what the library author/vendor requires you to do. If there's text in the license requiring you to obfuscate the code before distributing it, then do so. Otherwise, it's not worth your effort to obfuscate a third-party library. Although you seem to consider obfuscation a key part of deployment of anything, most people don't share that extreme viewpoint. I can see why some library providers may not want you to do so. In my personal judgement (which is not an informed legal opinion, and encompasses more than legal requirements), your unprovoked obfuscation of someone else's code is more likely to cause problems than solve them. -- www.designacourse.com The Easiest Way To Train Anyone... Anywhere. Chris Smith - Lead Software Developer/Technical Trainer MindIQ Corporation ============================================================================== TOPIC: A little optimization question: Local var allocation http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/a6b24661ed590053 ============================================================================== == 1 of 5 == Date: Tues, Dec 7 2004 3:49 pm From: Chris Berg I often wonder: Does it make any difference in EXECUTION TIME which version I choose: #1: String st; while (true){ st=dis.readLine(); if (st==null) break; < do something else > } #2: while (true){ String st=dis.readLine(); if (st==null) break; < do something else > } It's obvious that st is valid outside the loop in #1. But does it get allocated on the stack for every iteration in #2, or just re-used? If not, I suppose #2 is preferred as far as limiting the scope, enabling gc, is an issue. Chris == 2 of 5 == Date: Tues, Dec 7 2004 4:03 pm From: Michael Borgwardt Chris Berg wrote: > I often wonder: Does it make any difference in EXECUTION TIME which > version I choose: see http://www.google.de/groups?threadm=1101305706.051713.46060%40z14g2000cwz.googlegroups.com == 3 of 5 == Date: Tues, Dec 7 2004 3:04 pm From: "Tim Ward" "Chris Berg" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I often wonder: Does it make any difference in EXECUTION TIME which > version I choose: I'm sure a few seconds with Google would have found some of the other 137 times this has been asked and answered here in the last few months ... -- Tim Ward Brett Ward Limited - www.brettward.co.uk == 4 of 5 == Date: Tues, Dec 7 2004 4:47 pm From: Chris Berg On Tue, 7 Dec 2004 15:04:08 -0000, "Tim Ward" <[EMAIL PROTECTED]> wrote: >I'm sure a few seconds with Google would have found some of the other 137 >times this has been asked and answered here in the last few months ... Maybe not. Googling returns a heap of different discussions about the subject, and not a very clear conclusion. So, I will try to re-state the question: Does a method create a stack frame for ALL local var's at the beginning, or does it increment/decrement a stack pointer along the way, thus re-using stack space? A simple question with a binary answer, I suppose. Or? Chris == 5 of 5 == Date: Tues, Dec 7 2004 4:55 pm From: Michael Borgwardt Chris Berg wrote: > Maybe not. Googling returns a heap of different discussions about the > subject, and not a very clear conclusion. That is hard to believe, since the issue is very clear. But admittedly, I don't think finding the right search terms for this is easy. > So, I will try to re-state the question: > > Does a method create a stack frame for ALL local var's at the > beginning, On the bytecode level (which is all that matters) the JVM is mandated by the specification to do it that way. http://java.sun.com/docs/books/vmspec/2nd-edition/html/Overview.doc.html#17257 > A simple question with a binary answer, I suppose. Or? Exactly. Which is why I find it hard to believe that there are discussions about it that don't reach a clear conclusion, at least not on a forum, such as this, where there are competent people. ============================================================================== TOPIC: URL and FileNotFoundException http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/c1d75866a1a811a6 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 9:47 am From: Sudsy Ryan Stewart wrote: <snip> > public void work() throws MalformedURLException, IOException { > URL url = new URL("http://localhost:" + port + "/blah.jsp"); > System.out.println("** Requesting " + url); HttpURLConnection conn = (HttpURLConnection) url.openConnection(); if( conn.getResponseCode() != HttpURLConnection.HTTP_OK ) { // process error return; } InputStream in = conn.getInputStream(); > int data; > while ((data = in.read()) != -1) { > System.out.print((char) data); > } > in.close(); > } <snip> -- Java/J2EE/JSP/Struts/Tiles/C/UNIX consulting and remote development. ============================================================================== TOPIC: Threads and modal dialog behaviour question http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/7a5f146a46cb92ad ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 8:08 pm From: Babu Kalakrishnan Aloys Oberthür wrote: > I have a question on modal dialogs in (non-event-dispatching)Threads. I > do set a flag in the actionPerformed() method of a modal dialog and the > object which displayed the dialog in the first place can question this > flag after "returning" from show(). I would have expected this to be not > timing dependant, but I see it is not which I do not understand > > > that's the dialog in essence: > > class ModalerDialog extends JDialog implements ActionListener { > boolean flagSuccessful = false; > ... > > public void actionPerformed(ActionEvent aE) { > String cmd = aEvt.getActionCommand(); > > if(cmd.equals("one")) { > flagSuccessful = true; > this.setVisible(false); > } > else if(cmd.equals("two")) { > flagSuccessful = false; > this.setVisible(false); > } > } > > public boolean isSuccessful() { > return flagSuccessful; > } > } > > > and that is the Thread launched within the actionPerformed()-method of a > menu ActionListener (see // comments) > > Thread t = new Thread() { > public void run() { > > ModalerDialog md = new ModalerDialog(owner, true); > md.show(); If "md" is really a modal dialog, I would expect this thread to stop right here, and continue on to the next line only after the dialog has been hidden / disposed off. That's how modal dialogs are expected to behave. > > boolean b = md.isSuccessful(); // now on "one" false > try { > Thread.sleep(250); > } > catch (InterruptedException e1) {} > b = = md.isSuccessful(); // and now on "one" true ???? > > if(md.isSuccessful()) > md.dispose(); > else { > md.dispose(); > owner.showStartupDialog(); > } > } > }; > t.start(); > Couldn't understand what your comments meant either. BK ============================================================================== TOPIC: ActiveX Container in Java http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/188085b06e48f3d1 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 3:00 pm From: Mark Preston Dan wrote: > > To be honest I dont know a lot about ActiveX, are you saying that > ActiveX is a windows only technology? Well - errr - yes. Strictly speaking, its a *Microsoft* only one, but it amounts to much the same thing. ============================================================================== TOPIC: Java2D Direct3D usage disabled by J2D_D3D env http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/1436e957128d44c3 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 10:07 am From: Sudsy Brij wrote: <snip> > Could you please tell me how to stop getting this message "Java2D Direct3D > usage disabled by J2D_D3D env" everytime on the console. I'm going to do even better! > I use JBuilderX for development and the OS is windows XP professional and > the jdk is jdk1.4.2. Turns out that this is a JBuilder issue. How did I determine that? I did what everyone should do when encountering a problem like this: I started at <http://groups.google.com>. Did you know that they took over the DejaNews database? That it contains most of the posts made to the Usenet groups over the past decade? You'll want to winnow the number of hits so use this query string: +J2D_D3D +JBuilder So do yourself a big favour and try to find your own answers in the future. It's highly likely that someone else has already run into the situation and posted. Hopefully you'll also find a solution, saving yourself time and effort. And no waiting for the lag time on Usenet! -- Java/J2EE/JSP/Struts/Tiles/C/UNIX consulting and remote development. ============================================================================== TOPIC: can't find class file http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/41f61eb9d8c24f1c ============================================================================== == 1 of 2 == Date: Tues, Dec 7 2004 7:09 am From: "zpetero" Ryan, How can I stop logging altogether? I only want to write what I specify to the log file. This line deletes the file if its already there when initialized. log4j.appender.dest1.Append=false What's the difference beteween, log4j.rootCategory=DEBUG, dest1 VS. log4j.rootLogger=DEBUG, dest1 ?? Peter Here's the porperties file, # debug, info, warn, error, fatal log4j.rootCategory=DEBUG, dest1 #log4j.rootLogger=DEBUG, dest1 log4j.appender.dest1=org.apache.log4j.FileAppender #log4j.appender.dest1.layout=org.apache.log4j.PatternLayout #log4j.logger.com.web=FATAL # Appender dest1 writes to the file "test" in user's home. log4j.appender.dest1.File=${CATALINA_HOME}/webapps/Epiphany/WEB-INF/classes/app/log # Truncate 'test' if it aleady exists. log4j.appender.dest1.Append=false Ryan Stewart wrote: > "zpetero" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > >I got that and have since set up and tested Log4j, > > > > The tricky part is getting it to output to the file I want. > > > > Would you by chance know to set it up to send logging info to a file? > [...] > > This code compiles and runs but I can't figure out where the output is > > going. This is the log4j.properties file, which is located in the same > > directory as the class file. > > > > log4j.rootCategory=DEBUG, dest1 > > log4j.appender.dest1=org.apache.log4j.FileAppender > > #log4j.appender.dest1.layout=org.apache.log4j.PatternLayout > > > > # Appender dest1 writes to the file "test" in user's home. > > log4j.appender.dest1.File=${CATALINA_HOME}/webapps/EP/WEB-INF/classes/app/log > > > > # Truncate 'test' if it aleady exists. > > log4j.appender.dest1.Append=false > > > If you haven't already, you can find log4j documentation at > http://logging.apache.org/log4j/docs/ > > As for the properties file, you don't often have to set them up, so it's > hard to remember without looking it up. One thing I do notice is the first > line should be "log4j.rootLogger=..." and not "rootCategory". Did someone do > a global find and replace? Those are very dangerous. The ".File" tells it > what file to write to, which should be in the specified directory within > your Tomcat installation directory (assuming it is expanded properly; I > don't think I've tried EL in here). Finally, I don't recognize that last > line with the ".Append". == 2 of 2 == Date: Tues, Dec 7 2004 7:10 am From: "zpetero" Ryan, How can I stop logging altogether? I only want to write what I specify to the log file. This line deletes the file if its already there when initialized. log4j.appender.dest1.Append=false What's the difference beteween, log4j.rootCategory=DEBUG, dest1 VS. log4j.rootLogger=DEBUG, dest1 ?? Peter Here's the porperties file, # debug, info, warn, error, fatal log4j.rootCategory=DEBUG, dest1 #log4j.rootLogger=DEBUG, dest1 log4j.appender.dest1=org.apache.log4j.FileAppender #log4j.appender.dest1.layout=org.apache.log4j.PatternLayout #log4j.logger.com.web=FATAL # Appender dest1 writes to the file "test" in user's home. log4j.appender.dest1.File=${CATALINA_HOME}/webapps/Epiphany/WEB-INF/classes/app/log # Truncate 'test' if it aleady exists. log4j.appender.dest1.Append=false Ryan Stewart wrote: > "zpetero" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > >I got that and have since set up and tested Log4j, > > > > The tricky part is getting it to output to the file I want. > > > > Would you by chance know to set it up to send logging info to a file? > [...] > > This code compiles and runs but I can't figure out where the output is > > going. This is the log4j.properties file, which is located in the same > > directory as the class file. > > > > log4j.rootCategory=DEBUG, dest1 > > log4j.appender.dest1=org.apache.log4j.FileAppender > > #log4j.appender.dest1.layout=org.apache.log4j.PatternLayout > > > > # Appender dest1 writes to the file "test" in user's home. > > log4j.appender.dest1.File=${CATALINA_HOME}/webapps/EP/WEB-INF/classes/app/log > > > > # Truncate 'test' if it aleady exists. > > log4j.appender.dest1.Append=false > > > If you haven't already, you can find log4j documentation at > http://logging.apache.org/log4j/docs/ > > As for the properties file, you don't often have to set them up, so it's > hard to remember without looking it up. One thing I do notice is the first > line should be "log4j.rootLogger=..." and not "rootCategory". Did someone do > a global find and replace? Those are very dangerous. The ".File" tells it > what file to write to, which should be in the specified directory within > your Tomcat installation directory (assuming it is expanded properly; I > don't think I've tried EL in here). Finally, I don't recognize that last > line with the ".Append". ============================================================================== TOPIC: Stubs and Skeleton Eclipse http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/28950846f584e84b ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 7:16 am From: [EMAIL PROTECTED] (ilyas) Hai, How can i create stubs and skeleton(s) in the Eclipse 3.0 IDE? I have a implementation class and i'll create stubs and skeletons (for RMI connection) Thanx for all suggestions. Greatings from Holland, ilyas ============================================================================== TOPIC: Thread and Listener http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/79e41b9865d2cf15 ============================================================================== == 1 of 2 == Date: Tues, Dec 7 2004 9:50 am From: Sudsy Bob Rivers wrote: <snip> > How do I ran a listner without blocking other processes? I am looking > for a solution that should work both on linux and windows. Perhaps a change in architecture? How about if your listener just performs a POST to the webserver each time it receives a trap? That way you can run it stand-alone, perhaps just modify the Tomcat startup script to also fire up your daemon. -- Java/J2EE/JSP/Struts/Tiles/C/UNIX consulting and remote development. == 2 of 2 == Date: Tues, Dec 7 2004 9:31 am From: Chris Smith Bob Rivers <[EMAIL PROTECTED]> wrote: > I have a servlet that is executed when tomcat starts (using > <load-on-startup>). So I did a call to my new class. > > The problem is that this class is actually a listener. When it starts, > it hangs the other procedures, including tomcat initilization. The simple answer is to create a new thread for it. However, pay attention to Sudsy's response as well. When you are creating separate threads inside a servlet container to do things that have nothing to do with answering HTTP requests, you're quite possibly doing something wrong. -- www.designacourse.com The Easiest Way To Train Anyone... Anywhere. Chris Smith - Lead Software Developer/Technical Trainer MindIQ Corporation ============================================================================== TOPIC: Struts and Timeout in Validator http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/d651e24002f4ba14 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 7:32 am From: "Brian S. Paskin" Hi, I am using the validator framework within Struts. However, I noticed if there is a session timeout the validator just throws a NullPointerException. I am using the standard validators, required, double, etc. Is there a way to do something if a timeout occurs? Thanks, Brian ============================================================================== TOPIC: JSF version of JSTL forEach? http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/12c3510dbb3c55d4 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 4:46 pm From: Andrea Desole I know that forEach is not allowed with JSF. At the moment I'm trying to develop a renderer with its own iteration, as suggested in paragraph 9.2.8 of the JSF 1.1 specs (I wouldn't really like to use dataTable), so that I can have the same functionalities of the JSTL forEach. Since it's taking some time, I thought that it might be better to get it somewhere. Unfortunately at the moment not only I can't find a renderer like that, but I can't find even a repository of JSF components or renderers. Does anyone know one? Thanks Andrea ============================================================================== TOPIC: [OT] Using hobby source code in your job ? http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/a60dfe865a7807c4 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 4:12 pm From: [EMAIL PROTECTED] (Richard Bos) RCollins <[EMAIL PROTECTED]> wrote: > Andrew Koenig wrote: > > If your employer changed their mind about this policy, there wouldn't be > > much you could do about it short of leaving. > > So it's not really your time--it's time that they are letting you have at > > their discretion. > > Not likely... most U.S. busniness are *not* the evil overlords that most > science-fiction writers would have you believe. > > A modern engineering company (such as Raytheon) tries very hard to keep > it's engineering staff happy and "well fed" with intersting projects. > If I create something "on my own time" that the company wants, they will > truly make me a very generous offer for that product. And what happens if you refuse? That, I think, is the real test. Richard ============================================================================== TOPIC: How to access session beans from within a message bean? http://groups-beta.google.com/group/comp.lang.java.programmer/browse_thread/thread/8d9a452f382c487 ============================================================================== == 1 of 1 == Date: Tues, Dec 7 2004 4:16 pm From: "davout" Am I am allowed to access stateless session beans from within a message driven bean, and if so, should I be accessing the session bean via its remote or local interface? ============================================================================== You received this message because you are subscribed to the Google Groups "comp.lang.java.programmer" group. To post to this group, send email to [EMAIL PROTECTED] or visit http://groups-beta.google.com/group/comp.lang.java.programmer To unsubscribe from this group, send email to [EMAIL PROTECTED] To change the way you get mail from this group, visit: http://groups-beta.google.com/group/comp.lang.java.programmer/subscribe To report abuse, send email explaining the problem to [EMAIL PROTECTED] ============================================================================== Google Groups: http://groups-beta.google.com
