Re: Deadlock calling NCARG from Apache Tomcat

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Thu, 23 Oct 2008 22:28:28 -0600

On Oct 23, 2008, at 5:32 PM, Dave Allured wrote:

> Mary,
> We use Tomcat too to support our web portals. Is this an NCARG
> problem as implied by the original post, or an NCL problem?
> Also I would appreciate hearing of the final resolution if it is
> relevant to the larger community. Please post it to the list if you
> think it's appropriate. Thank you.
> --Dave


This was actually an NCL issue, not an NCAR Graphics issue. The
reference to NCAR Graphics in the original posting was because the C
program was generating a temporary NCL script to do graphics, and
hence NCAR Graphics is being used under the hood.

However, we discovered the problem was in exiting the NCL script,
regardless if graphics are being generated or not, so the problem is
not in NCAR Graphics.

I will post back here (and ncl-talk) if we do discover what the
problem is with NCL.


> Mary Haley wrote:
>> Hi folks,
>> We've been working behind the scenes on this one, and it's a
>> head-thumper.
>> As a work-around, I had Kevin add the following call before
>> the very end of his script:
>> status_exit(0)
>> This causes NCL to exist with an integer error code (which can be
>> useful if you are calling NCL from a shell script). It also,
>> apparently, causes NCL to exit from things differently than
>> just letting the script end.
>> Preliminary testing indicates that this was working for Kevin,
>> although we're both still curious why. We hope to get some
>> information
>> from a Dave Brown on this, who is out of the office until tomorrow.
>> I probably won't post any more on this, so email me separately
>> if you are having a similar issue and want to know more.
>> --Mary
>> On Mon, 13 Oct 2008, Dave Allured wrote:
>>> Kevin,
>>> Since no one else has responded about Java and Tomcat, you
>>> probably need to resort to more basic debugging methods. What
>>> version of NCAR Graphics are you running? Did you build NCARG
>>> from source, or use pre-compiled binaries? What platform and OS
>>> and version is NCARG running on, when your C program is invoked?
>>> (uname -a)
>>> Is the program set up to output to X11 or to a file format such as
>>> Postscript or PDF? What statement is executed when the program
>>> locks? Are there any error messages? Is it possible that error
>>> messages to stdout or stderr were suppressed within the Java/
>>> Tomcat environment?
>>> Dave Allured
>>> CU/CIRES Climate Diagnostics Center (CDC)
>>> NOAA/ESRL/PSD, Climate Analysis Branch (CAB)
>>> Stewart, Kevin L. (GSFC-614.5)[INOVM] wrote on 2008-sep-19:
>>>> Hey folks,
>>>> Has anyone seen a similar problem before or know where I can get
>>>> some help? I posted this a couple weeks back and didn?t see any
>>>> replies.
>>>> Kevin L. Stewart
>>>> Innovim
>>>> NASA GSFC, Code 614.5
>>>> 301-286-8385
>>>> *From:* Stewart, Kevin L. (GSFC-614.5)[INOVM]
>>>> *Sent:* Friday, August 22, 2008 4:26 PM
>>>> *To:* ''
>>>> *Subject:* Deadlock calling NCARG from Apache Tomcat
>>>> Hi, I?m brand new to this list. I?m currently working for NASA
>>>> on a small exploration project involving visualizing science data
>>>> on maps. Our main application is in Java running in the Apache
>>>> Tomcat application server but we implemented the visualization
>>>> portion in C that calls the NCAR Graphics package. The
>>>> visualization utility works find from the command line but locks
>>>> every time when we run it from Tomcat/Java. I have code in place
>>>> to read and flush the input and error buffer streams but that
>>>> didn?t fix the locking problem. As anyone else every had similar
>>>> problems between NCARG and Java or Tomcat? BTW, I?ve verified
>>>> that the NCARG_ROOT and PATH properties are defined correctly.
>>>> Kevin L. Stewart
>>>> Innovim
>>>> NASA GSFC, Code 614.5
>>>> 301-286-8385
>>> _______________________________________________
>>> ncarg-talk mailing list
>> ------------------------------------------------------------------------
>> _______________________________________________
>> ncarg-talk mailing list
> _______________________________________________
> ncarg-talk mailing list

ncarg-talk mailing list
Received on Thu Oct 23 2008 - 22:28:28 MDT

This archive was generated by hypermail 2.2.0 : Sat Nov 01 2008 - 07:16:33 MDT