You can subscribe to this list here.
| 2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(6) |
Oct
(6) |
Nov
(8) |
Dec
(2) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2005 |
Jan
(19) |
Feb
(15) |
Mar
(10) |
Apr
(8) |
May
(7) |
Jun
(9) |
Jul
(13) |
Aug
(31) |
Sep
(111) |
Oct
(52) |
Nov
(72) |
Dec
(42) |
| 2006 |
Jan
(21) |
Feb
(32) |
Mar
(33) |
Apr
(24) |
May
(15) |
Jun
(40) |
Jul
(32) |
Aug
(19) |
Sep
(38) |
Oct
(37) |
Nov
(63) |
Dec
(37) |
| 2007 |
Jan
(18) |
Feb
(39) |
Mar
(69) |
Apr
(49) |
May
(71) |
Jun
(59) |
Jul
(71) |
Aug
(85) |
Sep
(46) |
Oct
(14) |
Nov
(25) |
Dec
(56) |
| 2008 |
Jan
(24) |
Feb
(77) |
Mar
(104) |
Apr
(44) |
May
(41) |
Jun
(11) |
Jul
(31) |
Aug
(59) |
Sep
(44) |
Oct
(86) |
Nov
(66) |
Dec
(93) |
| 2009 |
Jan
(88) |
Feb
(41) |
Mar
(49) |
Apr
(135) |
May
(22) |
Jun
(31) |
Jul
(60) |
Aug
(71) |
Sep
(76) |
Oct
(18) |
Nov
(52) |
Dec
(20) |
| 2010 |
Jan
(8) |
Feb
(50) |
Mar
(35) |
Apr
(48) |
May
(46) |
Jun
(84) |
Jul
(38) |
Aug
(61) |
Sep
(51) |
Oct
(31) |
Nov
(17) |
Dec
(18) |
| 2011 |
Jan
(51) |
Feb
(14) |
Mar
(17) |
Apr
(23) |
May
(15) |
Jun
(11) |
Jul
(5) |
Aug
(5) |
Sep
(15) |
Oct
(8) |
Nov
(5) |
Dec
(25) |
| 2012 |
Jan
(2) |
Feb
(4) |
Mar
(6) |
Apr
(9) |
May
(27) |
Jun
(32) |
Jul
(36) |
Aug
(10) |
Sep
(16) |
Oct
(3) |
Nov
(13) |
Dec
(7) |
| 2013 |
Jan
(1) |
Feb
(4) |
Mar
|
Apr
(1) |
May
|
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(4) |
Oct
(2) |
Nov
(1) |
Dec
|
| 2014 |
Jan
|
Feb
|
Mar
(2) |
Apr
(1) |
May
(2) |
Jun
(9) |
Jul
(5) |
Aug
(2) |
Sep
(4) |
Oct
|
Nov
|
Dec
|
| 2015 |
Jan
(3) |
Feb
(2) |
Mar
(4) |
Apr
(3) |
May
(1) |
Jun
(2) |
Jul
|
Aug
(2) |
Sep
(5) |
Oct
(1) |
Nov
|
Dec
|
| 2016 |
Jan
|
Feb
(5) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(5) |
Sep
(3) |
Oct
|
Nov
|
Dec
|
| 2017 |
Jan
(6) |
Feb
|
Mar
|
Apr
(10) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(1) |
Dec
|
| 2018 |
Jan
(2) |
Feb
(5) |
Mar
|
Apr
|
May
(1) |
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2019 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2020 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
|
| 2021 |
Jan
(5) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2023 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <php...@li...> - 2009-01-12 14:21:18
|
Hello!
=> ID now passed back is "4" instead of "3"!
Object #4 is the invocation handler, object #3 a Proxy. You have passed back the invocation handler instead of the proxy, see here:
PhpProcedure ccb = (PhpProcedure)Proxy.getInvocationHandler($ccb);
try {
cca.invoke( $cca, "invokeA", new Object[]{ ccb } );
} catch (AbortException ae) {
Peter
|
|
From: <php...@li...> - 2009-01-12 14:09:14
|
Hi,
did I understand this correctly that
$reportBody = java_values(getReportBody());
doesn't work but
$reportBody = getReportBody();
$reportBody = java_values($reportBody);
does?
If that's the case, you have found a bug in the PHP evaluator.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-12 13:37:53
|
Hi Juergen,
> public void call(Object $cca, Object $ccb) {
> cca.invoke( $cca, "invokeA", new Object[]{ ccb
> So, the PhpProcedure passed to invokeA() is a new one.
yes, obviously. ccb != $ccb. However, why is this a problem?
> (which in turn causes invokeB() to fail...)
> Did I find a bug here?
What do you mean with causes invokeB() to fail? The test case I've attached in my previous mail runs correctly, invokeB() correctly returned the string ::B, so I don't see the problem.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-11 19:34:03
|
Hi Jost,
o.k., we're coming closer:
Your proposal is about the same I had already described in the attached file of my very first email.
I've now aligned it with your example.
-----------------------------------------------------------
Java looks like:
package php.java.bridge;
import java.lang.reflect.Proxy;
import php.java.bridge.Request.AbortException;
public class Test2 {
public void call(Object $cca, Object $ccb) {
PhpProcedure cca = (PhpProcedure)Proxy.getInvocationHandler($cca);
PhpProcedure ccb = (PhpProcedure)Proxy.getInvocationHandler($ccb);
try {
cca.invoke( $cca, "invokeA", new Object[]{ ccb } );
} catch (AbortException ae) {
} catch (Throwable e) {
e.printStackTrace();
}
}
public static void main(String[] args) {
final String[] initArgs = {"LOCAL", "6", "javabridge_simple_callback.log"};
try {
(new Standalone()).init(initArgs);
} catch (Throwable t) {
t.printStackTrace();
System.exit(9);
}
}
}
-----------------------------------------------------------
PHP looks about this:
class a {
function invokeA($b) {
echo $b->invokeB();
}
}
class b {
function invokeB() {
echo "class b";
}
}
$c = new Java("php.java.bridge.Test2");
$a = java_closure(new a());
$b = java_closure(new b());
$c->call($a, $b)
-----------------------------------------------------------
If I run this then the log-file shows:
1. new Java("php.java.bridge.Test2"):
--> <C v="php.java.bridge.Test2" p="I" ></C>
<-- <O v="1" m="php.java.bridge.Test2" p="O" n="T"/>
=> $c has Java-ID="1"
2. java_closure(new a()):
--> <I v="0" m="makeClosure" p="I" />
--> <L v="2513895" p="O" />
--> </I>
<-- <O v="2" m="php.java.bridge.PhpProcedureProxy" p="O" n="T"/>
=> $a has Java-ID="2"
3. java_closure(new b()):
--> <I v="0" m="makeClosure" p="I" />
--> <L v="2513278" p="O" />
--> </I>
<-- <O v="3" m="php.java.bridge.PhpProcedureProxy" p="O" n="T"/>
=> $b has Java-ID="3"
4. call($a, $b):
--> <I v="1" m="call" p="I" />
--> <O v="2" />
--> <O v="3" />
--> </I>
=> calling the method with the correct IDs ("2" and "3")
5. invokeA():
<-- <A v="2513895" p="aW52b2tlQSgp" m="aW52b2tlQSgp" n="1"><P><O v="4" m="php.java.bridge.PhpProcedure" p="O" n="T"/></P></A>
=> ID now passed back is "4" instead of "3"!
So, the PhpProcedure passed to invokeA() is a new one.
(which in turn causes invokeB() to fail...)
Did I find a bug here?
Regards Jürgen
|
|
From: <php...@li...> - 2009-01-11 17:48:32
|
Hi Jost, Thanks for the information. I added a statement: echo java_inspect($reportBody); And this is what I saw in my output: -------------------- [class [B: Constructors: Fields: Methods: public native int java.lang.Object.hashCode() public final native java.lang.Class java.lang.Object.getClass() public final native void java.lang.Object.wait(long) throws java.lang.InterruptedException public final void java.lang.Object.wait(long,int) throws java.lang.InterruptedException public final void java.lang.Object.wait() throws java.lang.InterruptedException public boolean java.lang.Object.equals(java.lang.Object) public java.lang.String java.lang.Object.toString() public final native void java.lang.Object.notify() public final native void java.lang.Object.notifyAll() Classes: ] -------------------- To my untrained eye, that looks like the methods and fields of a plain old java object, not an array of bytes. I then just made the call to java_values explicit: $reportBody = java_values($reportBody); and the file was saved as expected. Thanks again for your help! Dan On 1/9/2009 8:15 AM, php...@li... wrote: > Hi, > >> [[o:array_of_B]:"[B@3a0b2771"] > > it is an array of class B (whatever B is) rather than a byte array or a String. Please see: > > echo java_inspect($javaObject); > > for details. > > You can convert any java object to a string using java_cast($obj, "S") provided it contains a toString() method. Please see the PHP/Java Bridge API for details: http://php-java-bridge.sourceforge.net/pjb/docs/php-api/index.html > > > Regards, > Jost Boekemeier > > > > > > > ------------------------------------------------------------------------------ > Check out the new SourceForge.net Marketplace. > It is the best place to buy or sell services for > just about anything Open Source. > http://p.sf.net/sfu/Xq1LFB > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
|
From: <php...@li...> - 2009-01-11 15:12:46
|
Hi,
I have added a new FAQ entry for this:#
<h4>What does "The requested method PUT is not allowed ... at localhost Port 80" mean?</h4>
<p>It means that <code>request.getServerPort()</code> is lying. Port 80 is privileged and therefore cannot be the servlet engine's server port.</p>
<p>If you use the AJP connector, for example via <code>ProxyPassMatch ^(/.*\.jsp)$ ajp://127.0.0.1$1</code>, set the correct <code>proxyPort</code> in <code>tomcat/conf/server.xml</code>. Example:
</p><blockquote>
<code>
<!-- Define an AJP 1.3 Connector on port 8009 --><br>
- <Connector port="8009" protocol="AJP/1.3" redirectPort="8443" /><br>
+ <Connector port="8009" protocol="AJP/1.3" proxyPort="8080" redirectPort="8443" /><br>
</code>
</blockquote>
Please see the <a href="http://127.0.0.1:8080/docs/config/ajp.html#Proxy%20Support">AJP documentation</a><a> for details.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-11 15:07:37
|
Hi,
> But I wanted to invoke a method with its name given as a
> String
Well, use the Java reflection API.
Another possibility is to re-use the PHP/Java Bridge PhpProcedure:
cca.invokeA(ccb);
is equivalent to:
((PhpProcedure)Proxy.getInvocationHandler($cca))).invoke($cca, "invokeA", new Object[]{ccb});
Note the ccb, it has been resolved using the interface IB. If you want to invoke it dynamically, too, use the same procedure as above.
This part of the PHP/Java Bridge API and implementation won't change in the future, so you may use the above code within your application.
A complete example:
package test;
import java.io.ByteArrayOutputStream;
import java.io.Closeable;
import java.io.OutputStreamWriter;
import javax.script.Invocable;
import javax.script.ScriptEngine;
import javax.script.ScriptEngineManager;
public class TestGetInterface {
/**
* @param args
*/
public static void main(String[] args) throws Throwable {
//System.setProperty("php.java.bridge.default_log_file", "");
//System.setProperty("php.java.bridge.default_log_level", "3");
new TestGetInterface().doWork();
}
private ScriptEngine scriptEngine;
String classA = "class A{function toString(){return '::A';} function invokeA($b){$b->invokeB();}}\n";
String classB = "class B{function toString(){return '::B';} function invokeB(){echo '::B';}}\n";
String test = "<?php "+classA+classB+" $thiz=java_context()->getAttribute('thiz');\n$thiz->call(java_closure(new A()), java_closure(new B())); ?>";
private void doWork() throws Throwable {
scriptEngine = new ScriptEngineManager().getEngineByName("php-invocable");
scriptEngine.put("thiz", this);
ByteArrayOutputStream out;
OutputStreamWriter writer;
scriptEngine.getContext().setWriter(writer = new OutputStreamWriter(out = new ByteArrayOutputStream()));
scriptEngine.eval(test);
((Closeable)scriptEngine).close();
writer.close();
if(!"::B".equals(out.toString())) {
System.err.println("test failed");
System.exit(1);
}
System.out.println("test okay");
System.exit(0);
}
interface IA { public void invokeA(IB ccb); };
interface IB { public void invokeB(); };
public void call(Object $cca, Object $ccb) throws Throwable {
IA cca = (IA) ((Invocable)scriptEngine).getInterface($cca, IA.class);
IB ccb = (IB) ((Invocable)scriptEngine).getInterface($ccb, IB.class);
//cca.invokeA(ccb);
((php.java.bridge.PhpProcedure)java.lang.reflect.Proxy.getInvocationHandler($cca)).invoke($cca, "invokeA", new Object[]{ccb});
}
}
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-11 12:25:38
|
Hi Jost,
thanks for your answer, but you don't seem to get what I wanted to do:
You are showing me how to call testA() on an already existing PHP
object.
But I wanted to invoke a method with its name given as a String, so:
not: A.testA(B)
but: A.invokeMethod("testA", B)
Therefore I do not see why the Java part would need to know about the
methods available on A.
The only thing it has to do is:
- find object A in PHP (formerly created with "java_closure( new A() )")
- find object B in PHP (formerly created with "java_closure( new B() )")
- tell object A to invoke a method (given as a generic String, here:
"testA") with object B as parameter.
If I look at the Javadoc of the Java script-api, it says:
/**
* Invokes a procedure on an object which already defined in the
* script using the array of objects as its arguments set.
*
* @param methodName name of the procedure to be invoked
* @param thiz object on which the procedure is called
* @param args arguments set for the procedure
* @return resultant object after the execution of the
* procedure
* @throws ScriptException if the invocation of the procedure
* fails
*/
public Object invokeMethod(Object thiz,String methodName,Object[] args)
throws
ScriptException, NoSuchMethodException;
=> That's exactly what I want to do, isn't it?
It does not say that I first have to use getInterface() in order to
proof whether "thiz" understands method "methodName".
It also doesn't say that the args are not allowed to be script proxies
as well.
So, do I still get something wrong here or is this just not supported by
the PHP-Java-bridge?
Regards Juergen
|
|
From: <php...@li...> - 2009-01-09 15:28:22
|
Hi,
> Other JAR's execute OK, why is this an OS issue?
you've said that executing pure Java code hangs your operating system. If this is so, then there's something wront with your OS. -- Maybe you expect that java -jar JavaBridge.jar starts Java as a daemon, that's not what you've asked for.
> The TestInstallation gets the JavaBridge running fine.
Good.
> Does this test need to be passed in order for the Bridge to
> work correctly, or is it OK just deploying the WAR in
> Tomcat?
Simply deploy the war file.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-09 15:21:36
|
Hi,
> We have found java_values() method fails in some cases.
> when I try to
> convert a 15 element array, it fails.
if those 15 elements exceed PHP's memory limit, it will fail, yes.
> But when I convert each element by
> calling one by one there is no problem.
This cannot happen. Do you have an example which demonstrates this behaviour?
> I think this is the bug in php-java bridge.
The bridge is more than 5 years old, so I am very certain that this is not a bug in the bridge but rather a bug in your code or in the Java VM (emulation) you use.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-09 15:15:34
|
Hi, > [[o:array_of_B]:"[B@3a0b2771"] it is an array of class B (whatever B is) rather than a byte array or a String. Please see: echo java_inspect($javaObject); for details. You can convert any java object to a string using java_cast($obj, "S") provided it contains a toString() method. Please see the PHP/Java Bridge API for details: http://php-java-bridge.sourceforge.net/pjb/docs/php-api/index.html Regards, Jost Boekemeier |
|
From: <php...@li...> - 2009-01-09 09:08:44
|
Hi,
Other JAR's execute OK, why is this an OS issue?
The TestInstallation gets the JavaBridge running fine.
Does this test need to be passed in order for the Bridge to work correctly, or is it OK just deploying the WAR in Tomcat?
regards
Re: [Php-java-bridge-users] System hangs when starting own JavaBridge.jar
From: <php-java-bridge-users@li...> - 2009-01-08 18:23
Hi,
"java -jar JavaBridge.jar SERVLET_LOCAL:8082 3 JavaBridge.log" the system hangs and the operation won't complete.
if the above command hangs your operating system, please contact your OS vendor.
Regards,
Jost Boekemeier
----- Original Message -----
From: Jonathan Pilling
To: php...@li...
Sent: Thursday, January 08, 2009 2:55 PM
Subject: Re: System hangs when starting own JavaBridge.jar
Hi,
Thanks for the reply.
Sorry, the SERVLET_LOCAL:8084 was a typo, it should have read SERVLET_LOCAL:8082.
So its not that the port isn't free. I've tried the same procedure on many ports, starting with 8084. I tried 8084, 8085, 8086, 8087, 8088, 8089, 8090 and I still get the same behaviour.
Please advise.
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hi,
> Jan 08 10:17:13 VMBridge INFO : socket : SERVLET_LOCAL:8084
> port INET_LOCAL:8082
Looks like the next free socket is 8084, not 8082. killall -9 java or use a port above 8084.
Regards,
Jost Boekemeier
----- Original Message -----
From: Jonathan Pilling
To: php...@li...
Sent: Thursday, January 08, 2009 10:26 AM
Subject: System hangs when starting own JavaBridge.jar
Hi there,
I followed these instructions from INSTALL.J2EE:
Development
* Extract the JavaBridge.jar from the JavaBridge.war zip file from the PHP/Java Bridge binary ("php-java-bridge*_j2ee.zip") download. For example with the command:
java -classpath JavaBridge.war TestInstallation
Double-click on JavaBridge.jar or type:
java -jar JavaBridge.jar
and click "OK" to start a servlet engine back end for all computers on the local network. Type:
java -jar JavaBridge.jar --help
to see the list of available options.
After running the command "java -classpath JavaBridge.war TestInstallation" I receive:
Starting a simple servlet engine: [/home/java/jre/bin/java, -jar, /home/tomcat/webapps/ext/JavaBridge.jar, SERVLET_LOCAL:8081]
Jan 08 10:08:45 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/
Jan 08 10:08:45 VMBridge INFO : VMBridge version : 5.4.2
Jan 08 10:08:45 VMBridge INFO : logFile :
Jan 08 10:08:45 VMBridge INFO : default logLevel : 3
Jan 08 10:08:45 VMBridge INFO : socket : SERVLET_LOCAL:8081
Jan 08 10:08:45 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext
Jan 08 10:08:45 VMBridge INFO : php.java.bridge.base: /root
Jan 08 10:08:45 VMBridge INFO : thread pool size : 20
Jan 08 10:08:45 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8081
Invoking php: [php-cgi, -n, -d, allow_url_include=On, /home/tomcat/webapps/test.php]
Now check the /home/tomcat/webapps/RESULT.html.
Read the INSTALL.J2EE and/or INSTALL.J2SE documents.
The RESULT.html file came out fine. Are there any particluar values I should be looking for apart from all the Java ones at the end of the RESULT.html page?
Next, I did this command "ps aux | grep JavaBridge" and saw that the bridge is running on 8081:
root 2520 0.2 7.2 312964 36792 pts/0 Sl 10:03 0:01 /home/java/jre/bin/java -jar /home/tomcat/webapps/ext/JavaBridge.jar SERVLET_LOCAL:8081
However, if I try to start my own JavaBridge.jar on 8082 using "java -jar JavaBridge.jar SERVLET_LOCAL:8082 3 JavaBridge.log" the system hangs and the operation won't complete. I receive the log which states:
Jan 08 10:17:13 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/
Jan 08 10:17:13 VMBridge INFO : VMBridge version : 5.4.2
Jan 08 10:17:13 VMBridge INFO : logFile : JavaBridge.log
Jan 08 10:17:13 VMBridge INFO : default logLevel : 5
Jan 08 10:17:13 VMBridge INFO : socket : SERVLET_LOCAL:8084
Jan 08 10:17:13 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext
Jan 08 10:17:13 VMBridge INFO : php.java.bridge.base: /root
Jan 08 10:17:13 VMBridge INFO : thread pool size : 20
Jan 08 10:17:14 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8082
Even though this says the JavaBridgeRunner started, if I do "ps aux | grep JavaBridge" I see no JavaBridge running on Port 8082, which means it has not started properly.
Please can you advise how to correct this?
Thanks.
This message has been scanned for viruses by MailControl - www.mailcontrol.com
|
|
From: <php...@li...> - 2009-01-09 04:03:06
|
Hi, We have found java_values() method fails in some cases. when I try to convert a 15 element array, it fails. But when I convert each element by calling one by one there is no problem. Then I thought there is not enough memory that is why 15 element array fails, but when I try to convert 30 element array there was no problem. Anybody can tell me what is the reason for this. I think this is the bug in php-java bridge. php-java bridge completely fails in this situation so that it can't throw an exception in this case and looks hang. This causes out http requests remain in open state and increase in memory due to increase in number of http processes and finally server down. So it is causing memory leak in our application. How can I increase memory available for JVM? I have increased it by configuring in /etc/java.sh. I am using Apache 2.3 with php-java bridge 5.2. php-java bridge is starting with Apache. I cant specify xmx value at that time. Is it possible to allocate JVM to php-java bridge explicitly. Can someone help me by giving detailed information? Also, sometimes my php-java bridge looks hang even though I allocated 2GB JVM. Thanks Sareha On Thu, Jan 8, 2009 at 7:43 PM, <php...@li... > wrote: > Hi, > > > There is memory leak > > in php - java bridge. We have the following setup: > > there is no memory leak in the PHP/Java Bridge. > > > > Is there any solution for memory leak in php-java bridge? > > Our FAQ "OutOfMemory Errors" has some hints which should help you to debug > your Java code. > > > Regards, > Jost Boekemeier > > > > > > > ------------------------------------------------------------------------------ > Check out the new SourceForge.net Marketplace. > It is the best place to buy or sell services for > just about anything Open Source. > http://p.sf.net/sfu/Xq1LFB > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users > |
|
From: <php...@li...> - 2009-01-09 01:00:17
|
Hi folks,
I am using the php-java-bridge to make some remote web services calls.
I'm using the webapp version of the bridge, and I have confirmed it is
working (by visiting localhost:8080/JavaBridge/test.php). I am running
Apache Tomcat 5.5.25 (I also tried on tomcat 5.5.17). It is an older
version of the java bridge (I don't know how to tell what version it is,
but the copyright notice only goes to 2007). This code is running on
x86_64 GNU/Linux, with PHP 5.2.6.
The web service returns a set of bytes, and then my php class needs to
write those bytes to a file (it's a PDF or jpg):
-----------------------
$reportBody = $this->retrieveReport($reportFilename);
if(strlen($reportBody) == 0) {
return "ERROR: unable to retrieve report";
}
// write file
$handle = fopen($pdfDirectory . "/" . $reportFilename,"wb");
if(fwrite($handle,$reportBody) == FALSE) {
...
}
-----------------------
Unfortunately, I'm not able to get the bytes to show up. Instead, in
the file, I get this value:
[[o:array_of_B]:"[B@3a0b2771"]
I looked around the mailing list and found this post:
http://sourceforge.net/mailarchive/message.php?msg_id=215BBBD9D2B80E4E98225471640045918A3356%40CHEXV3.CHBOSTON.ORG
which seemed to indicate I should be able to use 'java_values' to decode
this file.
Using java_values doesn't seem to help--I still see the array_of_B value.
Trying to find the length of the bytes:
error_log($reportBody->length);
causes this error:
"PHP Notice: Trying to get property of non-object "
Use a plain old string works fine:
$str = new java("java.lang.String", "hello");
error_log($str);
outputs "hello".
The same code works on another X86_64 server running Tomcat 5.5.17. The
version of JavaBridge.war is, as far as I can tell, the same (it's the
same size). The same web service is being accessed from this server.
The only difference that I can see is that the other has 'java.so'
uncommented in the php.ini file--why would that matter if I'm using the
web version of the bridge?
Any other suggestions would be appreciated. I've googled around, but
there doesn't seem to be much information regarding byte streams passed
between php and java.
Thanks,
Dan
|
|
From: <php...@li...> - 2009-01-08 18:23:59
|
Hi,
"java -jar JavaBridge.jar SERVLET_LOCAL:8082 3 JavaBridge.log" the system hangs and the operation won't complete.
if the above command hangs your operating system, please contact your OS vendor.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-08 15:07:52
|
Hi,
Thanks for the reply.
Sorry, the SERVLET_LOCAL:8084 was a typo, it should have read SERVLET_LOCAL:8082.
So its not that the port isn't free. I've tried the same procedure on many ports, starting with 8084. I tried 8084, 8085, 8086, 8087, 8088, 8089, 8090 and I still get the same behaviour.
Please advise.
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hi,
> Jan 08 10:17:13 VMBridge INFO : socket : SERVLET_LOCAL:8084
> port INET_LOCAL:8082
Looks like the next free socket is 8084, not 8082. killall -9 java or use a port above 8084.
Regards,
Jost Boekemeier
----- Original Message -----
From: Jonathan Pilling
To: php...@li...
Sent: Thursday, January 08, 2009 10:26 AM
Subject: System hangs when starting own JavaBridge.jar
Hi there,
I followed these instructions from INSTALL.J2EE:
Development
* Extract the JavaBridge.jar from the JavaBridge.war zip file from the PHP/Java Bridge binary ("php-java-bridge*_j2ee.zip") download. For example with the command:
java -classpath JavaBridge.war TestInstallation
Double-click on JavaBridge.jar or type:
java -jar JavaBridge.jar
and click "OK" to start a servlet engine back end for all computers on the local network. Type:
java -jar JavaBridge.jar --help
to see the list of available options.
After running the command "java -classpath JavaBridge.war TestInstallation" I receive:
Starting a simple servlet engine: [/home/java/jre/bin/java, -jar, /home/tomcat/webapps/ext/JavaBridge.jar, SERVLET_LOCAL:8081]
Jan 08 10:08:45 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/
Jan 08 10:08:45 VMBridge INFO : VMBridge version : 5.4.2
Jan 08 10:08:45 VMBridge INFO : logFile :
Jan 08 10:08:45 VMBridge INFO : default logLevel : 3
Jan 08 10:08:45 VMBridge INFO : socket : SERVLET_LOCAL:8081
Jan 08 10:08:45 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext
Jan 08 10:08:45 VMBridge INFO : php.java.bridge.base: /root
Jan 08 10:08:45 VMBridge INFO : thread pool size : 20
Jan 08 10:08:45 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8081
Invoking php: [php-cgi, -n, -d, allow_url_include=On, /home/tomcat/webapps/test.php]
Now check the /home/tomcat/webapps/RESULT.html.
Read the INSTALL.J2EE and/or INSTALL.J2SE documents.
The RESULT.html file came out fine. Are there any particluar values I should be looking for apart from all the Java ones at the end of the RESULT.html page?
Next, I did this command "ps aux | grep JavaBridge" and saw that the bridge is running on 8081:
root 2520 0.2 7.2 312964 36792 pts/0 Sl 10:03 0:01 /home/java/jre/bin/java -jar /home/tomcat/webapps/ext/JavaBridge.jar SERVLET_LOCAL:8081
However, if I try to start my own JavaBridge.jar on 8082 using "java -jar JavaBridge.jar SERVLET_LOCAL:8082 3 JavaBridge.log" the system hangs and the operation won't complete. I receive the log which states:
Jan 08 10:17:13 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/
Jan 08 10:17:13 VMBridge INFO : VMBridge version : 5.4.2
Jan 08 10:17:13 VMBridge INFO : logFile : JavaBridge.log
Jan 08 10:17:13 VMBridge INFO : default logLevel : 5
Jan 08 10:17:13 VMBridge INFO : socket : SERVLET_LOCAL:8084
Jan 08 10:17:13 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext
Jan 08 10:17:13 VMBridge INFO : php.java.bridge.base: /root
Jan 08 10:17:13 VMBridge INFO : thread pool size : 20
Jan 08 10:17:14 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8082
Even though this says the JavaBridgeRunner started, if I do "ps aux | grep JavaBridge" I see no JavaBridge running on Port 8082, which means it has not started properly.
Please can you advise how to correct this?
Thanks.
This message has been scanned for viruses by MailControl - www.mailcontrol.com
|
|
From: <php...@li...> - 2009-01-08 14:24:38
|
Hi, > Which installation instructions do I follow to run PHP in > the J2EE backend? Can you provide me a link to the correct > php-java bridge instructions that I need to follow? => http://php-java-bridge.sourceforge.net/pjb/installation.php Regards, Jost Boekemeier |
|
From: <php...@li...> - 2009-01-08 14:22:14
|
Hi,
> * the JavaBridge.war (renamed to "myPhpApp.war")
> should be copied into the autodeploy folder of the J2EE
> server.
If you read the overview as an install instruction, then yes, INSTALL.J2EE is too verbose.
> JSR, Excel test etc over the web. Which part of the document
> do I need to refer to for testing then?
There's only one test procedure, which requires a php-cgi in the path.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-08 14:15:35
|
Hi,
> Jan 08 10:17:13 VMBridge INFO : socket : SERVLET_LOCAL:8084
> port INET_LOCAL:8082
Looks like the next free socket is 8084, not 8082. killall -9 java or use a port above 8084.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-08 14:13:12
|
Hi,
> There is memory leak
> in php - java bridge. We have the following setup:
there is no memory leak in the PHP/Java Bridge.
> Is there any solution for memory leak in php-java bridge?
Our FAQ "OutOfMemory Errors" has some hints which should help you to debug your Java code.
Regards,
Jost Boekemeier
|
|
From: <php...@li...> - 2009-01-08 13:05:11
|
Hi, After installing java/php-java-bridge/lucene , the server became very slow especially when the number of http requests are high . There is memory leak in php - java bridge. We have the following setup: Apache 5.2, PHP 5.2, php-java bridge 5.2 Is there any solution for memory leak in php-java bridge? Thanks |
|
From: <php...@li...> - 2009-01-08 10:28:57
|
Hi there,
I followed these instructions from INSTALL.J2EE:
Development
* Extract the JavaBridge.jar from the JavaBridge.war zip file from the PHP/Java Bridge binary ("php-java-bridge*_j2ee.zip") download. For example with the command:
java -classpath JavaBridge.war TestInstallation
Double-click on JavaBridge.jar or type:
java -jar JavaBridge.jar
and click "OK" to start a servlet engine back end for all computers on the local network. Type:
java -jar JavaBridge.jar --help
to see the list of available options.
After running the command "java -classpath JavaBridge.war TestInstallation" I receive:
Starting a simple servlet engine: [/home/java/jre/bin/java, -jar, /home/tomcat/webapps/ext/JavaBridge.jar, SERVLET_LOCAL:8081]
Jan 08 10:08:45 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/
Jan 08 10:08:45 VMBridge INFO : VMBridge version : 5.4.2
Jan 08 10:08:45 VMBridge INFO : logFile :
Jan 08 10:08:45 VMBridge INFO : default logLevel : 3
Jan 08 10:08:45 VMBridge INFO : socket : SERVLET_LOCAL:8081
Jan 08 10:08:45 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext
Jan 08 10:08:45 VMBridge INFO : php.java.bridge.base: /root
Jan 08 10:08:45 VMBridge INFO : thread pool size : 20
Jan 08 10:08:45 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8081
Invoking php: [php-cgi, -n, -d, allow_url_include=On, /home/tomcat/webapps/test.php]
Now check the /home/tomcat/webapps/RESULT.html.
Read the INSTALL.J2EE and/or INSTALL.J2SE documents.
The RESULT.html file came out fine. Are there any particluar values I should be looking for apart from all the Java ones at the end of the RESULT.html page?
Next, I did this command "ps aux | grep JavaBridge" and saw that the bridge is running on 8081:
root 2520 0.2 7.2 312964 36792 pts/0 Sl 10:03 0:01 /home/java/jre/bin/java -jar /home/tomcat/webapps/ext/JavaBridge.jar SERVLET_LOCAL:8081
However, if I try to start my own JavaBridge.jar on 8082 using "java -jar JavaBridge.jar SERVLET_LOCAL:8082 3 JavaBridge.log" the system hangs and the operation won't complete. I receive the log which states:
Jan 08 10:17:13 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/
Jan 08 10:17:13 VMBridge INFO : VMBridge version : 5.4.2
Jan 08 10:17:13 VMBridge INFO : logFile : JavaBridge.log
Jan 08 10:17:13 VMBridge INFO : default logLevel : 5
Jan 08 10:17:13 VMBridge INFO : socket : SERVLET_LOCAL:8084
Jan 08 10:17:13 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext
Jan 08 10:17:13 VMBridge INFO : php.java.bridge.base: /root
Jan 08 10:17:13 VMBridge INFO : thread pool size : 20
Jan 08 10:17:14 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8082
Even though this says the JavaBridgeRunner started, if I do "ps aux | grep JavaBridge" I see no JavaBridge running on Port 8082, which means it has not started properly.
Please can you advise how to correct this?
Thanks.
This message has been scanned for viruses by MailControl - www.mailcontrol.com
|
|
From: <php...@li...> - 2009-01-08 08:52:43
|
Hi, Thanks for the reply. >> java.lang.RuntimeException: Could not run PHP ([php-cgi, -n, -d, allow_url_include=On, /home/tomcat/webapps/test.php]), please check if php-cgi is in the path. >>> The above message means that the bridge functionality could not be checked. The bridge may or may not run on your operating system. (In 99% of all cases it will run without problems, it's just that we could not verify this because PHP is not installed). But PHP is installed as FastCGI? I have been using it to test various scripts, and the config php.ini file reports that everything is running OK. I think that the error means that the system cannot find the php-cgi binary, which resides in /home/php-fcgi/bin/php-cgi. Maybe there is no system PATH set to the php-cgi binary file. Could that not be the reason for this error? Surely the system has to know where to find the binary php-cgi file for this test to work? Please advise. >>> Why do you deploy the bridge before or while testing it? Please re-read the INSTALL.J2EE document I have read that document. Do I not need to deploy the bridge for testing???? It says to do this here: The PHP/Java Bridge can be installed with one copy operation: * the JavaBridge.war (renamed to "myPhpApp.war") should be copied into the autodeploy folder of the J2EE server. So thats what I did, and tested the examples such as Hello, JSR, Excel test etc over the web. Which part of the document do I need to refer to for testing then? any help would be great. Kind regards ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- ----- Original Message ----- From: Jonathan Pilling To: php...@li... Sent: Wednesday, January 07, 2009 5:02 PM Subject: php-cgi error on bridge startup: please check if php-cgi is in the path. Hi, > java -classpath JavaBridge.war TestInstallation > java.lang.RuntimeException: Could not run PHP ([php-cgi, Please install PHP properly. A php-cgi is an integral part of a PHP installation. The above message means that the bridge functionality could not be checked. The bridge may or may not run on your operating system. (In 99% of all cases it will run without problems, it's just that we could not verify this because PHP is not installed). > However, within my Tomcat webapps folder some new files Why do you deploy the bridge before or while testing it? Please re-read the INSTALL.J2EE document. > And my Tomcat installation uses port 8080, so why does it > say the bridge starts on 8081? The test uses port 8081 because there's another server already listening on 8080. Regards, Jost Boekemeier ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Hi there, I ran this command from the terminal to test the php-java bridge installation: java -classpath JavaBridge.war TestInstallation I got the following information followed by an error: Starting a simple servlet engine: [/home/java/jre/bin/java, -jar, /home/tomcat/webapps/ext/JavaBridge.jar, SERVLET_LOCAL:8081] Jan 07 16:48:41 VMBridge INFO : VM : 1.6.0@http://www.ibm.com/ Jan 07 16:48:41 VMBridge INFO : VMBridge version : 5.4.2 Jan 07 16:48:41 VMBridge INFO : logFile : Jan 07 16:48:41 VMBridge INFO : default logLevel : 3 Jan 07 16:48:41 VMBridge INFO : socket : SERVLET_LOCAL:8081 Jan 07 16:48:41 VMBridge INFO : java.ext.dirs : /home/java/jre/lib/ext Jan 07 16:48:41 VMBridge INFO : php.java.bridge.base: /root Jan 07 16:48:41 VMBridge INFO : thread pool size : 20 Jan 07 16:48:41 VMBridge INFO : JavaBridgeRunner started on port INET_LOCAL:8081 Invoking php: [php-cgi, -n, -d, allow_url_include=On, /home/tomcat/webapps/test.php] java.lang.RuntimeException: Could not run PHP ([php-cgi, -n, -d, allow_url_include=On, /home/tomcat/webapps/test.php]), please check if php-cgi is in the path. at TestInstallation.start(TestInstallation.java:327) at TestInstallation.main(TestInstallation.java:251) Caused by: java.io.IOException: Cannot run program "php-cgi": java.io.IOException: error=2, No such file or directory at java.lang.ProcessBuilder.start(ProcessBuilder.java:470) at java.lang.Runtime.exec(Runtime.java:604) at java.lang.Runtime.exec(Runtime.java:520) at TestInstallation.start(TestInstallation.java:325) ... 1 more Caused by: java.io.IOException: java.io.IOException: error=2, No such file or directory at java.lang.UNIXProcess.<init>(UNIXProcess.java:197) at java.lang.ProcessImpl.start(ProcessImpl.java:101) at java.lang.ProcessBuilder.start(ProcessBuilder.java:463) ... 4 more However, within my Tomcat webapps folder some new files were created after I did the above. An ext/ directory containing jar files, a result.html file and a log file were created. Does the error indicate that the path to the php-cgi binary is not set? If so, how can I correct this? And my Tomcat installation uses port 8080, so why does it say the bridge starts on 8081? Kind regards This message has been scanned for viruses by MailControl - www.mailcontrol.com |
|
From: <php...@li...> - 2009-01-08 08:33:36
|
Thank you once again. >> Both modes, running PHP within Apache/IIS front-end or within a J2EE server back-end are supported. Which installation instructions do I follow to run PHP in the J2EE backend? Can you provide me a link to the correct php-java bridge instructions that I need to follow? Kind regards Jonathan Hi, > Why do I definitely need Tomcat? you need a J2EE server or a servlet engine of your choice. You can write your own J2EE server or use the test "J2EE" server built into JavaBridge.jar and ship it as part of your product, but you're responsible for this. We guarantee that the PHP/Java Bridge application works correctly on any servlet engine or J2EE server inplementing the J2EE spec >= 1.3. > Hello: function bindtextdomain not found. Please install > language support, see http://php.net for details Please see the PHP documentation for details. > The requested method PUT is not allowed for the URL mod_jk disables PUT requests. Remove mod_jk. Nobody needs it, anyway. Use mod_proxy instead. Please see our FAQ ("j2ee cluster") for details. > Are the above errors pointing to problems with my PHP-Java > Bridge installation? If so, how can I go about fixing them? It's a misunderstanding. If you really need mod_jk for tomcat on port 8080, start another tomcat on port 8081 and deploy the bridge into this one. Or configure mod_jk to not disable PUT requests. [use PHP] > as an Apache module, or as FastCGI. Which would you > recommend using? Depends on your requirements. If you want to install a cluster, use mod_proxy/balancer within the apache front end and run PHP in the J2EE back end. [FastCGI vs Apache/PHP SAPI] > Does the PHP-Java bridge work better with > one rather than the other? The SAPI doesn't matter. > IDMS <-----> JDBC <-----> Java <-----> > /BRIDGE/ <-----> PHP <-----> Web?? Both modes, running PHP within Apache/IIS front-end or within a J2EE server back-end are supported. ----- Original Message ----- From: Jonathan Pilling To: php...@li... Sent: Wednesday, January 07, 2009 3:52 PM Subject: Re: Configure bridge as a PHP Apache module or deploy into J2EE server? This is a follow up to the post: Configure bridge as a PHP Apache module or deploy into J2EE server? Thanks for the reply. I still require a little more advice if thats OK? Why do I definitely need Tomcat? Is the reason for this so that I can use JDBC -- can you explain why I need Tomcat? I have had a go at setting up the bridge myself and managed to do the following, which may or may not be correct: 1) I auto-deployed the JavaBridge.war in the tomcats webapps folder. 2) I then accessed www.mydomain.com/JavaBridge/index.php (remember that I am using mod_jk so this is accessing Tomcat's webapps folder) and ran the examples - but these scripts gave errors: Hello example gave this error Hello: function bindtextdomain not found. Please install language support, see http://php.net for details JSR 223 example2 gave this error: protocol error: Method Not Allowed The requested method PUT is not allowed for the URL /JavaBridge/jsp+php.jsp._cache_.phpjavabridge. , Internal error at col 4. Check the back end log for OutOfMemoryErrors. protocol error: Method Not Allowed The requested method PUT is not allowed for the URL /JavaBridge/jsp+php.jsp._cache_.phpjavabridge. , Internal error at col 4. Check the back end log for OutOfMemoryErrors. JSR 223 and IIS/Apache interaction example gave this error: protocol error: Method Not Allowed The requested method PUT is not allowed for the URL /JavaBridge/jsp+php2.jsp._cache_.phpjavabridge. , Internal error at col 4. Check the back end log for OutOfMemoryErrors. Could not evaluate script on IIS/Apache port 80: java.lang.IllegalArgumentException: reader must be a ScriptFileReader Are the above errors pointing to problems with my PHP-Java Bridge installation? If so, how can I go about fixing them? 3) Next I copied the JavaBridge folder to the Apache htdocs folder, and renamed it to JavaBridge2. 4) I then accessed the examples using www.mydomain.com/JavaBridge2/index.php - which points to my Apache htdocs folder. 5) Again, the same scripts gave the same errors as they did when accessing the scripts through Tomcat. 6) Next I compiled my own HelloWorld.java Java example. I did this by running the following command on the HelloWorld.java file.: - javac HelloWorld.java 7) Next I compiled the jar file using this command: - jar cvf HelloWorld.jar HelloWorld.class 8) I then created the helloworld.php file <?php require_once("java/Java.inc"); java_require('http://localhost/HelloWorld.jar'); $myObj = new Java('HelloWorld'); // display Hello World echo (String) $myObj->getHelloWorld(); ?> 9) Next I copied the HelloWorld.java, HelloWorld.class, HelloWorld.jar and helloworld.php files into the webapps/JavaBridge folder on Tomcat, and also to the htdocs/JavaBridge2 folder on Apache. When viewing the following URL's I saw the "Hello World" text in the browser, indicating that it had worked: www.mydomain.com/JavaBridge/helloworld.php www.mydomain.com/JavaBridge2/helloworld.php So does the above indicate that the PHP-Java Bridge is working as it should?? My example works fine when using PHP as an Apache module, or as FastCGI. Which would you recommend using? Does the PHP-Java bridge work better with one rather than the other? The most important question is will the way in which I have setup the PHP-Java Bridge provide the correct foundation for my proposed system i.e. will it allow me to achieve the following: IDMS <-----> JDBC <-----> Java <-----> /BRIDGE/ <-----> PHP <-----> Web?? Sorry for the huge post, i'm still getting my head around the basics. Once again, any help will be fantastic. kind regards Jonathan > > > Message: 8 > Date: Wed, 7 Jan 2009 12:00:22 -0000 > From: php...@li... > Subject: [Php-java-bridge-users] Configure bridge as a PHP Apache > module or deploy into J2EE server? > To: <php...@li...> > Message-ID: <D9991C4FC6614709BF8700521BFCB9DC@JPILLING> > Content-Type: text/plain; charset="iso-8859-1" > > Hi there, > > I am configuring a Linux server that will be eventually used as a web server. I am new to Java so some things are not clear to me, so please excuse any incorrect statements that I make. > > The idea is to connect to our IDMS database via JDBC Type 4 drivers from within a Java environment (which is installed on the Linux server), and then collect the data using Java and/or PHP through the PHP-Java Bridge, and then display the data over the web using PHP. > > I have Apache 2 configured, PHP as an Apache module and also as FastCGI, Apache mod_fastcgi, Tomcat server and the Apache mod_jk connectors. > > We want Apache 2 to handle all web requests and so we are using the mod_jk connectors to do this. i.e. if we want to view a JSP page online we can access it through www.mydomain.com/test.jsp instead of www.mydomain.com:8080/test.jsp. > > Considering our desired setup, how should I use the PHP-Java Bridge? Should I use it as an Apache PHP module, or just deploy it to the J2EE Tomcat server? > > The reason that I installed Tomcat is because I assumed it will create the JDBC connection with our IDMS database and allow PHP and Java to work together. However, I think that this may be incorrect and that all I need is Apache, PHP as an Apache module, the Java environment (SDK 6) to create the JDBC connection, and the PHP-Java Bridge as a PHP module. If we are not serving JSP pages then I can't see any need for Tomcat? Can you confirm that what I suspect is somewhat correct? > > Please advise as I'm quite confused which method to use. Any help will be much appreciated. > > Kind regards > Jonathan > > This message has been scanned for viruses by MailControl - www.mailcontrol.com > > > ------------------------------ > > Message: 9 > Date: Wed, 7 Jan 2009 14:19:39 +0000 (GMT) > From: php...@li... > Subject: Re: [Php-java-bridge-users] Configure bridge as a PHP Apache > module or deploy into J2EE server? > To: php...@li... > Message-ID: <498...@we...> > Content-Type: text/plain; charset=iso-8859-1 > > Hi, > > whether or not you intent to use JSP, you'll need tomcat anyway; although you can start a Java daemon from PHP (see http://php-java-bridge.sourceforge.net/pjb/examples/source.php?source=startJava.php), tomcat is much easier to set up and to handle than some Java daemon started from PHP. > > > Regards, > Jost B?kemeier > > > > > > > > ------------------------------ > > ------------------------------------------------------------------------------ > Check out the new SourceForge.net Marketplace. > It is the best place to buy or sell services for > just about anything Open Source. > http://p.sf.net/sfu/Xq1LFB > > ------------------------------ > > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users > > > End of php-java-bridge-users Digest, Vol 32, Issue 2 > **************************************************** |
|
From: <php...@li...> - 2009-01-07 18:46:09
|
Hi,
> java -classpath JavaBridge.war TestInstallation
> java.lang.RuntimeException: Could not run PHP ([php-cgi,
Please install PHP properly. A php-cgi is an integral part of a PHP installation.
The above message means that the bridge functionality could not be checked. The bridge may or may not run on your operating system. (In 99% of all cases it will run without problems, it's just that we could not verify this because PHP is not installed).
> However, within my Tomcat webapps folder some new files
Why do you deploy the bridge before or while testing it? Please re-read the INSTALL.J2EE document.
> And my Tomcat installation uses port 8080, so why does it
> say the bridge starts on 8081?
The test uses port 8081 because there's another server already listening on 8080.
Regards,
Jost Boekemeier
|