OutOfMemoryError in 1.4.1, not in 1.3.1

I'm having trouble diagnosing an OutOfMemoryError in my application and I would like to double-check my assumptions here, if I may. I apologize in advance for the length of this post... I figured the more information the better.
The situation is this:
When running the application, it will eventually generate an OutOfMemoryError.
The OutOfMemoryError always happens during garbage collection and there is plenty of collectable garbage. What I mean to suggest is that I did not actually run out of memory.
If I specify the minimum heap size to be larger than default (equal to the max heap size at the extreme), I effectively increase the space allowed for allocation before a garbage collection which makes for a longer garbage collection which causes the error to occur much more quickly - usually within the first 3 garbage collections.
I am currently testing with the Windows JDK1.4.1 on Windows 2000/SP3.
My expectation (I have not verified this yet, perhaps someone here can confirm this) is that the JVM is supposed to guarantee that any time an allocation is attempted that, if there isn't enough memory available on the heap, the GC will run and attempt to give me my memory before it throws an error. I do not believe that this is what is happening.
The application uses several threads and my belief is that this must be some sort of race condition, incorrect or incomplete synchronization. When the OutOfMemoryError occurs during the collection, I will get anywhere from 1 to 11 (so far) threads reporting the error.
The reason I really don't think I'm running out of memory is based on observing the output of a profiler (OptimizeIt). I start with "-Xms192m -Xmx192m". Heap usage starts out at a nominal value of 15m. Application runs under load, eventually usage gets to within 1K of the limit and a "Full GC" begins. The first couple of times, memory usage drops back to the starting value of 15m. Then it fails. Either I "sprung" a really big leak or there is some other problem.
I have observed that, when running under 1.3.1, the GC runs while there is a LOT more room before reaching the heap limit. For example, in this case it will run when heap usage reaches around 180m. I have also noticed that, when running "-verbose:gc -XX:+PrintGCDetails", it appears that there is never a non-Full GC.
If anyone has any suggestions on where to look for this problem, I'm all ears. I've used a profiler to determine where most of the allocations are occuring, but that just doesn't help. I'm not really running out of memory, this could be a single byte allocation for all I know that's happening when it shouldn't. I can't believe that it's a VM bug or I would have heard more about it.

