---------------------------------------------------------------------------
HARBOR: http://coolharbor.100free.com/index.htm
Now Tomcat is also a cool pojo application server
---------------------------------------------------------------------------

Hi Rocco, listen I'm learning something here as well, I didnt even know Java 6 has a built in scripting engine.

I cant solve your coding problem, but I can show you how to fix it yourself.

Firstly dont worry too much about the Tomcat Native library message, that is not the cause of the problem. That is telling you that you are missing the tcnative-1.dll file, and what that does is make it run faster with sockets that work in C. I imagine you have unzipped and installed it yourself, I think if you on windows... if you get the Installer Version... then just running setup does all this stuff and gives you a windows service as well, installs the native libs and all that good stuff..... so remove that installation and do that, much easier. OR... download tcnative-1.dll yourself and install it in the one of the locations, make sure its the right one for the version you usiing... too much hassle ;)

When you install the new application make sure Netbeans is not running.

OK, so now you have the new Tomcat installed.

+ Tell netbeans to use it.... Go to TOOLS - > SERVER MANAGER and show netbeans where the new Tomcat is. LOOK at the JRE in the NB 5.17 version of TC is using, it may be pointing at your JDK, not the JRE. When you install the new TC, make sure when it asks you that you point at the same one. ie you can have JRE 5 on the machine and TC can be told to use JDK 6.... check that.

Now in your application project, if your RIGHT CLICK -> RUN you will see you can tell it to use the new TC in that application. Now when you run it, it will probably take you to the line of code that is causing the problem....
You can swap between different tomcats and experiment.

When you work in NB, you can start and stop the tomcats from the RUN tab, you can only have one running at a time. Before you deploy to the new tomcat, in NB RUN tab.... UNDEPLOY the application, and stop that TC.... because otherwise even if you drop the WAR into tomcat.... it will still look at the application in NB....

NB does not have to use the embedded TC....
Have fun....


----- Original Message ----- From: "Rocco Scappatura" <[EMAIL PROTECTED]>
To: "Tomcat Users List" <users@tomcat.apache.org>
Sent: Sunday, November 04, 2007 1:05 PM
Subject: RE: Problems with a web application running a PHP script





From: Rocco Scappatura [mailto:[EMAIL PROTECTED]
Subject: Problems with a web application running a PHP script

Under Netbeans it works. But wen deploy it under Tomcat
5.5.25 I get this error when I try to access at a PHP page:

java.lang.NoSuchMethodError:
javax.script.ScriptEngineManager.getEngineFactories()
[Ljavax/script/ScriptEngineFactory;

I cant figure out what I'm missing..

Possibly the correct JRE/JDK for Tomcat.  The above class and method
exist only in Java SE 6; what JVM are you trying to run Tomcat with?

Thanks Chunck,

I'm a newbie with Tomcat and I'm not experencied with Java programming...

Anyway, the version of Java I'm using is:

C:\Documents and Settings\rocco>java -version
java version "1.6.0_02"
Java(TM) SE Runtime Environment (build 1.6.0_02-b06)
Java HotSpot(TM) Client VM (build 1.6.0_02-b06, mixed mode)

Moreover, I have noticed that in there is an INFO in catalina logs of both
Tomcat - The one used by Netbeans (5.5.17) and the separate one installed
by me (5.5.25) - that reports the java.lib.path:

- On Tomcat 5.5.17 catalina logs: 2-nov-2007 21.38.51
org.apache.catalina.core.AprLifecycleListener lifecycleEvent
INFO: The Apache Tomcat Native library which allows optimal performance in
production environments was not found on the java.library.path:
C:\Programmi\Java\jdk1.5.0_13\bin;.;C:\WINDOWS\system32;C:\WINDOWS;C:\Perl\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Programmi\PC-Doctor
for Windows\services;C:\Programmi\QuickTime\QTSystem\;C:\Programmi\IDM
Computer
Solutions\UltraEdit-32;C:\Programmi\WinSCP\;C:\Programmi\ZipGenius
6\;C:\php5;C:\Programmi\MySQL\MySQL Server 5.0\bin

- On Tomcat 5.5.25 catalina logs: 2-nov-2007 22.03.49
org.apache.catalina.core.AprLifecycleListener lifecycleEvent
INFO: The Apache Tomcat Native library which allows optimal performance in
production environments was not found on the java.library.path:
C:\Tomcat\bin;.;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\Perl\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Programmi\PC-Doctor
for Windows\services;C:\Programmi\QuickTime\QTSystem\;C:\Programmi\IDM
Computer
Solutions\UltraEdit-32;C:\Programmi\WinSCP\;C:\Programmi\ZipGenius
6\;C:\php5;C:\Programmi\MySQL\MySQL Server 5.0\bin

Remember that on Tomcat 5.5.17 PHP works fine while on Tomcat 5.5.25 an
error occour whenever I try to access to a PHP page.

Please note that 'C:\WINDOWS\Sun\Java\bin' is an inexistent path and that
I have tried to set the correct path of java binary in PATH environment
variable but get always the same error (indeed it seemes that Tomcat has
not read the new value of PATH environment variable. Maybe do I had had to
restart my computer?).

The last question: how I have to do to take away the message " The Apache
Tomcat Native library which allows optimal performance.."?

Thanks,

rocsca


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to