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-12-08 14:05:52
|
Since version 5.5.4.1 joomla and other PHP libraries crash the PHP executable. JavaBridgeTemplate5442 is okay. I think this is a regression. |
From: <php...@li...> - 2009-12-07 11:21:48
|
>From the NEWS file: Version 5.5.4.1 * The "JBoss" application server abuses the log4j port 4445 for its internal purposes. The bridge now switches off log4j "chainsaw" if getServletContext().getServerInfo().startsWith("JBoss"). * The namespace separator "_" (e.g.: new org_foo_bar_baz(...) syntax), which has been used by some projects, is available again. However, new projects should use the official namespace separator, which defaults to "\". * If the option -Dphp.java.bridge.default_log_file= is set, the bridge switches off log4j chainsaw completely. * The default value of php_include_java has been set to Off. * A configuration option has been added to the JavaBridgeTemplate.war which sets php_include_java to On. * Bugfix: If php_include_java is set, global PHP variables are no longer discarded; the PHP scripts are required from the top-level environment. => http://downloads.sourceforge.net/project/php-java-bridge/Binary%20package/php-java-bridge_5.5.4.1/JavaBridgeTemplate5541.war?use_mirror=switch Regards, Jost Bökemeier |
From: <php...@li...> - 2009-12-07 10:47:56
|
Hi, [java-code] Certificate[] chain = ks.getCertificateChain(alias); if (chain.length >= 2) { String url = PdfPKCS7.getOCSPURL(( > > X509Certificate)chain[0]); > if (url != null && url.length() > 0) > ocsp = new OcspClientBouncyCastle((X509Certificate)chain[0], > (X509Certificate)chain[1], url).getEncoded(); > } => $chain = $ks->getCertificateChain($alias); if (java_values(chain.length)) >= 2) { $url = java("...PdfPKCS7")->getOCSPURL($chain[0]); if (java_values($url) != null && java_values($url->length()) > 0) { $val = new java("...OcspClientBouncyCastle", $chain[0], $chain[1], $url); $ocsp = $val->getEncoded(); } Where exactly are the problems? You can always use echo java_inspect($jobject) to see if a Java method or procedure invocation has returned the correct result. However, it isn't possible to blindly convert a Java program to PHP. PHP has different type conversion rules for example. If you have a working java library, just add it to your web context and call it from PHP. Regards, Jost Boekemeier |
From: <php...@li...> - 2009-12-07 09:01:46
|
Thanks Jost, This solution seem to work. But I still got a lot of problems for the rest of the script like [java-code] Certificate[] chain = ks.getCertificateChain(alias); if (chain.length >= 2) { String url = PdfPKCS7.getOCSPURL((X509Certificate)chain[0]); if (url != null && url.length() > 0) ocsp = new OcspClientBouncyCastle((X509Certificate)chain[0], (X509Certificate)chain[1], url).getEncoded(); } How to create an Array of object when you don't know the size... I can't use : $Certificate = new JavaClass("java.security.cert.Certificate"); $Array = new JavaClass("java.lang.reflect.Array"); $chain = $Array->newInstance($Certificate, 10); Otherwise, do you know someone who can help me to traduce this script (http://itextpdf.sourceforge.net/howtosign.html -> How to sign with a timestamp and OCSP in Java) Best regards > Date: Thu, 3 Dec 2009 19:31:36 +0100 > To: php...@li... > From: php...@li... > Subject: Re: [Php-java-bridge-users] messageDigest and byte manipulation(2) > > Hi, > > > while (($n = $data->read($byteArray)) > 0) { > > I always got a : Maximum execution time of 60 seconds exceeded in ... > > > Yes, this is the correct behaviour. The above statement evaluates to an > endless loop. > > $data->read(...) returns a java Integer object. Any object evaluates to > true, according to the PHP type conversion rules. > > > What you probably want is: > > while (($n = java_values($data->read($byteArray))) > 0) { > ... > > Please see our API documentation at > http://php-java-bridge.sourceforge.net/pjb/docs/php-api/JavaBridge/_JavaProxy.inc.html#functionjava_valuesand > JAVA_PREFER_VALUES > http://php-java-bridge.sourceforge.net/pjb/docs/php-api/JavaBridge/_Options.inc.htmlfor > details. > > > Regards, > Jost Boekemeier > ------------------------------------------------------------------------------ > Join us December 9, 2009 for the Red Hat Virtual Experience, > a free event focused on virtualization and cloud computing. > Attend in-depth sessions from your desk. Your couch. Anywhere. > http://p.sf.net/sfu/redhat-sfdev2dev > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users _________________________________________________________________ Messenger à partir de votre boîte de réception ! Découvrez la foule d'atouts de Hotmail. http://www.microsoft.com/switzerland/windows/fr/windowslive/hotmail_bl1/hotmail_bl1.aspx |
From: <php...@li...> - 2009-12-03 18:31:49
|
Hi, > while (($n = $data->read($byteArray)) > 0) { > I always got a : Maximum execution time of 60 seconds exceeded in ... Yes, this is the correct behaviour. The above statement evaluates to an endless loop. $data->read(...) returns a java Integer object. Any object evaluates to true, according to the PHP type conversion rules. What you probably want is: while (($n = java_values($data->read($byteArray))) > 0) { ... Please see our API documentation at http://php-java-bridge.sourceforge.net/pjb/docs/php-api/JavaBridge/_JavaProxy.inc.html#functionjava_valuesand JAVA_PREFER_VALUES http://php-java-bridge.sourceforge.net/pjb/docs/php-api/JavaBridge/_Options.inc.htmlfor details. Regards, Jost Boekemeier |
From: <php...@li...> - 2009-12-03 14:04:18
|
Well, if you hit the 60seconds, you have no other chance than 1) raise the limit in php.ini 2) optimize your code what do you want to do with your code? It looks like you are trying to generate a md5 hash or something like that... php has build in support for various hashes... also your loop always transfers data back-and-forth between java and php which makes it slow.. so instead of trying to figure out, whats wrong with the code, it maybe would be better if you would tell us, what you like to achieve so we can guide you to a possible better solution. kind regards, dominik On Thu, Dec 3, 2009 at 2:28 PM, <php...@li...> wrote: > > Hi, > > > Thanks for you fast answer. > > I try again to implement the Java Array class like that (from the FAQ): > > $Byte = new JavaClass("java.lang.Byte"); > $byte = $Byte->TYPE; > $Array = new JavaClass("java.lang.reflect.Array"); > $byteArray = $Array->newInstance($byte, 8192); > > $n; > while (($n = $data->read($byteArray)) > 0) { > $messageDigest->update($byteArray, 0, $n); > echo "n= " . $n ; > } > > -> I always got a : Maximum execution time of 60 seconds exceeded in ... > > > When I try with a Php int Array like that: > > $buf = array(); > for ($i=0; $i<8192; $i++){ > $buf[$i] = '0'; > } > $n; > while (($n = $data->read($buf)) > 0) { > $messageDigest->update($buf, 0, $n); > echo "n= " . $n ; > } > > -> I receive that: n= 184n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 6259 Exception... > > Here you can find the original Java code: > > byte buf[] = new byte[8192]; > int n; > while ((n = data.read(buf)) > 0) { > messageDigest.update(buf, 0, n); > System.out.print("n=" + n); > } > > > Do you see where the problem can come from? > > Best regards Antoine > > > _________________________________________________________________ > Faites vos achats de Noël en ligne en toute sécurité : avec MSN Internet Explorer 8 surfez sûr, télécharger maintenant gratuitement ! > http://www.microsoft.ch/msnie8/fr > ------------------------------------------------------------------------------ > Join us December 9, 2009 for the Red Hat Virtual Experience, > a free event focused on virtualization and cloud computing. > Attend in-depth sessions from your desk. Your couch. Anywhere. > http://p.sf.net/sfu/redhat-sfdev2dev > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users > |
From: <php...@li...> - 2009-12-03 13:28:56
|
Hi, Thanks for you fast answer. I try again to implement the Java Array class like that (from the FAQ): $Byte = new JavaClass("java.lang.Byte"); $byte = $Byte->TYPE; $Array = new JavaClass("java.lang.reflect.Array"); $byteArray = $Array->newInstance($byte, 8192); $n; while (($n = $data->read($byteArray)) > 0) { $messageDigest->update($byteArray, 0, $n); echo "n= " . $n ; } -> I always got a : Maximum execution time of 60 seconds exceeded in ... When I try with a Php int Array like that: $buf = array(); for ($i=0; $i<8192; $i++){ $buf[$i] = '0'; } $n; while (($n = $data->read($buf)) > 0) { $messageDigest->update($buf, 0, $n); echo "n= " . $n ; } -> I receive that: n= 184n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 8192n= 6259 Exception... Here you can find the original Java code: byte buf[] = new byte[8192]; int n; while ((n = data.read(buf)) > 0) { messageDigest.update(buf, 0, n); System.out.print("n=" + n); } Do you see where the problem can come from? Best regards Antoine _________________________________________________________________ Faites vos achats de Noël en ligne en toute sécurité : avec MSN Internet Explorer 8 surfez sûr, télécharger maintenant gratuitement ! http://www.microsoft.ch/msnie8/fr |
From: <php...@li...> - 2009-12-01 21:34:27
|
Hi, take a look at the java Array class. It contains the procedures you need. Primitives like int, byte, ... are wrapped by Java classes (Integer, Byte, ...). For arrays there's a separate class which handles it: http://java.sun.com/j2se/1.4.2/docs/api/java/lang/reflect/Array.html java("java.lang.Byte")->TYPE is the type of a byte, so that java("java.lang.reflect.Array")->newInstance(java("java.lang.Byte")->TYPE, size); creates a byte[] array of type byte with a given size. Please see our FAQ section "How do I create a primitive array?" for a detailed example. Regards, Jost Boekemeier |
From: <php...@li...> - 2009-12-01 16:02:19
|
Hi all, I'm new in the java-bridge technologies and have to create a PHP script to generate and signed an PDF. My problem come from 'byte' data type. I try to find a solution in archives and FAQ but nothing works... My java source code ( from http://itextpdf.sourceforge.net/howtosign.html -> How to sign with a timestamp and OCSP in Java) has to be 'traduce' to PHP. For the rest of the page, I think I'm fine, but when i declare the buf[] and use the messageDigest.update on it, I got unexpected result... (that's why I have a System.out.print("n=" + n) for the debug ) java result: n=191n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=4525 php result: n=184n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=8192n=6260 Exception... (when i use a array of 'int' instead of 'byte') [java code] byte buf[] = new byte[8192]; int n; while ((n = data.read(buf)) > 0) { messageDigest.update(buf, 0, n); System.out.print("n=" + n); } byte hash[] = messageDigest.digest(); Calendar cal = Calendar.getInstance(); byte[] ocsp = null; if (chain.length >= 2) { String url = PdfPKCS7.getOCSPURL((X509Certificate)chain[0]); if (url != null && url.length() > 0) ocsp = new OcspClientBouncyCastle((X509Certificate)chain[0], (X509Certificate)chain[1], url).getEncoded(); } byte sh[] = sgn.getAuthenticatedAttributeBytes(hash, cal, ocsp); sgn.update(sh, 0, sh.length); byte[] encodedSig = sgn.getEncodedPKCS7(hash, cal, tsc, ocsp); if (contentEstimated + 2 < encodedSig.length) throw new Exception("Not enough space"); byte[] paddedSig = new byte[contentEstimated]; System.arraycopy(encodedSig, 0, paddedSig, 0, encodedSig.length); PdfDictionary dic2 = new PdfDictionary(); dic2.put(PdfName.CONTENTS, new PdfString(paddedSig).setHexWriting(true)); sap.close(dic2); If someone can help to 'traduce in php' this code or just explain my exactly how to produce a array[8192] of byte. Best regards Antoine _________________________________________________________________ Messenger à partir de votre boîte de réception ! Découvrez la foule d'atouts de Hotmail. http://www.microsoft.com/switzerland/windows/fr/windowslive/hotmail_bl1/hotmail_bl1.aspx |
From: <php...@li...> - 2009-11-30 18:21:20
|
> But now that it came all clear, you can set the log4j logger to listen on a > different port: > Well, I don't like configuration options; software should just work. In my opinion adding a configuration option to work around a bug in some external software component is a bad idea. I think the jboss developers are to blame, because they use a well known service end point for their internal communication purpose. I will have a look at this issue when I prepare version 5.5.4.1. In the worst case, we need to switch off chainsaw if we're running within the jboss app server or if we detect that the service listening on port 4445 is not chainsaw. Regards, Jost Boekemeier |
From: <php...@li...> - 2009-11-30 17:52:37
|
On Monday 30 November 2009, php...@li... wrote: > This port clash seems to be a common problem in jboss 4. See > http://www.thedance.net/~roth/TECHBLOG/jbossports.html > Changing the ports as suggested should solve the problem. Oh, 1000 thanks, indeed, changing the jboss default port solved the problem. > I don't think we can do anything here. We can't change the log4j standard > port and we can't change the jboss defaults. On the contrary, I'm thinking of at least a couple of things :) Even if you don't change anything, don't you think that at least it should be mentioned in the FAQ perhaps ? :) In the beginning, it wasn't clear for me that the bridge scans for the port and then uses it because the exception I pasted on my original post really doesn't help at all. But now that it came all clear, you can set the log4j logger to listen on a different port: java -Dchainsaw.port=14445 org.apache.log4j.chainsaw.Main In the same direction, does it make sense to ask for a new feature? The port that the bridge scans for, could also be configurable in the same way: -Dphp.java.bridge.default_log_port=14445 (I see that it is a static final variable in php.java.bridge.ChainsawLogger) This could eventually help your JBoss users to maintain all jboss default ports and just configure the bridge (which is the deployable). And not vice versa :) If you'd like, I could contribute this small patch. Thanks for your support! :) > Regards, > Jost Boekemeier -- Thanos Kyritsis <djart at linux.gr> |
From: <php...@li...> - 2009-11-30 13:28:48
|
This port clash seems to be a common problem in jboss 4. See http://www.thedance.net/~roth/TECHBLOG/jbossports.html Changing the ports as suggested should solve the problem. I don't think we can do anything here. We can't change the log4j standard port and we can't change the jboss defaults. Regards, Jost Boekemeier |
From: <php...@li...> - 2009-11-30 13:09:55
|
Hi, > java.net.SocketException: Connection reset yes, I've seen this bug, but I assumed it was a jboss issue. I didn't connect it to the java bridge logger until now. > 1) Starting the log4j viewer is not possible, since it uses port 4445, which is > already taken by the JBoss running instance. This explains both issues, I think. Port 4445 is the standard log4j port. The bridge scans and uses it as its log output device, if some service is listening on that port. If jboss starts another thread listening on that port, the jboss thread will get confused and the bridge will stop writing the log when it detects that its 'logger' has crashed. I will check this issue when I prepare version 5.5.4.1 (either this week or next week). Regards, Jost Boekemeier |
From: <php...@li...> - 2009-11-30 11:04:07
|
Hello, I'd like to ask for some advice when deploying the php-java bridge on JBoss 4.2.3. I'm facing 2 issues: 1) logging 2) An exception when jboss starts The exception is this one: ERROR [ServerThread] Failed to initialize java.net.SocketException: Connection reset at java.net.SocketInputStream.read(SocketInputStream.java:168) at java.io.BufferedInputStream.fill(BufferedInputStream.java:218) at java.io.BufferedInputStream.read1(BufferedInputStream.java:258) at java.io.BufferedInputStream.read(BufferedInputStream.java:317) at java.io.ObjectInputStream$PeekInputStream.read(ObjectInputStream.java:2266) at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2279) at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:2750) at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:780) at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280) at org.jboss.invocation.pooled.interfaces.OptimizedObjectInputStream.<init>(OptimizedObjectInputStream.java:147) at org.jboss.invocation.pooled.server.ServerThread.dorun(ServerThread.java:265) at org.jboss.invocation.pooled.server.ServerThread.run(ServerThread.java:156) It happens immediately after deploying JavaBridgeTemplate554.war. Another troubling fact is that sometimes (but very rarely) I don't see this exception when JBoss starts. For example, if I do 10 jboss startups, 9 times I see this exception and 1 time I don't. The second issue is the logging. The JavaBridge war somehow gets in the way and after it gets deployed it blocks any jboss console logging. I understand that this is a somewhat default behaviour as I see in the documentation, however, I'd like to solve this if possible and re-enable JBoss console logging. Is it possible ? I'm looking in README.J2EE, it mentions nothing about it, so I'm only left with the FAQ. However, the FAQ's instructions on enabling logging do not apply for a JBoss environment, because: 1) Starting the log4j viewer is not possible, since it uses port 4445, which is already taken by the JBoss running instance. 2) Using -Dphp.java.bridge.default_log_level=5 in JBoss' JAVA_OPTS makes absolutely no difference. I'm currently successfully using the php-java bridge for bridging 2 completely remote projects (that communicate with each other), one running on PHP/Apache and one running on JBoss. But, if possible, I'd like to solve these JBoss issues as well. I've exploded the JavaBridgeTemplate554.war, expecting to find some related properties files (for example log4j.properties, application properties and so), but that also didn't help. Could you please provide some help ? I'm going to use the bridge in a production environment but need these issues ironed out! :) Thanks in advance for any help. -- Thanos Kyritsis <djart at linux.gr> |
From: <php...@li...> - 2009-11-29 14:41:59
|
Thanks very much! It is working now. Cay |
From: <php...@li...> - 2009-11-27 19:43:42
|
Hello! The following WEB-INF/web.xml fixes this problem. While testing I also saw that there are some issues with Java 5 error reporting. The IOException(throwable, ...) doesn't exist in Java 5. <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd"> <web-app> <listener> <listener-class>php.java.servlet.ContextLoaderListener</listener-class> </listener> <servlet> <servlet-name>PhpJavaServlet</servlet-name> <servlet-class>php.java.servlet.PhpJavaServlet</servlet-class> </servlet> <servlet> <servlet-name>PhpCGIServlet</servlet-name> <servlet-class>php.java.servlet.PhpCGIServlet</servlet-class> <load-on-startup>0</load-on-startup> <!-- Automatically include java/JavaProxy.php --> <!-- Switch this off if you don't use Java in all of your scripts --> <!-- Default is On. --> <init-param> <param-name>php_include_java</param-name> <param-value>Off</param-value> </init-param> </servlet> <servlet-mapping> <servlet-name>PhpJavaServlet</servlet-name> <url-pattern>*.phpjavabridge</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>PhpCGIServlet</servlet-name> <url-pattern>*.php</url-pattern> </servlet-mapping> <welcome-file-list> <welcome-file>index.php</welcome-file> </welcome-file-list> </web-app> Peter |
From: <php...@li...> - 2009-11-27 08:59:47
|
Hi Mehdi, I do understand what you want. However, starting a long-running demon from a HTTP server won't work, as the demon inherits the settings from its parent. Please follow the tutorials at http://php-java-bridge.sf.net. Regards, Jost Boekemeier 27.11.2009 09:23 schrieb am <php...@li...>: Hi, First, Excuse me for my very bad english. Second, i try to explain my problem: I get the java sources and i edited the file "php.java.bridge.Standalone.java", this file started a background daemon without -Xmx java option. My application try to run BIRT reports and when I run more than 1 report, i get a JVM memory problem (looking "free" unix command I'm limited to 128. I tried to insert the Xmx option, compile and use my new jar library (with all files not only Standalone). The problem is that the daemon doesn't want to start. My question is : Is there a way to specify a default jvm memory size to allow the daemon to use 1GB ? Regards, Mehdi GUENOUNE ------------------------------------------------------------------------------ Let Crystal Reports ... |
From: <php...@li...> - 2009-11-27 08:23:15
|
Hi, First, Excuse me for my very bad english. Second, i try to explain my problem: I get the java sources and i edited the file "php.java.bridge.Standalone.java", this file started a background daemon without -Xmx java option. My application try to run BIRT reports and when I run more than 1 report, i get a JVM memory problem (looking "free" unix command I'm limited to 128. I tried to insert the Xmx option, compile and use my new jar library (with all files not only Standalone). The problem is that the daemon doesn't want to start. My question is : Is there a way to specify a default jvm memory size to allow the daemon to use 1GB ? Regards, Mehdi GUENOUNE |
From: <php...@li...> - 2009-11-26 17:13:48
|
Hi, If moodle uses the same pattern as described here ( http://sourceforge.net/mailarchive/forum.php?thread_name=3afa16cf0911150804j32fecc93p52edb3b983b6fd99%40mail.gmail.com&forum_name=php-java-bridge-users), the web.xml from JavaBridgeTemplate will evaluate the script in a non-toplevel environment. Can you please use the JavaBridge.war instead of the JavaBridgeTemplate.war and try again? Regards, Jost Boekemeier 26.11.2009 17:43 schrieb am <php...@li...>: I am trying to use the PHP/JavaBridge to run Moodle on GlassFish v3. I uncompressed Moodle and added WEB-INF/lib/JavaBridge.jar WEB-INF/lib/php-script.jar WEB-INF/lib/php-servlet.jar WEB-INF/web.xml from the PHP/JavaBridge distribution. I also added a test page test.php with contents <?php phpinfo(); ?> I use directory deployment in GlassFish. The test page comes up fine. But when I point to Moodle, I get java.lang.RuntimeException: PHP Notice: Trying to get property of non-object in /tmp/moodle/lib/componentlib.class.php on line 126 PHP Warning: require_once(/filelib.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in /tmp/moodle/lib/componentlib.class.php on line 126 PHP Fatal error: require_once() [<a href='function.require'>function.require</a>]: Failed opening required '/filelib.php' (include_path='.:/usr/share/php:/usr/share/pear') in /tmp/moodle/lib/componentlib.class.php on line 126 I don't understand why it can't filelib.php--it is in /tmp/moodle/lib. Is there anything that I am overlooking? This is the first time that I am trying to use the bridge. (FWIW, the app comes up fine under Caucho Quercus in GlassFish.) Thanks, Cay ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ php-java-bridge-users mailing list php...@li... https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
From: <php...@li...> - 2009-11-26 16:42:47
|
I am trying to use the PHP/JavaBridge to run Moodle on GlassFish v3. I uncompressed Moodle and added WEB-INF/lib/JavaBridge.jar WEB-INF/lib/php-script.jar WEB-INF/lib/php-servlet.jar WEB-INF/web.xml from the PHP/JavaBridge distribution. I also added a test page test.php with contents <?php phpinfo(); ?> I use directory deployment in GlassFish. The test page comes up fine. But when I point to Moodle, I get java.lang.RuntimeException: PHP Notice: Trying to get property of non-object in /tmp/moodle/lib/componentlib.class.php on line 126 PHP Warning: require_once(/filelib.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in /tmp/moodle/lib/componentlib.class.php on line 126 PHP Fatal error: require_once() [<a href='function.require'>function.require</a>]: Failed opening required '/filelib.php' (include_path='.:/usr/share/php:/usr/share/pear') in /tmp/moodle/lib/componentlib.class.php on line 126 I don't understand why it can't filelib.php--it is in /tmp/moodle/lib. Is there anything that I am overlooking? This is the first time that I am trying to use the bridge. (FWIW, the app comes up fine under Caucho Quercus in GlassFish.) Thanks, Cay |
From: <php...@li...> - 2009-11-26 07:16:12
|
I will be out of the office starting 11/24/2009 and will not return until 12/02/2009. I will respond to your message when I return. |
From: <php...@li...> - 2009-11-25 14:28:36
|
> What do you mean by "fetch directly from the backend"? Use the require command I have given. Please fetch Java.inc directly from the back end, use <?php require_once("http://localhost:8080/JavaBridge/java/Java.inc"); ... ?> Or make sure that the version of your Java.inc matches the version of your back end. > What's the backend here? The PHP/Java Bridge application. > can configure the path to the > PHPjavaBridge installation in a variable Which seems to be the problem here. You have probably confused the versions. Or the Java daemon you have written crashes immediately. > I'm not allowed to use a tomcat although I'd like to have it. Interesting. I thought you were running the back end as a daemon. Regards, Jost Boekemeier |
From: <php...@li...> - 2009-11-25 14:09:59
|
Thank you, Jost. What do you mean by "fetch directly from the backend"? What's the backend here? I'm using a symfony PHP framework and can configure the path to the PHPjavaBridge installation in a variable very easily. That's the $this->javabridge_root variable. It contains a path to my bridge. The java.inc is located in that directory. I'm not allowed to use a tomcat although I'd like to have it. Jost Boekemeier wrote: Hi, can you please fetch Java.inc directly from the back end (require_once(" http://localhost:8080/JavaBridge/java/Java.inc" <http://localhost:8080/JavaBridge/java/Java.inc>) to make sure that your back end version matches the version of the Java.inc library? BTW: Why don't you install tomcat to run java as a service? Regards, Jost Boekemeier Thorsten Kummer schrieb: > Hi all, > > I've set up the PHPJavaBridge standalone as a windows service to > implement lucene search capabilities in my PHP application. > After having started the Bridge with SERVLET_LOCAL:8080 the very first > call to my script fails. > Here's what I can see in my SOAP Client: > > <faultcode>SOAP-ENV:Server</faultcode> > <faultstring>Broken local connection handle fwrite() [<a > href='function.fwrite'>function.fwrite</a>]: send of 6 bytes failed > with errno=10054 Eine vorhandene Verbindung wurde vom Remotehost > geschlossen.</faultstring> > > Which means an existing connection has been closed by the remote host. > Every additional call is made with success, only the the first time > fails. I assume the call to java_autoload(..) fails the first time. > > here's my PHP function that encapsulates lucene searching: > ++++++++++++++++++++++++++++++++++++++++++++++ > public function SearchIndex ($maxrows, $searchstring) { > /** > * @desc Search in a lucene index > * */ > try { > require_once ($this->javabridge_root."/Java.inc"); > java_autoload("lucene-core-2.9.1.jar;lucene-analyzers-2.9.1.jar"); > > $analyzer = new > Java('org.apache.lucene.analysis.standard.StandardAnalyzer'); > $indexer = new > Java('org.apache.lucene.search.IndexSearcher',$this->indexfilename); > > //Lese alle indizierten Felder aus dem Index aus > $Felder_ind = > java('org.apache.lucene.index.IndexReader$FieldOption')->INDEXED; > $IndexReader = > java('org.apache.lucene.index.IndexReader')->open($this->indexfilename); > > $AlleSuchfelder=java_values($IndexReader->getFieldNames($Felder_ind)->toArray()); > > $IndexReader->close(); > > //Eine Suche über alle im Index vorhandenen Suchfelder > $parser = new > Java('org.apache.lucene.queryParser.MultiFieldQueryParser', > $AlleSuchfelder,$analyzer); > } catch (Exception $e) { > throw new Exception(utf8_encode($e)); > } > $hits = array(); try { > if ($searchstring) { > $sortfield= new > Java('org.apache.lucene.search.SortField','releasedate',3, true); > $sorter= new > Java('org.apache.lucene.search.Sort',$sortfield ); > //$sorter->setSort($sortfield); > $query = $parser->parse($searchstring); > $hits = $indexer->search($query,$sorter ); > $num=java_values($hits->length()); > > //printf("3) Hits: %d\n", $num); > if ($num < $maxrows) { > $maxrows = $num; > } > $soapreturn = array(); > for ($i = 0; $i < $maxrows; $i++) { > $found = $hits->doc($i); > $si = new SOAPSearchResult(); > $si->wiretextId = > utf8_encode($found->get('wiretextid')); > $soapreturn[] = $si; > } > } > } > catch (Exception $e) { > throw new Exception(utf8_encode($e)); > } > if(SF_ENVIRONMENT == 'soap') return $soapreturn; > } > > : > > > |
From: <php...@li...> - 2009-11-25 08:49:36
|
Hi, can you please fetch Java.inc directly from the back end (require_once(" http://localhost:8080/JavaBridge/java/Java.inc") to make sure that your back end version matches the version of the Java.inc library? BTW: Why don't you install tomcat to run java as a service? Regards, Jost Boekemeier 25.11.2009 08:26 schrieb am <php...@li...>: Hi all, I've set up the PHPJavaBridge standalone as a windows service to implement lucene search capabilities in my PHP application. After having started the Bridge with SERVLET_LOCAL:8080 the very first call to my script fails. Here's what I can see in my SOAP Client: <faultcode>SOAP-ENV:Server</faultcode> <faultstring>Broken local connection handle fwrite() [<a href='function.fwrite'>function.fwrite</a>]: send of 6 bytes failed with errno=10054 Eine vorhandene Verbindung wurde vom Remotehost geschlossen.</faultstring> Which means an existing connection has been closed by the remote host. Every additional call is made with success, only the the first time fails. I assume the call to java_autoload(..) fails the first time. here's my PHP function that encapsulates lucene searching: ++++++++++++++++++++++++++++++++++++++++++++++ public function SearchIndex ($maxrows, $searchstring) { /** * @desc Search in a lucene index * */ try { require_once ($this->javabridge_root."/Java.inc"); java_autoload("lucene-core-2.9.1.jar;lucene-analyzers-2.9.1.jar"); $analyzer = new Java('org.apache.lucene.analysis.standard.StandardAnalyzer'); $indexer = new Java('org.apache.lucene.search.IndexSearcher',$this->indexfilename); //Lese alle indizierten Felder aus dem Index aus $Felder_ind = java('org.apache.lucene.index.IndexReader$FieldOption')->INDEXED; $IndexReader = java('org.apache.lucene.index.IndexReader')->open($this->indexfilename); $AlleSuchfelder=java_values($IndexReader->getFieldNames($Felder_ind)->toArray()); $IndexReader->close(); //Eine Suche über alle im Index vorhandenen Suchfelder $parser = new Java('org.apache.lucene.queryParser.MultiFieldQueryParser', $AlleSuchfelder,$analyzer); } catch (Exception $e) { throw new Exception(utf8_encode($e)); } $hits = array(); try { if ($searchstring) { $sortfield= new Java('org.apache.lucene.search.SortField','releasedate',3, true); $sorter= new Java('org.apache.lucene.search.Sort',$sortfield ); //$sorter->setSort($sortfield); $query = $parser->parse($searchstring); $hits = $indexer->search($query,$sorter ); $num=java_values($hits->length()); //printf("3) Hits: %d\n", $num); if ($num < $maxrows) { $maxrows = $num; } $soapreturn = array(); for ($i = 0; $i < $maxrows; $i++) { $found = $hits->doc($i); $si = new SOAPSearchResult(); $si->wiretextId = utf8_encode($found->get('wiretextid')); $soapreturn[] = $si; } } } catch (Exception $e) { throw new Exception(utf8_encode($e)); } if(SF_ENVIRONMENT == 'soap') return $soapreturn; } : ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ php-java-bridge-users mailing list php...@li... https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
From: <php...@li...> - 2009-11-25 07:26:41
|
Hi all, I've set up the PHPJavaBridge standalone as a windows service to implement lucene search capabilities in my PHP application. After having started the Bridge with SERVLET_LOCAL:8080 the very first call to my script fails. Here's what I can see in my SOAP Client: <faultcode>SOAP-ENV:Server</faultcode> <faultstring>Broken local connection handle fwrite() [<a href='function.fwrite'>function.fwrite</a>]: send of 6 bytes failed with errno=10054 Eine vorhandene Verbindung wurde vom Remotehost geschlossen.</faultstring> Which means an existing connection has been closed by the remote host. Every additional call is made with success, only the the first time fails. I assume the call to java_autoload(..) fails the first time. here's my PHP function that encapsulates lucene searching: ++++++++++++++++++++++++++++++++++++++++++++++ public function SearchIndex ($maxrows, $searchstring) { /** * @desc Search in a lucene index * */ try { require_once ($this->javabridge_root."/Java.inc"); java_autoload("lucene-core-2.9.1.jar;lucene-analyzers-2.9.1.jar"); $analyzer = new Java('org.apache.lucene.analysis.standard.StandardAnalyzer'); $indexer = new Java('org.apache.lucene.search.IndexSearcher',$this->indexfilename); //Lese alle indizierten Felder aus dem Index aus $Felder_ind = java('org.apache.lucene.index.IndexReader$FieldOption')->INDEXED; $IndexReader = java('org.apache.lucene.index.IndexReader')->open($this->indexfilename); $AlleSuchfelder=java_values($IndexReader->getFieldNames($Felder_ind)->toArray()); $IndexReader->close(); //Eine Suche über alle im Index vorhandenen Suchfelder $parser = new Java('org.apache.lucene.queryParser.MultiFieldQueryParser', $AlleSuchfelder,$analyzer); } catch (Exception $e) { throw new Exception(utf8_encode($e)); } $hits = array(); try { if ($searchstring) { $sortfield= new Java('org.apache.lucene.search.SortField','releasedate',3, true); $sorter= new Java('org.apache.lucene.search.Sort',$sortfield ); //$sorter->setSort($sortfield); $query = $parser->parse($searchstring); $hits = $indexer->search($query,$sorter ); $num=java_values($hits->length()); //printf("3) Hits: %d\n", $num); if ($num < $maxrows) { $maxrows = $num; } $soapreturn = array(); for ($i = 0; $i < $maxrows; $i++) { $found = $hits->doc($i); $si = new SOAPSearchResult(); $si->wiretextId = utf8_encode($found->get('wiretextid')); $soapreturn[] = $si; } } } catch (Exception $e) { throw new Exception(utf8_encode($e)); } if(SF_ENVIRONMENT == 'soap') return $soapreturn; } : |