java

How firefox 3.6 accelerates the phasing out of Jinitiator (and frustrates Metalink..)

Customer using Webforms, Application Server 10.1.2.0.2 with Jinitiator on the client. Planning to upgrade the client to Java 6.17 / 6.18, so these java-versions are already installed on the clients. We’re testing the java-configuration on the web-server (formsweb.cfg), but production still works with the old Jinitiator.

Also the customer is using Firefox, 3.5 in this case, and Internet Explorer (6!). Suddenly the application does not work anymore for a lot of clients, as a matter of fact, the firefox-users.

They had upgraded their Firefox to 3.6., and got the message that an add-on must me installed ( appears to be the JRE  / Jinitiator) . After installing this, it still does not work.

The answer comes from here :  no more Java < 6.10 anymore in  Firefox 3.6 and above…. So the plans we had for upgrading JRE to Java 6.17 or 6.18, we have to accelarate these… No  more Jinitiator.

By the way: ever tried to open notes in  Metalink with Firefox 3.6 ? Does not look nice.  Following  this item at the support page of Mozilla.

By |March 15th, 2010|Categories: App. Server|Tags: , , , |0 Comments

Java-errors in 10.2.0.2 – ORA-29516 and ORA-03113

m4s0n501

Why is it that java is crossing my path so much…

After a restore of a database on another node, including renaming him/her, java classes were invalid.
Example of the source code is at the bottom of this post by the way. RDBMS 10.2.0.2 on Suse Linux 9.2.
Trying to create / replace them, errors popped up:

ORA-29516: Aurora assertion failure: Assertion failure at eox.c:317
Uncaught exception Root of all Java exceptions:
java.lang.NullPointerException

After some thoughts about the causes like the renaming, environment settings etc., decided to go for the ‘inelegant’ way, such as removing java from the database, and installing it again:

@?/javavm/install/rmjvm.sql
shutdown immediate
startup
@?/javavm/install/initjvm.sql

After that, creating the java source was no problem(!), but while compiling it got the generic error:
–> ORA-03113: end-of-file on communication channel

But then..
It appeares I was connected through sql*net.  Didn’t expect  it matters so much…
A direct connect on the server (sqlplus “/as sysdba”) and ‘alter java source BlobHandler compile; ‘ did the job.

Sample source:

create or replace java source named BlobHandler as
import java.lang.*;
import java.sql.*;
import oracle.sql.*;
import java.io.*;

public class BlobHandler {

public static void ExportBlob(String myFile, BLOB myBlob) throws Exception {
// Bind the image object to the database object
// Open streams for the output file and the blob
File binaryFile = new File(myFile);
FileOutputStream outStream = new FileOutputStream(binaryFile);
InputStream inStream = myBlob.getBinaryStream();

// Get the optimum buffer size and use this to create the read/write buffer
int size = myBlob.getBufferSize();
byte[] buffer = new byte[size];
int length = -1;

// Transfer the data
while ((length = inStream.read(buffer)) != -1) {
outStream.write(buffer, 0, length);
outStream.flush();
}

// Close everything down
inStream.close();
outStream.close();
}
};
/

alter java source BlobHandler compile;
show errors java source BlobHandler

create or replace procedure ExportBlob (p_file in varchar2, p_blob in blob)
as language java
name ‘BlobHandler.ExportBlob(java.lang.String, oracle.sql.BLOB)';
/

By |October 19th, 2009|Categories: Database|Tags: , |0 Comments

Sun JRE instead of Jinitiator: Discoverer

The whole company has to move in the end to Sun Java  instead of Jinitiator (also based on Sun Java by the way), so also the Discoverer – application.

Changed the client from Jinitatior 1.3.2 to Sun 5, update 6 (5.0.6).  You can download it here by the way.

As of this release you can no longer specify the exact JRE release. Only configure the ‘Family CLSID’.

Configure Discoverer, middle-tier:
1. cd $ORACLE_HOME/discoverer/config
2. backup configuration.xml
3. edit configuration.xml
4. comment out the original Sun JRE tag using the comment tags:
For example:
<!– <jvm name=”sun” classid=”clsid:CAFEEFAC-0014-0002-0006-ABCDEFFEDCBA” plugin_setup=”http://biserver.domain:7779/jpi/j2re.exe” version=”1.4.2″ versionie=”1,4,2,mn” type=”application/x-java-applet” plugin_page=”http://java.sun.com/products/archive/j2se/1.4.2_06/index.html” disco_archive=”disco5i.jarjar” d4o_archive=”d4o_double.jarjar”/> –>

