165 lines (116 with data), 6.1 kB
2004-08-29 Jost Boekemeier <jost2345@mail.yahoo.de>
* php-java-bridge 1.0.0 released.
2004-08-30 Jost Boekemeier <jost2345@mail.yahoo.de>
* bind.c: wait until the JVM is initialized
Initialize the cfg vars correctly so that only one VM is started
* java.c, init_cfg: set the defaults _after_ the cfg changes.
* php-java-bridge 1.0.1 released.
2004-09-09 Jost Boekemeier <jost2345@mail.yahoo.de>
Initialize PVAL's so that they have a proper ref-count. Otherwise
either the bridge or the JVM might crash (or both).
* java.c: Allocate pval's correctly.
* php-java-bridge 1.0.2 released.
2004-09-10 Jost Boekemeier <jost2345@mail.yahoo.de>
* java.c: Display empty string as ''.
REL3 or RH9 running a non-NPTL kernel require to set the
environment variable LD_ASSUME_KERNEL=2.4.19 in order to run
jdk1.4 correctly.
* bind.c: Pass modified environment on to the child process.
2004-09-12 Jost Boekemeier <jost2345@mail.yahoo.de>
* README: GNU Java supported
The SUN Java implementation may store objects on the stack.
Objects on the heap may reference them. So in this JVM we cannot
simply longjmp to clear the stack, because some heap objects may
still refer to dead locations. The result would be that the VM
will barf when the GC tries to follow these phantom references.
* natcJavaBridge.c: Longjmp to the last savepoint, then return
back to java, throw an exception to return to one of the three
native main methods and then jump back to the loop. This fixes a
crash in the SUN VM which occured after apache has aborted the
connection.
* php-java-bridge 1.0.3 released.
2004-09-15 Jost Boekemeier <jost2345@mail.yahoo.de>
* JavaBridge.java: The bridge now catches errors and runtime
exceptions such as "class not found" and reports them to the
client.
2004-09-19 Jost Boekemeier <jostb@diego.intern>
Allocate pval's correctly, part II -- the previous change for 1.0.2
was incorrect: the php interpreter could not work reliable anymore if nextElement,
hashIndexUpdate or hashUpdate was called.
* client.c (nextElement, hashIndexUpdate, hashUpdate): Increment the refcount.
* php-java-bridge.spec, php-java-bridge.service, php-java-bridge:
New file.
* php.ini: Removed (now in php-java-bridge.spec).
* INSTALL, LICENSE: New file.
Starting the JVM from the web-server caused several problems.
Apache 1.3 even killed the server-part of the bridge.
* README: Recommend to start the JVM separately and to hardcode the
java.socketname.
* bind.c (java_start_server): Do not start the server part of the
bridge if the user has hardcoded the java.socketname in java.ini.
(can_fork): New function.
* natcJavaBridge.c (handle_request): If the JVM ran out of memory
do nothing, send back null-pointer.
(exit_sig): Workaround for a bug in the IBM JVM. This VM should
not hang anymore when started as a sub-process from Apache --
starting the VM as a sub-process of Apache is now deprecated
anyway.
* php-java-bridge 1.0.4 released.
2004-09-21 Jost Boekemeier <jost2345@mail.yahoo.de>
* java.c (PHP_MINIT_FUNCTION): Fixed a typo that caused a massive
memory leak on the java side of the bridge. The DeleteGlobalRef
was never called and since Java does not release the memory when
a client detaches from the VM (thanks, Sun!) the memory remained
locked until the VM ran out of memory.
* natcJavaBridge.c (Java_JavaBridge_startNative): Linux handles
accept different than the BSD variants. Check errno.
Starting java as a daemon should solve the sub-process problem.
* bind.c (java_start_server): Start java as a daemon, if possible.
(readpid): New function.
* java_bridge.c (php_java_shutdown_library): Wait for daemon
(wait_for_daemon): New function
* README: Delete the note about Apache 1.3.
Correctly shut down the connection in rshutdown
* java.c (PHP_RSHUTDOWN_FUNCTION): Delete global refs and close
file descriptors.
2004-09-23 Jost Boekemeier <jost2345@mail.yahoo.de>
Use a guard thread instead of a async signal to shutdown the server.
* natcJavaBridge.c (mutex, cond, count, block): New variables.
(exit_sig): removed
(block_sig, enter, leave, guard_requests): New functions.
(initGlobals): initialization added
(handle_requests): update thread count
(Java_JavaBridge_startNative): terminate after guard has terminated.
* README: Note about dynamic loading via dl() added.
The bridge must do its own resource tracking because php4 calls
the php_java_destructor too late (*after* rshutdown!).
* java_bridge.c (php_java_destructor): Code disabled.
* natcJavaBridge.c (enumClass, hashKeys, enumMore, enumNext): New
globals.
(initGlobals): initialization
(connection_startup, connection_cleanup): New functions.
(handle_requests, handle_request_impl, handle_request): Trace global
refs.
2004-09-26 Jost Boekemeier <jost2345@mail.yahoo.de>
* natcJavaBridge.c (Java_JavaBridge_startNative): do not restart
when signal arrived, this caused problems on some OS.
It is now possible to set the library path at run-time e.g.:
java_set_jar_library_path(";file:c:/test.jar;http://foo.com/xy.jar");
* Javabridge.java (setJarLibraryPath, load, findClass): New methods.
(CreateObject): Load classes via our own classloader.
* java.c (java_set_jar_library_path): New function.
* client.c (java_connect_to_server): Call constructor.
* sample.php: Use new function.
* java.c (java_last_exception_clear, java_last_exception_get):
Check if java is initialized.
* client.c (abort_on_error): Renamed to check_error.
* client.c (java_do_test_server): Check return value from close().
* php-java-bridge 1.0.5 released.
2004-09-27 Jost Boekemeier <jost2345@mail.yahoo.de>
* JavaBridge.java (findClass): Store the classes into a weak-value
hash so that classes don't get loaded multiple times (some JVM's
don't have a class GC).
* natcJavaBridge (handle_request, connection_cleanup): Count
the # of handles the client has aquired.
* java_bridge.c (wait_for_daemon): gcj uses the 2 internaly(!), we
must send it twice to kill it.