Well, as I mentioned, I am starting at only 15m of heap usage. I then climb to 192m and drop back down to 15m after the collection. Even under load, my baseline memory usage is only about 32m. There is a lot of temporary creation (I've done a lot to reduce it, which has helped, but still quite a bit).
The duration of the GC appears to be part of the equation. If the GC lasts a long time, it is more likely to happen.
Maybe I should also point out this: If, rather than specify "-Xms192m -Xmx192m", I use "-Xms128m -Xmx192m", I may get an OutOfMemoryError before heap size even grows to 192m.

Similar Messages

  • Java.lang.OutOfMemoryError when editing a routing note for a Proxy Service?

    Hi,
    Does anyone know why I am getting a java.lang.OutOfMemoryError in the AqualLogic Service Bus logs which freezes the browser (IE) when I try to edit a route node of a proxy service? I can change the name of the node but when I try to edit the node itself, the interface freezes and the out of memory thrown by the Service Bus. I have tried restarting the server etc..... The java memory allocated should already be adequate as it is set to 512Mb. All I can think of doing next is to uninstall the Service Bus and reinstall.
    The logs I am getting can be seen below.....
    Welcome, weblogic Connected to : servicebus Home WLS Console Logout Help AskBEA
    weblogic session Created 9/01/08 13:46 No Conflicts 3 Change(s) 1 Active Session(s)
    The source of this error is com.bea.portlet.adapter.scopedcontent.ActionLookupFailedException: java.lang.OutOfMemoryError at com.bea.portlet.adapter.scopedcontent.ScopedContentCommonSupport.executeAction(ScopedContentCommonSupport.java:699) at com.bea.portlet.adapter.scopedcontent.ScopedContentCommonSupport.renderInternal(ScopedContentCommonSupport.java:268) at com.bea.portlet.adapter.scopedcontent.StrutsStubImpl.render(StrutsStubImpl.java:107) at com.bea.netuix.servlets.controls.content.NetuiContent.preRender(NetuiContent.java:288) at com.bea.netuix.nf.ControlLifecycle$6.visit(ControlLifecycle.java:427) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:708) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walkRecursivePreRender(ControlTreeWalker.java:720) at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:183) at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361) at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:339) at com.bea.netuix.nf.Lifecycle.runOutbound(Lifecycle.java:186) Caused by: java.lang.OutOfMemoryError
    Thanking you in advance for any help/insight.

    Okay, I fixed the "Incompatible initial and maximum heap sizes specified" issue now. The problem was that in the lh.bat script the parameter -Xmx128M was hardcoded and overwrote my own -Xmx setting.
    I now set JAVA_OPTS to "-Xms1400m -Xmx1400m" which is the maximum that Java accepts without complaining about too little memory. However, I still get the OutOfMemoryError and in addition to that I now also get this error:
    com.waveset.util.Shutdown: Sorry!  This repository has been shut down by an administrator.  Please try to get another instance.
    I've googled already but found only two sites and those weren't really helpful. So, any help is very much appreciated!
    Thanks,
    David

  • FB 4.7 AIR 3.6 Flex 4.9 iOS packing - Exception in thread "main" java.lang.OutOfMemoryError'

    I've got an error similar to Isaac_Sunkes' 'FB 4.7 iOS packaging - Exception in thread "main" java.lang.OutOfMemoryError',
    but the causes are not related to what he discovered, corrupt image or other files, I'd exclude bad archive contents in my project.
    I'm using Flash Builder 4.7 with Adobe AIR 3.6 set into an Apache Flex 4.9.1 SDK;
    HW system is:
    iMac,    2,7 GHz Intel Core i5,    8 GB 1600 MHz DDR3,    NVIDIA GeForce GT 640M 512 MB,    OS X 10.8.2 (12C3103)
    The Flash project consists in an application with a main SWF file which loads, via ActionScript methods, other SWF in cascade.
    I've formerly compiled and run the application on an iPad 1, IOS 5.0.1 (9A405), but got on the device the error alert:
    "Uncompiled ActionScript
    Your application is attempitng to run
    uncompiled ActionScript, probably
    due to the use of an embedded
    SWF. This is unsupported on iOS.
    See the Adobe Developer
    Connection website for more info."
    Then I changed the FB compiler switches, now are set to:
    -locale en_US
    -swf-version=19
    Please note that without the switch    -swf-version=19     the application is compiled correctly and the IPA is sent to the device
    and I can debug it, but iOS traps secondary SWF files and blocke the app usage, as previously told.
    they work on deploy of small applications,
    but, when I try to build a big IPA file either for an ad-hoc distribution, either for an debug on device, after some minutes long waiting, I get a Java stuck, with this trace:
    Error occurred while packaging the application:
    Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
        at java.util.HashMap.addEntry(HashMap.java:753)
        at java.util.HashMap.put(HashMap.java:385)
        at java.util.HashSet.add(HashSet.java:200)
        at adobe.abc.Algorithms.addUses(Algorithms.java:165)
        at adobe.abc.Algorithms.findUses(Algorithms.java:187)
        at adobe.abc.GlobalOptimizer.sccp(GlobalOptimizer.java:4731)
        at adobe.abc.GlobalOptimizer.optimize(GlobalOptimizer.java:3615)
        at adobe.abc.GlobalOptimizer.optimize(GlobalOptimizer.java:2309)
        at adobe.abc.LLVMEmitter.optimizeABCs(LLVMEmitter.java:532)
        at adobe.abc.LLVMEmitter.generateBitcode(LLVMEmitter.java:341)
        at com.adobe.air.ipa.AOTCompiler.convertAbcToLlvmBitcodeImpl(AOTCompiler .java:599)
        at com.adobe.air.ipa.BitcodeGenerator.main(BitcodeGenerator.java:104)
    I've tried to change the Java settings on FB's eclipse.ini in MacOS folder,
    -vmargs
    -Xms(various settings up to)1024m
    -Xmx(various settings up to)1024m
    -XX:MaxPermSize=(various settings up to)512m
    -XX:PermSize=(various settings up to)256m
    but results are the same.
    Now settings are back as recommended:
    -vmargs
    -Xms256m
    -Xmx512m
    -XX:MaxPermSize=256m
    -XX:PermSize=64m
    I've changed the Flex build.properties
    jvm.args = ${local.d32} -Xms64m -Xmx1024m -ea -Dapple.awt.UIElement=true
    with no results; now I'n get back to the standard:
    jvm.args = ${local.d32} -Xms64m -Xmx384m -ea -Dapple.awt.UIElement=true
    and now I truely have no more ideas;
    could anyone give an help?
    many thanks in advance.

    I solved this. It turns out the app icons were corrupt. After removing them and replacing them with new files this error went away.

  • Having issues with Crawler

    Having two issues with my crawler service. My environment is Netware 6.0 with Java version 1.4.1_05, and Apache 1.03
    1) Eating memory. I have allocated 128 to 256 MB of memory and I still get out of memory issues. I would like to think that this app does need more than 256MB of memory. Specifically I am getting this: 2004-05-31 12:00:56 - Ctx(/soap) : Exception in R( /soap + /servlet/rpcrouter + null) - java.lang.OutOfMemoryError.
    2) Am getting "not logging out cached identity" message. I am assuming that the crawler is leaving open a connection from the portal server. Is this an issue or a feature?:
    2004-06-01 09:51:24 - ContextXmlReader: Context config=$TOMCAT_HOME\conf\apps-admin.xml Module MOD_JK.NLM load status OK 2004-06-01 09:51:24 - ContextXmlReader: Context config=$TOMCAT_HOME\conf\apps-examples.xml 2004-06-01 09:51:24 - AutoWebApp: Loaded from config: DEFAULT:/admin 2004-06-01 09:51:24 - AutoWebApp: Loaded from config: DEFAULT:/examples 2004-06-01 09:51:24 - AutoWebApp: Auto-Adding DEFAULT:/ 2004-06-01 09:51:24 - AutoWebApp: Auto-Adding DEFAULT:/soap 2004-06-01 09:51:24 - ContextManager: Tomcat configured and in stable state 2004-06-01 09:51:24 - ContextManager: Adding DEFAULT:/admin 2004-06-01 09:51:24 - ContextManager: Adding DEFAULT:/examples 2004-06-01 09:51:24 - ContextManager: Adding DEFAULT:/ROOT 2004-06-01 09:51:24 - ContextManager: Adding DEFAULT:/soap EmbededTomcat: Init time 1096 2004-06-01 09:51:24 - Ajp12Interceptor: Starting on 8007 2004-06-01 09:51:24 - Ajp12Interceptor: Starting on 0 2004-06-01 09:51:24 - Ajp13Interceptor: Starting on 8009 2004-06-01 09:51:24 - Ajp13Interceptor: Starting on 0 EmbededTomcat: Startup time 63 2004-06-01 09:51:35 - SessionIdGenerator: Created random class java.security.SecureRandom 0 [Thread-15] WARN com.plumtree.crawlerwebservice.novell.NovellContainerProvider - Not logging out cached identity
    Thanks
    Nigel

    I wasn't sure if you were using the Novell Crawler or writing your own. This board is principly for people writing crawlers. Questions about Plumtree products can be directed to the Deployment center, or Technical Support.

  • OutOfMemory when using QueueService

    Hi,
    I have a crawler plugin implemented using QueueService. But it runs into OutOfMemory problem while crawling.
    Scenario: I have a content repository which has 1 parent and 10,000 children.
    Now my crawler logic looks like below
    public void crawl() {
         while(!m_abort && queueSize > 0) {
              //get next documentMetaData from queue
    //process it
              //submit the documentMetadata
              processChild(documentMetadata);
    private void processChild(DocumentMetadata docMetadata) {
         List childList = getChildren(docMetadata);
         //the size of childList is around 10,000
         while(childList.size > 0) {
              child = childList.remove(0);
              queueService.enqueue(child);
    From logs, it looks like once one thread enters processChild() method, none of the other threads enter crawl() method. I get an OutOfMemoryError in processChild() method.
    Note: The same piece of code works great when i use a custom arrayList to store custom object instead of QueueService and docMetadata.
    Can anybody let me know what is the cause of the problem and a possible solution to it.
    Thanks in advance.
    Regards,
    Priya

    Hi Tom,
    today I have been switching from MySQL to Oracle XE as data base, since this will be our target plattform. I just used MySQL in the first place because we had it already running for some third party components that we will use later and that were initially developed for MySQL.
    Switching to to Oracle seemed to solve the recovery problem. I shutdown the database, waited for error messages in the WLS log to appear and restarted it. Then I was again able to send messages to the queue without restarting WLS. From what you wrote in your last post this should not be possible, should it? I am a bit confused about this. I guess I will try some more tests about this just to make sure. Could this be the because I did restart the database rather quickly?
    I am also running some tests to see if the WLS can restart while having a large amount of messages in the JDBCStore. Maybe this was a MySQL problem. But if it was not, aren't there any WLS options that would force the server to just read a part of the messages? Or could we try to split up the table and let WLS only read part of the data, get those messages delivered, then shut the server down again, move in the rest of the messages and restart again? I saw that there are some sort of "control entries" in the JDBCStore and I think chances are pretty good those entries depend on the amount/data of the messages stored in the table and how much WLS has processed them. So I would not dare to do this kind of manipulation without confirmation from Oracle and documentation how this should be done.
    Best Regards,
    Chris
    BTW: I am not an Oracle employee. but thanks for the offer :-)

  • I want to download and image from the url and image is in byte format

    hi
    i want to download the image from the url:
    http://www.tidelinesonline.com/mobile/j2me_v1?reqType=imageJoin&imageCount=1&month=1&day=1&year=2008&id=1&imageWidth=230&imageHeight=216&imageDepth=8&imageUnits=feet&imageType=JPG&msisdn=456
    can any one help me to do this i need to finish this today plz help me.
    first 5 character 09593 is the length of the image we need to substract image length from total length.
    thanks in advance
    M.Raj
    Edited by: Mraj.Bangalore on May 15, 2008 12:01 AM
    Edited by: Mraj.Bangalore on May 15, 2008 12:01 AM

    hi
    thanks for the reply,
    that works only if .png file is there in the path.
    i worked it out, it is working fine now
    try
                   httpConn = (HttpConnection)Connector.open(url);
                   is=httpConn.openInputStream();
                   responseCode = httpConn.getResponseCode();
                   if(httpConn.getResponseCode() == 200)
                             ByteArrayOutputStream bStrm = null;
                             byte[] data = new byte[512];
                             int contentLen = httpConn.getHeaderFieldInt("Content-Length", 0);
                             if(contentLen > 0)
                                  response = new byte[contentLen];
                             else
                                  bStrm = new ByteArrayOutputStream();
                             int count = 0, tmp =0;
                                  while ((count = is.read(data)) >= 0)
                                       if( contentLen > 0 )
                                            for(int i=0;i<count && tmp+i < contentLen;i++)
                                                 response[tmp+i] = data;
                                            tmp += count;
                                       else
                                            bStrm.write(data, 0, count);
    //                                    if( aborted)
    //                                         break;
                                  data = null;
                                  System.gc();
                                  if( contentLen <= 0 )
                                       response = bStrm.toByteArray();
                                       bStrm.close();
                                       bStrm = null;
                                       System.gc();                                   
                        else
    //                          main.showAlert("ERROR","Connection failed.Please access again later");
    //                          main.changeToMain();
              catch(Exception e){
                   response = null;
                   responseCode = 0;
    //                main.showAlert("ERROR","Connection failed.Please access again later");
    //                main.changeToMain();
              catch(OutOfMemoryError e){
    //                main.showAlert("ERROR","Not enough memory, please disable some apps or delete files and try again.");
    //                main.changeToMain();
              finally
                   System.out.println("Before Creation"+response.length);
                   img = Image.createImage(response, 5, response.length-5);
                   System.out.println("After Creation");
                   CanvasImageFile canvas = new CanvasImageFile(this);
                   midlet.display.setCurrent(canvas);
                   try
                        if( is != null )
                             is.close();
                             is=null;
                   catch(Exception ex){
    //                     main.showAlert("ERROR","Connection failed.Please access again later");}
                             if( httpConn != null )
                             try {
                                       httpConn.close();
                                  } catch (IOException e) {
                                       // TODO Auto-generated catch block
                                       e.printStackTrace();
                             httpConn=null;

  • BufferedImage causing OutOfMemoryError not getting GC'd

    I'm writing a photo library application just for practice. I'm trying to display all the jpegs in an album by displaying thumbnails of them as ImageIcons in JLabels on a JFrame.
    To get the images I use ImageIO.read(File) into a BufferedImage. Then using Image.getScaledInstance I pass the resized image to a new ImageIcon which is added to the JLabel. This all happens in a final class ThumbDisplay, method showPic which returns the JLabel.
    I call ThumbDisplay.showPic(File) in a loop, and it can read about 5 files before throwing an OutOfMemoryError. I have been able to successfully display no more than 4 images. Most of my images were taken on my digital camera and are around 2560X1920.
    I read a bit about the java heap space and I understand how 5 BufferedImages of that size open at once can easily eat up memory. But the code looks to me that any instantiated BufferedImages would be GC'd as soon as the showPic method returned the JLabel. JHAT proved otherwise and there were still 5 instances of BufferedImage when I got the OutOfMemoryError.
    So, the following is my example code block and the StackTrace. No extra stuff required. Just throw about 10 extra large jpegs in whatever path you choose to put in 'File directory' on line 9, compile and run. I'd really appreciate some help on this. I've searched countless message boards for that error and found many similar topics but ZERO answers. Can someone tell me why these aren't getting GC'd?
    code:
    1. import javax.swing.*; 
       2. import java.awt.image.*; 
       3. import javax.imageio.*; 
       4. import java.awt.*; 
       5. import java.io.*; 
       6.  
       7. public class ThumbTest{ 
       8.     public static void main(String args[]){ 
       9.         File directory = new File("c:\\pictemp\\"); 
      10.         File[] files = directory.listFiles(); 
      11.         JFrame jf = new JFrame(); 
      12.         jf.setSize(1000,1000); 
      13.         jf.setLayout(new GridLayout(10,10,15,15)); 
      14.         for(File file : files) 
      15.             jf.add(ThumbDisplay.showPic(file)); 
      16.          
      17.         jf.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); 
      18.         jf.setVisible(true); 
      19.  
      20.  
      21.     } 
      22. } 
      23.  
      24. final class ThumbDisplay{ 
      25.      
      26.     public static JLabel showPic(File f){ 
      27.         BufferedImage img = null; 
      28.         try{ 
      29.             img = ImageIO.read(f); 
      30.         }catch (IOException e){ 
      31.             e.printStackTrace(); 
      32.         } 
      33.         if(img != null){ 
      34.             float ratio = 100 / (float) img.getHeight(); 
      35.             int w = Math.round((float)img.getWidth() * ratio); 
      36.             int h = Math.round((float)img.getHeight() * ratio); 
      37.             return new JLabel(new ImageIcon(img.getScaledInstance(w,h,Image.SCALE_DEFAULT))); 
      38.         } else 
      39.             return new JLabel("no image"); 
      40.     } 
      41. }exception:
       1. D:\java\Projects\PhotoLibrary>java ThumbTest 
       2. Exception in thread "main" java.lang.OutOfMemoryError: Java heap space 
       3.         at java.awt.image.DataBufferByte.<init>(Unknown Source) 
       4.         at java.awt.image.ComponentSampleModel.createDataBuffer(Unknown Source) 
       5.         at java.awt.image.Raster.createWritableRaster(Unknown Source) 
       6.         at javax.imageio.ImageTypeSpecifier.createBufferedImage(Unknown Source) 
       7.         at javax.imageio.ImageReader.getDestination(Unknown Source) 
       8.         at com.sun.imageio.plugins.jpeg.JPEGImageReader.readInternal(Unknown Sou 
       9. rce) 
      10.         at com.sun.imageio.plugins.jpeg.JPEGImageReader.read(Unknown Source) 
      11.         at javax.imageio.ImageIO.read(Unknown Source) 
      12.         at javax.imageio.ImageIO.read(Unknown Source) 
      13.         at ThumbDisplay.showPic(ThumbTest.java:29) 
      14.         at ThumbTest.main(ThumbTest.java:15) 

    sjasja wrote:
    ImageIO.read() does not cache images. Run ImageIO.read() in a loop for a large image. No OOME.
    Run the OP's original program under hprof. See in hprof's output how the original image data are retained. Gives an OOME, and hprof's output shows where the memory goes.
    After creating a resized image with Image.getScaledInstance(), make a copy of the resized image and discard the first resized image. (Create a BufferedImage, get a Graphics2D, and blit with g.drawImage()). Discarding the resized image will also make the pointer to the original large image go away, allowing GC. No OOME.
    In the OP's program, edit like so:
    // return new JLabel(new ImageIcon(img.getScaledInstance(w,h,Image.SCALE_DEFAULT))); 
    new JLabel(new ImageIcon(img.getScaledInstance(w,h,Image.SCALE_DEFAULT)));
    return new JLabel("yes image");You are now doing all the image loading and resizing the original program does. But because the JLabel is discarded, the pointer to the resized image is discarded, thus the pointer to the original image is discarded, and everything can be GCd. No OOME.
    If you want to see how the scaled image retains a pointer to the original image, see the interaction of Image.getScaledImage(), BufferedImage.getSource(), java.awt.image.FilteredImageSource, sun.awt.image.OffScreenImageSource, and sun.awt.image.ToolkitImage.
    By these experiments, in a reply above, I guesstimated: "As far as I can figure out, Image.getScaledInstance() keeps a pointer to the original image."
    Yes, getScaledInstance() is somewhat slow. Here is the FAQ entry for a better way to resize an image: http://java.sun.com/products/java-media/2D/reference/faqs/index.html#Q_How_do_I_create_a_resized_copy
    I have a problem with this because it should mean that the code fragment I posted in reply #5 should make no difference but I can load over a thousand images using it whereas the original code allowed me to load only 30 or so.
    I can see how creating a buffered image from the scaled image might help since discarding the scaled image will discard any reference to the original image stored in the scaled image.

  • J2EE 70 does not start - OutOfMemoryError rc=666

    We have NTW04s ABAP+J2EE (ut. EP, BI) on Win 32 bit, 2048 RAM installed.
    The J2SDk is 1.4.2_17.
    We applied the parameters of note 723909 and 1044330 for Win32 (-Xms and -Xmx=1024m, Perm and MaxPerm=256m, new and MaxNew=160m) anyway the J2EE server0 does not come up.
    It start and arrive in state 'Starting Apps' in MMC and into the log std_server0.out we see 'Framework started' but after that we see these entries:
    730.927: [GC 730.927: [ParNew: 239922K->70400K(245760K), 0.3252431 secs] 293939K->128044K(966656K), 0.3253927 secs]
    FATAL: Caught OutOfMemoryError! Node will exit with exit code 666
    ===========================================
    getThreadDump : Tue Jun 10 15:42:50 2008
    FATAL: Caught OutOfMemoryError! Node will exit with exit code 666
    ===========================================
    java.lang.OutOfMemoryError: unable to create new native thread ......."
    As note 1044330 says the ut BI Java require more Heap in the Perm area, and we suspect there is not free heap memory to start the J2EE applications, we try to enlarge it to 512m (perm and maxperm) but the J2EE server0 does not come up at all.
    Into the  std_server0.out we see these entries:
    "....Reserved 1610612736 (0x60000000) bytes before loading DLLs.
    [Thr 4876] MtxInit: -2 0 0
    Error occurred during initialization of VM
    Could not reserve enough space for object heap"
    We try also with perm and maxperm equal to 320m, but the result is the same.
    We reduced the Abap instance at minimal as number of work process, buffers and Phys_mem_size. We reduced also the Oracle SGA at minimal.
    Any advise ?
    bye

    Thanks for the fedbacks but....
    We read these notes, anyway any attempt to increase the Heap size produce the error 'Could not allocate ....'.
    This is a 32 bit system.
    From the other side if we leave the Xmx=Xms=1024M and the other parameters suggested in the Oss notes for 32bit platform the server0 starts but after a while it give the error "Out of memory...."
    It seems the Heap is not enought to start all the applications.
    We installed the Sap Adddress Viever and identified the JLAUCH process responsible for the server0.
    If we do "List/Rebase" we see 8 dlls: 7 from the J2SDK 1.4.2_17 in use and one from Windows.
    Is it possible that the J2SDK 1.4.2_17 compete with the JLAUCH for teh Heap memory ?

  • Java.lang.OutOfMemoryError  solved (was NOT a leak)

    Alright I'm just posting this to hopefully save someone some time in the future.
    This was a bug that dragged out for over a year. An application would be deployed to a production app server and low and behold OutOfMemoryError's would start to be thrown, naturally the new application would look like the most likely culprite. So now the unlucky developer gets to spend hours running the memory profiler and looking in vain for a memory leak that does not exist.
    The actual problem was not the Heap running out of memory as in most memory leaks. No, the problem was the app server runs out of Perm Generation space (this is where class loaders and reflection data is stored) by default the Max Perm space is 64MB which is fine for most apps, but on an application server (OC4J in our case) when you have 10 apps with tons of JSP's this space can fill up.
    You can check out your perm gen usage by running the jmap tool with the -heap option and pass the pid of the oc4j instance to it, this will tell you your max perm gen space and your current usage.
    Anyway to up your max perm gen space, start the java process for your app server with the parameter -XX:MaxPermSize=128m
    Problem solved.

    Good Luck,
    If 10.1.3 uses 1.5.x of the JVM then I believe they added an extra string on the end of of the outofmemoryerror that says Heap or PermGen so you have that hint to go on.
    You should take a look at the jmap tool in 1.5 though, you can make it print a dump of what's in the heap then open it up in the tool jhat to take a graphical look of what's hanging out in memory, very useful.
    By the way, thanks very much for sharing your
    experience.
    I will surely encounter your problem since I have a
    big app.
    I begin deployment to OAS 10.1.3 at the end of the
    month, I waited for the latest version since it is
    much easier to maintain then previous versions.
    Regards
    Fred

  • OutOfMemoryError on Jtable with not 'that' much data

    Hi,
    Im getting outofmemoryerror when using my jtable. The dataset is collected from an xml file at the moment (soon to be changed to mysql as were getting too much data for xml) but anyhow, of course it depends which pc you are on, but when accessing our programs applet sometimes we will get this outofmemoryerror with only 1056 lines. Now I know lots of people are going to say just cut down the number of lines displayed, use a filter, etc etc, and we are working on adding a filter, but for now I need all of the lines to be displayed, and well I have seen people displaying 10,000 lines or more before getting this error.
    Maybe I am doing something simple wrong. Please take a look.
    Im not really sure what code to supply you with, as the StudyTableModel wont be of any use really....
    Im just after some advice really. Why do you think I am getting my OutOfMemoryError with so few rows?
    Thanks, and if you want any code supplied, then just ask :D
    James

    I meant profiler, sorry typo.
    Wikipedia explains it best: http://en.wikipedia.org/wiki/Profiler_%28computer_science%29
    You'd want a memory profiler.
    If you're still a newbie than getting this stuff to work might seem like a big task and could take some time, but in the end it will definitely be worth it, since knowing where your problem is is much, much better than guessing ;-)

  • 1) OutOfMemoryError: Java heap space 2) Could not create the JVM

    Hi guys!
    I'm having a lot of memory problems with the java virtual machine and I really need to fix them as soon as I can :(
    I was running an heavy application on Eclipse and at the end it stopped saying:
    Exception in thread "main" java.lang.OutOfMemoryError: Java heap space so I tried to enlarge the memory heap space in various ways... editing eclipse.ini (but I cannot go over a certain quantity), trying to change some parameters as:
    -vmargs -XX:MaxPermSize=<memory size>or to launch a jar of my application using :
    Java –jar –Xms1024M –Xmx3000M jarnameAnd now the error I got is:
    Error occurred during initialization of VM
    Could not reserve enough space for object heap
    Could not create the Java virtual machine.I just don't know what to do!
    I'm using a workstation but I don't have it right now in front of me... it should be a 4 core xeon-64bit having 8 giga of ram, under windows vista.
    do you have any suggestions?
    many many thanks!
    lou

    loucat wrote:
    I don't know if it requires 3GB, I just know the default memory is not enough... I have to load an index (a Lucene-based one) made up of almost 4 GB of images... I cannot change anything of the code about it :(
    Should I have to install a new java version downloading it from this page?
    http://www.java.com/en/download/faq/java_win64bit.xml
    I would download the 64 bit version from this page:
    [http://java.sun.com/javase/downloads/widget/jdk6.jsp]
    .. but you should probable be able to find it on java.com as well.

  • OutOfMemoryError on W2K, not on NT 4

    Hi,
    I have a program that reads text files and sends them through JMS.
    This works really fine on a machine with windows NT 4, but on another machine with windows 2000, I get OutOfMemory errors very quickly.
    I have tried running it with the -verbosegc option, and there is something I do not understand :
    GC 4497K->3983K(4568K), 0.0010714 secs]
    [GC 4498K->3983K(4568K), 0.0011437 secs]
    [GC 4496K->3983K(4568K), 0.0010714 secs]
    [GC 4496K->3984K(4568K), 0.0012275 secs]
    [GC 4497K->3984K(4568K), 0.0010948 secs]
    [GC 4498K->3995K(4568K), 0.0011479 secs]
    [Full GC 63551K->4222K(65280K), 0.1820189 secs]
    [GC 7604K->5328K(65280K), 0.0067830 secs]
    [GC 7377K->5329K(65280K), 0.0010540 secs]
    [GC 7379K->5335K(65280K), 0.0011856 secs]
    [GC 7384K->5336K(65280K), 0.0011800 secs]
    [GC 7385K->5337K(65280K), 0.0012083 secs]
    [GC 7386K->5337K(65280K), 0.0012331 secs]
    (this is on my W2K box)
    I don't understant the Full GC 63551K, while it was just 4498K on the line above. And when I get this line, I also get an OutOfMemoryError. Can someone help me ?
    I am running my program with JDK1.3.1_09.
    Thanks !
    Julien

    Hi Julien,
    We have similar problem in Unix that the Garbage collection happened every 1 minutes and took 17 seconds...
    We went through the url :
    http://java.sun.com/docs/hotspot/gc/index.html
    to understand what happens...
    We identified that we had been caching one of our RMI's Remote instance in our Session which was creating this Garbage collection. This might not be what you are facing but you can have a look into this link and see what is wrong.
    More over I heard that JDK1.3.1_11 version has resolved most of the JVM related Issues.
    Thanks and regards,
    Pazhanikanthan. P

  • Java.lang.OutOfMemoryError: PermGen space Not able to open applications

    Hi ,
    I am facing issue in running the application when I deploy 10 applications successfully to the Integrated weblogic server [in jdev].
    Then after some time I am not able to open any of the application.
    Thanks and Regards,
    Vivek Pemawat

    Set MaxPermSize to a higher value.
    export JVM_ARGS="-Xmx1024m -XX:MaxPermSize=256m"
    https://forums.oracle.com/thread/1140785

  • Can not deploy Oracle Spatial Routing Engine on Oracle Weblogic

    I posted my question with Oracle Support, however they directed me to the oracle forums. I am hoping this problem can be resolved here. In any event I am getting the following stack trace (shown below). I am using Spatial Version 11.2.0.1.0, Map Viewer 11.1.1.5.1, and WebLogic 10.3.5.0, and data-set provided by Pro Oracle Spatial for Oracle Database 11g - Apress boos. I have successful in deploying Map Viewer, Geocoder Server, but not the Routing Server.
    Below is the stack trace:
    ####<Nov 18, 2011 3:31:07 PM CST> <Error> <Deployer> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1321651867820> <BEA-149202> <Encountered an exception while attempting to commit the 1 task for the application 'routeserver'.>
    ####<Nov 18, 2011 3:31:07 PM CST> <Warning> <Deployer> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <[STANDBY] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1321651867826> <BEA-149004> <Failures were detected while initiating deploy task for application 'routeserver'.>
    ####<Nov 18, 2011 3:31:07 PM CST> <Warning> <Deployer> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <[STANDBY] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1321651867826> <BEA-149078> <Stack trace for message 149004
    weblogic.application.ModuleException: [HTTP:101216]Servlet: "RouteServerServlet" failed to preload on startup in Web application: "routeserver".
    java.lang.NullPointerException
         at oracle.spatial.router.server.RouteServerServlet.init(RouteServerServlet.java:102)
         at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
         at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
         at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
         at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539)
         at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1985)
         at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1959)
         at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1878)
         at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3153)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1508)
         at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:482)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
         at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
         at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205)
         at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
         at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1510)
         at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:482)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
         at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
         at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205)
         at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
         at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    Caused By: java.lang.NullPointerException
         at oracle.spatial.router.server.RouteServerServlet.init(RouteServerServlet.java:102)
         at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
         at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
         at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
         at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539)
         at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1985)
         at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1959)
         at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1878)
         at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3153)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1508)
         at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:482)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
         at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
         at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205)
         at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
         at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    >
    ####<Nov 18, 2011 3:31:07 PM CST> <Error> <Console> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <[ACTIVE] ExecuteThread: '1' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1321651867831> <BEA-240003> <Console encountered the following error weblogic.application.ModuleException: [HTTP:101216]Servlet: "RouteServerServlet" failed to preload on startup in Web application: "routeserver".
    java.lang.NullPointerException
         at oracle.spatial.router.server.RouteServerServlet.init(RouteServerServlet.java:102)
         at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
         at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
         at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
         at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539)
         at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1985)
         at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1959)
         at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1878)
         at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3153)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1508)
         at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:482)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
         at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
         at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205)
         at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
         at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
         at oracle.spatial.router.server.RouteServerServlet.init(RouteServerServlet.java:102)
         at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
         at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
         at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
         at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539)
         at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1985)
         at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1959)
         at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1878)
         at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3153)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1508)
         at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:482)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
         at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
         at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205)
         at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
         at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1510)
         at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:482)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.ScopedModuleDriver.start(ScopedModuleDriver.java:200)
         at weblogic.application.internal.flow.ModuleListenerInvoker.start(ModuleListenerInvoker.java:247)
         at weblogic.application.internal.flow.ModuleStateDriver$3.next(ModuleStateDriver.java:425)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.flow.ModuleStateDriver.start(ModuleStateDriver.java:119)
         at weblogic.application.internal.flow.StartModulesFlow.activate(StartModulesFlow.java:27)
         at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:636)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
         at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:205)
         at weblogic.application.internal.EarDeployment.activate(EarDeployment.java:58)
         at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:161)
         at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:79)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:569)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:150)
         at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:116)
         at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:323)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:844)
         at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1253)
         at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:440)
         at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:163)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:195)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:13)
         at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:68)
         at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:528)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)
    Caused by: java.lang.NullPointerException:
         at oracle.spatial.router.server.RouteServerServlet.init(RouteServerServlet.java:102)
         at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:283)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
         at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:64)
         at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
         at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
         at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:539)
         at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1985)
         at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1959)
         at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1878)
         at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:3153)
         at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:1508)
    >
    ####<Nov 18, 2011 3:31:07 PM CST> <Warning> <netuix> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1321651867900> <BEA-423420> <Redirect is executed in begin or refresh action. Redirect url is /console/console.portal?_nfpb=true&_pageLabel=AppApplicationOverviewPage&AppApplicationOverviewPortlethandle=com.bea.console.handles.AppDeploymentHandle%28%22com.bea%3AName%3Drouteserver%2CType%3DAppDeployment%22%29.>
    ####<Nov 18, 2011 3:31:34 PM CST> <Info> <Health> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <weblogic.GCMonitor> <<anonymous>> <> <> <1321651894879> <BEA-310002> <43% of the total memory in the server is free>
    ####<Nov 18, 2011 3:57:36 PM CST> <Info> <Health> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <weblogic.GCMonitor> <<anonymous>> <> <> <1321653456622> <BEA-310002> <67% of the total memory in the server is free>
    ####<Nov 18, 2011 3:58:36 PM CST> <Info> <Health> <sa2apsp-spatialdev.sa2apsp.com> <AdminServer> <weblogic.GCMonitor> <<anonymous>> <> <> <1321653516623> <BEA-310002> <51% of the total memory in the server is free>

    Below is the configuration of the routeserver.ear (web.xml):
    <?xml version="1.0"?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN" "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
    <web-app>
    <servlet>
    <servlet-name>RouteServerServlet</servlet-name>
    <servlet-class>oracle.spatial.router.server.RouteServerServlet</servlet-class>
    <load-on-startup>1</load-on-startup>
    <!-- RouteServer initialization parameters -->
    <init-param>
    <param-name>routeserver_schema_jdbc_connect_string</param-name>
    <param-value>jdbc:oracle:[email protected]:1521:SPATLDB</param-value>
    <!--
    <description>
    Tells the Router how to connect to the database use the following
    as a template replaceing host_name, port_number and oracle_sid:
    jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=host_name)(PORT=port_number)))(CONNECT_DATA=(SID=oracle_sid)))
    host_name: the name of the machine where the database is located
    for example mysystem.us.mycompany.com
    port_number: the database port number which can be found with the
    lsnrctl status command
    oracle_sid: the SID of your database
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>routeserver_schema_username</param-name>
    <param-value>spatial</param-value>
    </init-param>
    <init-param>
    <param-name>routeserver_schema_password</param-name>
    <param-value>!spatial</param-value>
    </init-param>
    <init-param>
    <param-name>routeserver_network_name</param-name>
    <param-value>NDM_US</param-value>
    </init-param>
    <init-param>
    <param-name>routeserver_schema_connection_cache_min_limit</param-name>
    <param-value>3</param-value>
    </init-param>
    <init-param>
    <param-name>routeserver_schema_connection_cache_max_limit</param-name>
    <param-value>100</param-value>
    </init-param>
    <!-- Geocoder parameters -->
    <init-param>
    <param-name>geocoder_type</param-name>
    <param-value>httpclient</param-value>
    <!--
    <description>
    httpclient - interacts with geocoder Java Servlet
    thinclient - interacts with geocoder in Oracle Database
    none - no geocoder provided
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>geocoder_match_mode</param-name>
    <param-value>DEFAULT</param-value>
    </init-param>
    <!-- These parameters are used if geocoder_type is httpclient -->
    <init-param>
    <param-name>geocoder_http_url</param-name>
    <param-value>http://127.0.0.1:7001/geocoder</param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_http_proxy_host</param-name>
    <param-value></param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_http_proxy_port</param-name>
    <param-value>-1</param-value>
    </init-param>
    <!-- These parameters are used if geocoder_type is thinclient -->
    <!--
    <init-param>
    <param-name>geocoder_schema_host</param-name>
    <param-value>sa2apsp-spatialdev.sa2apsp.com</param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_schema_port</param-name>
    <param-value>1521</param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_schema_sid</param-name>
    <param-value>SPATLDB</param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_schema_username</param-name>
    <param-value>spatial</param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_schema_password</param-name>
    <param-value>spatial</param-value>
    </init-param>
    <init-param>
    <param-name>geocoder_schema_mode</param-name>
    <param-value>thin</param-value>
    <description>
    thin, oci8, etc
    </description>
    </init-param>
    -->
    <!-- RouteServer Logging parameters -->
    <init-param>
    <param-name>log_filename</param-name>
    <param-value>/u01/app/routeserver/routeserver.ear/web.war/log/RouteServer.log</param-value>
    <!--
    <description>
    Create a log file for the Router.
    The log file can be specified as a relative path log/RouteServer.log
    This creates a log file relative to the Router install.
    In OC4j the log file created would be
    $OC4J_HOME/j2ee/home/applications/routeserver/web/log/RouteServer.log
    The log file can also be specified as an absolute path:
    /scratch/logfiles/router/Router.log
    If the <param-value></param-value> is left empty the Router
    creates a default log file:
    $OC4J_HOME/j2ee/home/applications/routeserver/web/log/RouteServer.log
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>log_level</param-name>
    <param-value>INFO</param-value>
    <!--
    <description>
    What information should be written to log file?
    FATAL - highest level: only FATAL messages are logged
    ERROR - error and fatal messages are logged
    WARN - warn, error, and fatal messages are logged
    INFO - info, warn, error, and fatal messages are logged
    DEBUG - debug, info, warn, error, and fatal messages are logged
    FINEST - lowest level: everything is logged
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>log_thread_name</param-name>
    <param-value>true</param-value>
    <!--
    <description>
    Whether or not to log the thread name which
    makes the log entry - (true or false).
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>log_time</param-name>
    <param-value>true</param-value>
    <!--
    <description>
    Whether or not to log the time of day along
    with the log entry - (true or false).
    </description>
    -->
    </init-param>
    <!-- Road description parameters -->
    <init-param>
    <param-name>max_speed_limit</param-name>
    <param-value>34</param-value>
    <!--
    <description>
    Maximum speed limit of any road segment.
    In meters per second. Should be A
    POSITIVE INTEGER SMALLER THAN 32767.
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>local_road_threshold</param-name>
    <param-value>25</param-value>
    <!--
    <description>
    If the estimated distance between source and destination nodes is
    less than this value, in miles, then keep local roads a viable
    option. This is done as an optimization for short routes.
    Increasing this value beyond the 25 mile default may generate more
    accurate routes using local roads but can also decrease the Routers
    performance by increasing size of the soluion set to be searched.
    Decreasing this value, the minimum allowed value is 10, can increase
    Router performance by decreasing the size of the solution set to be
    searched. However, this may cause the Router to abandon viable local
    routes and produce nonoptimal short routes.
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>highway_cost_multiplier</param-name>
    <param-value>1.5</param-value>
    <!--
    <description>
    This is the amount by which to make
    highways less attractive when computing
    routes with route_preference="local".
    1.5 is a good value.
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>driving_side</param-name>
    <param-value>R</param-value>
    <!--
    <description>
    Side of the road on which drivers drive.
    R for right side and L for left side.
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>language</param-name>
    <param-value>English</param-value>
    <!--
    <description>
         Language to use to give driving directions.
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>long_ids</param-name>
    <param-value>true</param-value>
    <!--
    <description>
    If true edge and node ids are Java long datatype (8 bytes)
    otherwise they are Java integers (4 bytes)
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>distance_function_type</param-name>
    <param-value>geodetic</param-value>
    <!--
    <description>
    geodetic - Use the distance function for
    geodetic coordinate systems (e.g. SRID 8307).
    euclidean - Use the distance function for
    projected coordinate systems.
    </description>
    -->
    </init-param>
    <!-- Partitioning parameters -->
    <init-param>
    <param-name>partition_cache_size_limit</param-name>
    <param-value>125</param-value>
    <!--
    <description>
    The network partition cache can hold at
    most this many number of partitions.
    Set this based on how much memory you have.
    If partitions are already in the cache, the
    RouteServer will not have to load them from the
    database.
    WARNING: if you set this too high, you will
    run into a OutOfMemoryError.
    </description>
    -->
    </init-param>
    <init-param>
    <param-name>partition_table_name</param-name>
    <param-value>partition</param-value>
    <!--
    <description>
    Name of the partition table that contains the
    network partitions. The table is presumed
    to be contained in the schema described by
    routeserver_schema_jdbc_connect_string,
    routeserver_schema_username,
    and routeserver_schema_password parameters
    described above.
    </description>
    -->
    </init-param>
    </servlet>
    <servlet-mapping>
    <servlet-name>RouteServerServlet</servlet-name>
    <url-pattern>/routeserver</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>RouteServerServlet</servlet-name>
    <url-pattern>/servlet/RouteServerServlet</url-pattern>
    </servlet-mapping>
    <!-- Security parameters -->
    <security-constraint>
    <web-resource-collection>
    <web-resource-name>AdminPage</web-resource-name>
    <url-pattern>/admin.jsp</url-pattern>
    </web-resource-collection>
    <auth-constraint>
    <role-name>rs_admin_role</role-name>
    </auth-constraint>
    </security-constraint>
    <login-config>
    <auth-method>BASIC</auth-method>
    <realm-name>Oracle RouteServer Administration</realm-name>
    </login-config>
    <security-role>
    <description>To perform RouteServer administration.</description>
    <role-name>rs_admin_role</role-name>
    </security-role>
    </web-app>

  • Application works from NB but not from jar

    Hi,
    I'am programming a game in JAVA and this going as planned. Everything works when I run it from NetBeans, but when I execute the jar file from the console, then I get hunderds of the same exception.
    I really don't know what it is, I see a NoSuchMethod exception in the MouseEvent of the method getLocationOnScreen(), but just as i said, the app works fine without errors from out NB.
    Does somebody knows what the problem is?
    thx Sven
    java -jar Hotel.jar
    Loading board images.
    Loading image: /Images/bg-patern-hotel.jpg
    Opening file /Images/bg-patern-hotel.jpg file exisits: true -- [/Users/svenvanzoelen/NetBeansProjects/Games/Hotel/dist/Images/bg-patern-hotel.jpg]
    Loading image: /Images/Main-board-big.jpg
    Opening file /Images/Main-board-big.jpg file exisits: true -- [/Users/svenvanzoelen/NetBeansProjects/Games/Hotel/dist/Images/Main-board-big.jpg]
    Exception in thread "AWT-EventQueue-0" java.lang.NoSuchMethodError: java.awt.event.MouseEvent.getLocationOnScreen()Ljava/awt/Point;
         at Engine.GameAction.setMousePos(GameAction.java:137)
         at Engine.InputManager.mouseMoved(InputManager.java:277)
         at java.awt.Component.processMouseMotionEvent(Component.java:5647)
         at java.awt.Component.processEvent(Component.java:5371)
         at java.awt.Container.processEvent(Container.java:2010)
         at java.awt.Window.processEvent(Window.java:1184)
         at java.awt.Component.dispatchEventImpl(Component.java:4068)
         at java.awt.Container.dispatchEventImpl(Container.java:2068)
         at java.awt.Window.dispatchEventImpl(Window.java:1801)
         at java.awt.Component.dispatchEvent(Component.java:3903)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
    Same error goes 50 times more.Edited by: Svenmeister on Apr 16, 2010 7:22 AM
    Edited by: Svenmeister on Apr 16, 2010 7:22 AM

    Ok, I updated my Mac but still got the 1.5.0_22 crap so I changed the function from the mouseEvent to one that 1.5 supports.
    But now when I run the application from the console the Exception about the mouse function is gone, but I got another exception instead of it. And this one is I believe not JRE version relevant.
    The error is in the loading of the images, at the third PNG image to be precise. The images are now in total 10.8MB in size.
    So is this also a 1.6 thing? Would be awesome if someone can explain it.
    java -jar Hotel.jar Loading board images.
    Exception in thread "Image Fetcher 0" java.lang.OutOfMemoryError: Java heap space
         at java.awt.image.DataBufferInt.<init>(DataBufferInt.java:41)
         at java.awt.image.Raster.createPackedRaster(Raster.java:458)
         at java.awt.image.DirectColorModel.createCompatibleWritableRaster(DirectColorModel.java:1015)
         at sun.awt.image.ImageRepresentation.createBufferedImage(ImageRepresentation.java:223)
         at sun.awt.image.ImageRepresentation.setPixels(ImageRepresentation.java:469)
         at apple.awt.OSXImageRepresentation.setPixels(OSXImageRepresentation.java:66)
         at sun.awt.image.ImageDecoder.setPixels(ImageDecoder.java:120)
         at sun.awt.image.PNGImageDecoder.sendPixels(PNGImageDecoder.java:498)
         at sun.awt.image.PNGImageDecoder.produceImage(PNGImageDecoder.java:419)
         at sun.awt.image.InputStreamImageSource.doFetch(InputStreamImageSource.java:246)
         at sun.awt.image.ImageFetcher.fetchloop(ImageFetcher.java:172)
         at sun.awt.image.ImageFetcher.run(ImageFetcher.java:136)
    Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
         at java.awt.image.DataBufferInt.<init>(DataBufferInt.java:41)
         at java.awt.image.Raster.createPackedRaster(Raster.java:458)
         at java.awt.image.DirectColorModel.createCompatibleWritableRaster(DirectColorModel.java:1015)
         at java.awt.image.BufferedImage.<init>(BufferedImage.java:345)
         at apple.awt.CGraphicsConfig.createCompatibleImage(CGraphicsConfig.java:174)
         at GUI.Board.toBufferedImage(Board.java:1472)
         at GUI.Board.loadImages(Board.java:1143)
         at Engine.HotelMain.switchState(HotelMain.java:86)
         at Engine.HotelMain.<init>(HotelMain.java:57)
         at Engine.HotelMain.main(HotelMain.java:194)Edited by: Svenmeister on Apr 16, 2010 11:01 AM

Maybe you are looking for

  • Error when installing Premier 9 to Mac

    I am attempting to install my Adobe Premier Elements 9 from my disc (not purchased from Adobe, but from Amazon).  The computer recognizes the disc and when it begins installation it spits the disc out and shows this error message. Exit Code: 7 ------

  • Text in Wizard Windows not displayed

    Hello, for a functioning test I installed form builder 6.0.8.11.3, as downloaded from OTN. Now I found, that text displayed in wizards (for example layout-wizard) or messages is often too long for the windows, so only a part of it can be read. Is the

  • Battlefield 2142 and MAC OS X 10.5.5

    hello, Battlefield 2142 in Multiplayer mode does not connect with other Server after installing MAC OS X Update 10.5.5 When i try to update serverlist in BF nothing appears and an error occurred "check your network connection" I'm a Networkadmin and

  • How to create pf status

    hi, i want to create pf stastus for this one. SET PF-STATUS 'ALV_STATUS_01' EXCLUDING RT_EXTAB. tell me the steps 1 by 1.

  • ***Battery Replacement From Big Jugs***

    i have replaced my i phone 4s battery today now my phone is permenatly searching for a signal i9m running latest version of ios any help would be great thanks