Re: jdk servlets on Linux

1999-04-16 Thread Kowshik Podder

Camilo Wilson wrote:
> 
> Using Apache Jserv for servlets does work, but it requires a good dose
> of masochism. Much, much easier is to use the Java Web Server from Sun
> (free evaluation, under $300), Solaris version. About 1/10 the
> configuration time, in my experience. You will need the JSDK classes
> from Sun too.

Free evaluation, but not free (in every sense of the word) and IMHO
not a better product than Apache.

If you simply want to run a small scale website with servlets, doubtless
the JWS will seem infinitely simpler to set up, but once you start
working with bigger distributed systems (processing servlets on machines
other than the server), the advantages of Apache JServ, used as a fully
distributed servlet engine, become obvious. Such features obviously
increase the complexity of the configuration, but it is really quite
logical and straightforward and by no means beyond anybody who has the
patience to read the documentation...and any sysadmin worth their salt.
IMO by no means a qualification for masochism. I may be wrong, but I
would suggest that most people who feel the way you do simply find the
whole Apache compilation process cumbersome and frustrating I would
recommend using Apache's DSO (dynamic loadable module) feature, so that
you don't have to recompile the whole of Apache every time you wish to
add a module such as JServ,
and thus makes life a lot simpler.

> We have also found Apache Jserv servlets are slower than servlets served
> by the Java Web Server on the same box. Probably due to inefficient
> communication between Apache and VM (uses sockets).

The JWS is slightly faster than Jserv at the moment, but this is rapidly
changing following discussion on the developer mailing lists - the final
release of v1.0 (currently 1.0b3) will be out very soon - and also in my
opinion such a difference is irrelevant since it is like comparing
apples with oranges - the JWS will simply allow you to run servlets on a
web server, whereas Apache Jserv enables Apache with a fully distributed
servlet engine.

Basically, the point is that Apache + JServ, gives you the best web
server combined with a powerful servlet engine that has the scalability
to handle your site as it grows, which seems to only be getting
better... together with the added advantages of free software, which in
the very least case is that it won't cost you anything!


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



JNI from JDK1.2 on Linux-2.0.36 hangs in method JNI_CreateJavaVM()

1999-04-16 Thread Marcel Ruff developer

Hi,

My little JNI HelloWorld C++ program hangs when invoking
JNI_CreateJavaVM() with following output:

>  export LD_BIND_NOW=true
>  export RTLD_NOW=true
>  invokecpp

[Opened /usr/local/jdk1.2Pre1/jre/lib/rt.jar in 29 ms]
[Opened /usr/local/jdk1.2Pre1/jre/lib/i18n.jar in 4 ms]

-> here it stays forever 

The old version, calling the JDK 1.1 interface (Blackown Java 1.1.7)
runs fine.

CAN ANYBODY PROVIDE ME  A LITTLE HELLOWORLD JNI SAMPLE CODE WHICH WORKS?

I couldnt find any example for the new JDK-2 JNI API, so perhaps im
using it wrong.


My Environment:
-
- Pentium Linux  2.0.36 with glibc
- jdk1.2pre-v1.tar from Blackdown


How i compiled it:
-
export LD_BIND_NOW=true
export RTLD_NOW=true
g++ -D_REENTRANT -I/usr/local/jdk/include -I/usr/local/jdk/include/linux
invoke.C -o invokecpp  -L/usr/local/jdk/jre/lib/i386 -ljava -L
/usr/local/jdk/jre/lib/i386/native_threads -lhpi
-L/usr/local/jdk/jre/lib/i386/classic -ljvm


How invoke.C looks like:
--
#include 