5. Insert the new Sun JRE tag:
For example:
<jvm name=”sun” classid=”clsid:CAFEEFAC-0015-0000-FFFF-ABCDEFFEDCBA” plugin_setup=”http://biserver.domain:7779/jpi/jre5u16.exe” version=”1.5″ versionie=”1,5,0,mn” type=”application/x-java-applet” plugin_page=”http://java.sun.com/javase/downloads/index_jdk5.jsp” disco_archive=”disco5i.jarjar” d4o_archive=”d4o_double.jarjar”/>

Table of the Sun version versus the Family CLSID’s:

1.4.2     : clsid:CAFEEFAC-0014-0002-FFFF-ABCDEFFEDCBA
5.0        : clsid:CAFEEFAC-0015-0000-FFFF-ABCDEFFEDCBA
6.0        : clsid:CAFEEFAC-0016-0000-FFFF-ABCDEFFEDCBA

Oracle quote ———>:

“The behavior will be as follows:

If the user does not have any JRE installed on the client PC, then the JRE installed be what you have configured with the plugin_setup parameter; therefore, we would recommend that you stage the latest minor version within the JRE family.

* For 1.5, it will be 1.5.0_16 (http://java.sun.com/javase/downloads/index_jdk5.jsp).

This would require the Discoverer Administrator to:

* Download the latest jre family Windows executable you plan to use on the Windows clients
* copy or ftp (binary) the executable to the Discoverer middle-tier server at: $ORACLE_HOME/jpi/bin/
You may name it whatever you wish, for example: jre142u18.exe or jre150u16.exe
* Update the plugin_setup=”http://biserver.domain:7779/jpi/jre5u16.exe” (in the file configuration.xml), making sure the executable names match

”   <——— end of Oracle quote.

By |September 8th, 2009|Categories: App. Server|Tags: , , |0 Comments

The curious case of the left-handed mouse in webforms

In OAS (10.1.2.0.2), webforms, when using a left-handed mouse to expand a menu, the tree node is not expanding. No error is given.
For example, in ‘Material Workbench’ select the ‘+’ to expand ‘Organizations’ in the menu.
Left and right button does not do anything.
Also, the left handed users are having difficulties in moving screens with the mouse.

Oracle states that this is a bug (note 196844.1, bug 2200274), in Jinitiator (we are using 1.3.1.22)
Just to be sure, I installed Jinitator 1.3.1.30:  same behaviour.

Solutions
1 Install  Sun Java (5.0.6)  instead of  Jinitiator. This definitely works. Wrote another post on this matter to use Sun instead of Jinitiator.
2 Update of the (Microsoft Intellipoint) mouse-driver. Did not work for us. Problems with the mouse-driver in our environment
3 Oracle work-around in the note: use a right-handed mouse… => no comment.
4 Use the keyboard for that part of the functionality. We got unexpected results from this. At first it seems to be working, but the results didn’t match the results when we use the (right-handed) mouse. Also you have to program the ‘focus’ of the mouse or cursor in that case.

As there is no support for Jinitiator anymore, and the Intellipoint didn’t do what we expected, we’ve chosen for nr 1.

Sources:

Note: 274100.1 – Left Hand Mouse Does Not Expand Tree Node In Oracle Forms

Note: 760250.1Diagnosing Forms Mouse Focus Problems Using JRE in Release 11i

Note: 290807.1 - Deploying Sun JRE (Native Plug-in) for Windows Clients in Oracle E-Business Suite 11i

By |July 6th, 2009|Categories: App. Server|Tags: , , , |0 Comments

Creating PDF's with PL/SQL and itext

There are several ways to create PDF’s, on the client (e.g. PDFCreator) or on the middletier.
But to create PDF’s merely with packages in the database, that’s another story. Even Apex uses some Java on the middletier.
The product PLPDF on the other hand is a well known utility which provides this functionality (using open-source ‘itext’), but.. you have to pay for this.

So why not do it ourselves with itext, open-source (answer: a lot of work and knowledge of Java…).

What follows are the basics to use pl/sql in combination with ‘itext’.
1. Download itext-jar-file (itext-2.1.5.jar):

http://sourceforge.net/project/showfiles.php?group_id=15255&package_id=12596

Copy the jar-file to your database server

2. load these java-classes in the database.

grant create procedure to <owner>;
grant create table to <owner>;

loadjava -user exg/exg iText-2.1.5.jar

Some explanation about loadjava:
http://www.oracleutilities.com/OSUtil/loadjava.html

Check if it’s correctly loaded in the database:

select object_name, object_type, status
from dba_objects
where object_type like ‘%JAVA%’
and owner='<owner>’
and status <> ‘VALID’

3. A lot of Java is not valid, you need some other Java classes of ‘bouncycastle’ (encryption):

By |June 20th, 2009|Categories: Database|Tags: , , |0 Comments