main()
{
JNIEnv *env;

  JavaVMInitArgs vm_args;
JavaVMOption options[4];

options[0].optionString = "-Djava.compiler=NONE";   /*
disable JIT */
options[1].optionString = "-Djava.class.path=.";/* user
classes */
options[2].optionString = "-Djava.library.path=.";  /* set
native library path */
options[3].optionString = "-verbose:jni,class,gc";  /* print
JNI-related messages */

vm_args.version = JNI_VERSION_1_2;
vm_args.options = options;
vm_args.nOptions = 4;
vm_args.ignoreUnrecognized = JNI_TRUE;

JavaVM *jvm;
jint res = JNI_CreateJavaVM(&jvm, (void **)&env, &vm_args);
.  here it hangs :-(


Thanks very much for any hint,

Marcel

PS: Please send answers to [EMAIL PROTECTED] as well


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



DnD to native app like kfm

1999-04-16 Thread Willi Richert

I have a serious problem.
I try to program an kfm-like app with ftp and http-file transfer
feature. But the DnD-mechanism made me stumbling: In the
javaworld-articel about dnd I read that it makes no sense to transmit
object references.
But it seems to me that it is the only possible solution: If I mark some
files in one window (e.g. currently ftp.something.com) and drag them to
a kfm window onto my local disk. Then - if I have understand it right -
I have to download it into the jvm. After that I have to create an
InputStream and pass all the data of the files in it. Then kfm will read
it. Given the lousy performance of Streams on all platforms it will be
so slow no one will use it.
Yes, there is a possibility to transmit only the filenames. But how
would kfm handle it? And thus everytime I have always two connection to
the specified ftp-server: One holds the java app to determine the
filenames, and the other has kfm to download it. Not very elegant.

If someone has a hint for me, I would be very glad,
willi



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



printing in java2

1999-04-16 Thread Justin Lawler

Hi all,

forgive me if this has been asked before as i am just new to the list.

in java 1.1.7 when you print a page, if there is any text not going
horizontaly
across the page (i.e. virtically) the text is printed at screen
resolution
and looks realy terable. The same goes for any line drawn that is not
horizontal
or vertical. My question is that does java 2 fix this limitation, and if
not is there
any plan to fix it in the near future?

Justin Lawler


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: JNI from JDK1.2 on Linux-2.0.36 hangs in method JNI_CreateJavaVM()

1999-04-16 Thread Juergen Kreileder

> Marcel Ruff developer writes:

Marcel> Hi,
Marcel> My little JNI HelloWorld C++ program hangs when invoking
Marcel> JNI_CreateJavaVM() with following output:

>> export LD_BIND_NOW=true
>> export RTLD_NOW=true
>> invokecpp
Marcel> 
Marcel> [Opened /usr/local/jdk1.2Pre1/jre/lib/rt.jar in 29 ms]
Marcel> [Opened /usr/local/jdk1.2Pre1/jre/lib/i18n.jar in 4 ms]

-> here it stays forever 

Please try again with 'export LD_PRELOAD=libpthread.so'.


Juergen

-- 
Juergen Kreileder, Universitaet Dortmund, Lehrstuhl Informatik V
Baroper Strasse 301, D-44221 Dortmund, Germany
Phone: ++49 231/755-5806, Fax: ++49 231/755-5802


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: JIT and unexpected verify errors for jdk1.2

1999-04-16 Thread Albrecht Kleine

> Dimitris Vyzovitis wrote:


> At any rate, who could answer questions concerning the linux port of sunwjit?

> PS: Hopefully tya1.3 will be out real soon, so that we don't have to depend on
> sunwjit...

OK, you won't to be depend on sunwjit, but don't expect to be faster 
than sunwjit. (Hope you are not disappointed to much.)

Any JIT will call a lot of functions residing inside the JVM. May be
some of them are not yet optimized in the first alpha release of 1.2/linux?

As mentioned, there is an early TYA1.3 running here but I have some 
heavy problems to get EXCEPTIONS_BY_SIGNALS running. A threads problem maybe. 
And BTW bug hunting is difficult because there are bugs inside the JVM 
and of course my TYA bugs. 

Why I am speaking about ``bugs inside the JVM''? Simply because sunwjit 
doesn't run using green threads. But nobody knows why ??  So I hope
the people @blackdown will release another version really soon.

BTW does anyone knows the current state of JDK1.2 for FreeBSD ?
(You know, TYA runs on FreeBSD too.)

Cheers
Albrecht
CC: [EMAIL PROTECTED]







--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: Fonts messages again

1999-04-16 Thread Matthew McKeon

Jesus Correas Fernandez wrote:
> 
> Last 03/15/1999 Kazuki Yasumatsu wrote how to fix the 'font 
> specification not found' messages. i've tried this solution step by > step, but when 
>i run
> the Stylepad demo appears:
> 
>  [75]> java Stylepad
>  Font specified in font.properties not found [-urw-zapf ]
>  Font specified in font.properties not found [-urw-zapf ]
>  Font specified in font.properties not found [-urw-zapf ]
>  Font specified in font.properties not found [-urw-zapf ]
> 
> What's wrong?
> 

If you look carefully at the fonts.properties he provided,
a few lines were wrapped in his post. 
grep through it for "zapf" and those lines 
will be readily apparent. 
Just un-wrap them and everything should be fine. 

> Thanks in advance.
> 
> Jesus.

-- 
Matthew McKeon - [EMAIL PROTECTED]
 Developer | MAYA Viz, Ltd. 
   | 2100 Wharton St.
   | Pittsburgh, PA 15203
   | 412.488.2900


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



new Linux-related RFE on the JDC

1999-04-16 Thread Matthew McKeon


Hi y'all. 
I've posted a new RFE to the Java Developer Connection
asking that Javasoft either provide a port 
of the Java Plug-In to Linux
or that they provide additional resources to Blackdown
towards that end. 
The URL is:

http://developer.javasoft.com/developer/bugParade/bugs/4229178.html

(bug ID 4229178)

Granted, bugs on the JDC don't seem to garner much attention,
however if they get lots and lots of votes (hint hint)
Javasoft might just sit up and take notice.
Please vote for it! :)

-- 
Matthew McKeon - [EMAIL PROTECTED]
 Developer | MAYA Viz, Ltd. 
   | 2100 Wharton St.
   | Pittsburgh, PA 15203
   | 412.488.2900


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Problems with the appletviewer etc

1999-04-16 Thread Mark MacRae

I'm not sure if this is strictly a Linux Java problem or what, but the
appletviewer can't find any imported classes (other than the core
library) at runtime.  My classpath is right (the applets compile,
applicaitons have no trouble, and even Netscape runs the applets -
though terrible performance as compared to what I'm used to).
Somebody must have run into this problem, please help.

Also I can't get any debugging to work properly, but maybe it's a JDE
problem, I don't know . . .

mark
[EMAIL PROTECTED]



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: JNI from JDK1.2 on Linux-2.0.36 hangs in method JNI_CreateJavaVM() - RESOLVED (THANKS)

1999-04-16 Thread Marcel Ruff developer

Juergen Kreileder wrote:

> > Marcel Ruff developer writes:
>
> Marcel> Hi,
> Marcel> My little JNI HelloWorld C++ program hangs when invoking
> Marcel> JNI_CreateJavaVM() with following output:
>
> >> export LD_BIND_NOW=true
> >> export RTLD_NOW=true
> >> invokecpp
> Marcel> 
> Marcel> [Opened /usr/local/jdk1.2Pre1/jre/lib/rt.jar in 29 ms]
> Marcel> [Opened /usr/local/jdk1.2Pre1/jre/lib/i18n.jar in 4 ms]
>
> -> here it stays forever 
>
> Please try again with 'export LD_PRELOAD=libpthread.so'.
>
> Juergen
>

That helped, it runs now fine.

Thank you for your instant help!

Solving problems in the free software world is done in minutes :-)


thanks, Marcel



--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: JNI from JDK1.2 on Linux-2.0.36 hangs in method JNI_CreateJavaVM()

1999-04-16 Thread Marcel Ruff developer

Riyad Kalla wrote:

> Wait... what is JNI? And why does all that code at the bottom look so
> complicated for "Hello World"?
>
> Thanks in advance.
>
> Riyad
>
> --
> > From: Marcel Ruff developer <[EMAIL PROTECTED]>
> > To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> > Subject: JNI from JDK1.2 on Linux-2.0.36 hangs in method
> JNI_CreateJavaVM()
> > Date: Friday, April 16, 1999 6:35 AM
> >
> > Hi,
> >
> > My little JNI HelloWorld C++ program hangs when invoking
> > JNI_CreateJavaVM() with following output:
> >
> > >  export LD_BIND_NOW=true
> > >  export RTLD_NOW=true
> > >  invokecpp
> > 
> > [Opened /usr/local/jdk1.2Pre1/jre/lib/rt.jar in 29 ms]
> > [Opened /usr/local/jdk1.2Pre1/jre/lib/i18n.jar in 4 ms]
> >
> > -> here it stays forever 
> >
> > The old version, calling the JDK 1.1 interface (Blackown Java 1.1.7)
> > runs fine.
> >
> > CAN ANYBODY PROVIDE ME  A LITTLE HELLOWORLD JNI SAMPLE CODE WHICH WORKS?
> >
> > I couldnt find any example for the new JDK-2 JNI API, so perhaps im
> > using it wrong.
> >
> >
> > My Environment:
> > -
> > - Pentium Linux  2.0.36 with glibc
> > - jdk1.2pre-v1.tar from Blackdown
> >
> >
> > How i compiled it:
> > -
> > export LD_BIND_NOW=true
> > export RTLD_NOW=true
> > g++ -D_REENTRANT -I/usr/local/jdk/include -I/usr/local/jdk/include/linux
> > invoke.C -o invokecpp  -L/usr/local/jdk/jre/lib/i386 -ljava -L
> > /usr/local/jdk/jre/lib/i386/native_threads -lhpi
> > -L/usr/local/jdk/jre/lib/i386/classic -ljvm
> >
> >
> > How invoke.C looks like:
> > --
> > #include 
> >
> > main()
> > {
> > JNIEnv *env;
> >
> >   JavaVMInitArgs vm_args;
> > JavaVMOption options[4];
> >
> > options[0].optionString = "-Djava.compiler=NONE";   /*
> > disable JIT */
> > options[1].optionString = "-Djava.class.path=.";/* user
> > classes */
> > options[2].optionString = "-Djava.library.path=.";  /* set
> > native library path */
> > options[3].optionString = "-verbose:jni,class,gc";  /* print
> > JNI-related messages */
> >
> > vm_args.version = JNI_VERSION_1_2;
> > vm_args.options = options;
> > vm_args.nOptions = 4;
> > vm_args.ignoreUnrecognized = JNI_TRUE;
> >
> > JavaVM *jvm;
> > jint res = JNI_CreateJavaVM(&jvm, (void **)&env, &vm_args);
> > .  here it hangs :-(
> >
> >
> > Thanks very much for any hint,
> >
> > Marcel
> >
> > PS: Please send answers to [EMAIL PROTECTED] as well
> >
> >
> > --
> > To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> > with a subject of "unsubscribe". Trouble? Contact
> [EMAIL PROTECTED]
> >
> 

JNI ist the nativ interface from Java, to acces C/C++ etc.

I use Java-Swing as my portable GUI toolkit for our C++ software.


Marcel


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



jdk1.2 on RedHat 5.2 (undefined symbol in libfontmanager.so)

1999-04-16 Thread Wee, Merrick

As like everyone else I can't get jdk1.2 (specifially the SwingSet
demo) to run on RedHat 5.2

I orginally got the shared lib error about libfontmanager and
libstdc++-libc.6-1.so.

I installed the egcs stuff to get the right lib (I can't find the
version that blackdown used 91.61?)

As per the readme.linux I installed the libstdc++--libc6.0-1.so.2
and then set the LD_PRELOAD to it's path and still got the following error:


-- Exception in thread "main" java.lang.UnsatisfiedLinkError:
/usr/local/src/jdk1.2/jre/lib/i386/libfontmanager.so:
/usr/local/src/jdk1.2/jre/lib/i386/libfontmanager.so: undefined symbol:
__deregister_frame_info --


Any help on this is greatly appreciated




--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: JIT and unexpected verify errors for jdk1.2

1999-04-16 Thread Nate Williams

> BTW does anyone knows the current state of JDK1.2 for FreeBSD ?
> (You know, TYA runs on FreeBSD too.)

It's a ways away.  Some progress has been made, but we're waiting for
the Linux patches to be released for some of the integration, and Steve
hasn't (yet) done that.


Nate


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Re: JIT and unexpected verify errors for jdk1.2

1999-04-16 Thread Albrecht Kleine

> > At any rate, who could answer questions concerning the linux port of sunwjit?
> 
> > PS: Hopefully tya1.3 will be out real soon, so that we don't have to depend on
> > sunwjit...
> 

> As mentioned, there is an early TYA1.3 running here but I have some 
> heavy problems to get EXCEPTIONS_BY_SIGNALS running. A threads problem maybe. 
> And BTW bug hunting is difficult because there are bugs inside the JVM 
> and of course my TYA bugs. 


In general no good idea to follow up own mails, but
for your imagination what kind of bugs I am speaking about
look at this:

public class Moo 
{
 public static void main(String args[])
 { 
  try
  {
  int M=0,o=0;
  o=o/M;
  } 
  catch (Exception )
  {
 System.out.println("catch ex "+);
  }
  try 
  {
 Thread.currentThread().sleep( 1 );
  } 
  catch (InterruptedException e)
  {
 System.out.println("main sleep interrupted");
  }
  System.out.println("END");
 }
}


Moo running jdk1.2v1a+TYA1.3/unreleased (***) gives this:

  green  native
 ==  ==
TYA compiled 
EXC_BY_SIGNALS:   hangs   okay
NO EXC_BY_S...:   okayokay
---
sunwjit   :   hangs   okay

Does a such TYA release really makes sense..?
Consider: most users would use EXC_BY_SIGNALS and green threads
as best choice. And in general it's much slower than jdk1.1+TYA.

Still interested in release ?? 

Cheers,
Albrecht
PS: 
(***) Moo running -green using sunwjit hangs too, of course.


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Keypad support with non-Redhat.

1999-04-16 Thread Christopher R. Barry

I'm running Debian and the numeric keypad 1-9 keys do not work at
all. Searching the archives I found this advice for the problem:

Adam Williams wrote:

> I upgraded from the JVM that comes with RedHat 4.2 (kaffe) to
> Blackdown's JVM (jdk1.1.6v2-libc5).  Drop and go, beautiful, better
> than my previous attempts to use thier JVM.  It seems MUCH faster
> and in some subtle way even seems to "look" better.  But now my
> numeric keypad doesn't work, it does nothing, num-lock on or off.
> [...]

Adam,

This is where these are defined on my system
/usr/X11R6/lib/X11/XKeysymDB. But make sure that you have a link to
them from here also /usr/X386/lib/X11/XKeysymDB.  If for some reason
you don't have this file (XKeysymDB) a good copy of it comes with
Netscape that you can copy over to these locations.

Hope this helps,
K.R.

On my Debian box there is no /usr/X386 directory but I have
/usr/X11R6/lib/X11/XKeysymDB and /usr/lib/X11/XKeysymDB and they are
correct.

This is really frustrating because my app is a tic-tac-toe game that
I'm writing for CS255 and the only keys I really need on the keyboard
are the 1-9 keypad ones. All other keypad keys like '0' which I don't
need actually work!

Christopher


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Can“t load javax.swing.plaf... (jdk1.2)

1999-04-16 Thread Klaus Erber

Hello,

after installing the new jdk1.2 and try to run the SimpleExample-Demo
get the following output:

ke@s10:/usr/lib/java/demo/jfc/Simple/src > java -Djava.compiler=
SimpleExample
Exception in thread "main" java.lang.Error: can't load
javax.swing.plaf.metal.MetalLookAndFeel
at
javax.swing.UIManager.initializeDefaultLAF(UIManager.java:826)
at javax.swing.UIManager.initialize(UIManager.java:896)
at javax.swing.UIManager.maybeInitialize(UIManager.java:913)
at javax.swing.UIManager.getUI(UIManager.java:535)
at javax.swing.JPanel.updateUI(JPanel.java:110)
at javax.swing.JPanel.(JPanel.java:70)
at javax.swing.JPanel.(JPanel.java:100)
at SimpleExample.(SimpleExample.java:39)
at SimpleExample.main(SimpleExample.java:135)

can anybody help me?

klaus



-- 
Klaus Erber mailto:[EMAIL PROTECTED]
maxheim wirtschaftsinformatik   http://www.mwi-online.de


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]