Andrej Koelewijn

7/25/2004

The thing that irritates me most about JDeveloper

Filed under: — andrejk @ 11:58 am

It’s Applications Navigator and System navigator views are really unusable. Jdeveloper categorizes your files into folders for you, and it completely ignores the folders you’ve setup. And this causes a lot of problems for so called ‘miscellaneous files’. If you have two files with the same name, but in different folders, they’ll just be displayed in the same folder. For one project, the miscellaneous files folder under ‘Web content’ or ‘Html sources’ (depending on the view), shows all my hibernate xml mapping files, all xdoclet include files, all tld files, all xsl files. It’s a long list, maybe 100 files, all in folder.

Also, the fact that something is an html file, doesn’t mean it’s web content. It could also be documentation, which i want to see in a different folder. The fact that something is an xml file doesn’t mean it’s web content. It’s quite often a configuration file, which i also want to see in a separate folder.

If anybody knows how to make jdeveloper just show my own folders under a project, please let me know.

7/21/2004

Creating a custom tag for use with ADF data bindings

Filed under: — andrejk @ 9:16 am

Here’s how you can create custom tags that support JSTL’s expression language. This example applies to JSP 1.2. In JSP 2.0 is has become a lot easier, as JSP 2.0 already supports EL, so you don’t need JSTL for that.

I wanted to create a tag that can be used with ADF’s data bindings, for example:


<taglib1:Tag1 attr1="${bindings.TabDonorView1}" ></taglib1:Tag1>

In you tag implementation code you’ll need to import apache jstl’s ExpressionEvaluatorManager. Here’s how you can use it:


import oracle.adf.model.binding.DCControlBinding;
import org.apache.taglibs.standard.lang.support.ExpressionEvaluatorManager;
...
binding = (DCControlBinding) ExpressionEvaluatorManager.evaluate("attr1",attr1,Object.class,this,pageContext);

Using VPD with BC4J

Filed under: — andrejk @ 9:14 am

On OTN you’ll find a document outlining how to use VPD with BC4J: How To Create Secure BC4J Applications with Oracle9i VPD and Oracle 9iAS JAAS Provider.

I’ve tried the method described, but couldn’t get it to work properly. The afterConnect method is called only once, if you do not use connection pooling. I tested this by setting the max application module pool size to 1, and starting 2 browser sessions. Logging in with the first browser, afterConnect is called, setting the application context for VPD. After logging in with the second browser, afterConnect is not called as the application module already has a database connection.

You need to use afterActivation instead of afterConnect to make this work. AfterActivation is called every time an application module is activated from the pool. Now you can set your VPD context in the database before doing any work in the application module.

Update: Steve Muench has commented that it’s better to implement this using prepareSession(), instead of afterActivation().

7/17/2004

JBOSS certified

Filed under: — andrejk @ 9:18 am

According to InfoWorld Jboss has passed the J2EE certification test suite.

Oracle’s Edwin Khodabakchian on BPEL

Filed under: — andrejk @ 9:10 am

Infoworld has an interview with Oracle’s Edwin Khodabakchian on BPEL.

Accept BPEL as a first-class language, understand the tasks of the developers, and create the equivalent of the JDT [Java Development Tools] for BPEL within Eclipse. And we have the visual [tool] as well, for when the visual is important. But we never lose focus that it’s a development tool. We’re not trying to build a high-level Visio-type thing.

I think it’s a couple of years before we can deliver the Holy Grail of having more parametric processes that nontechnical people can change and configure more easily.

PHP5 new features

Filed under: — andrejk @ 9:06 am

There’s a good article on onlamp.com about some of the new features in php5: Why PHP5 Rocks!. I’ve been doing some development with php recently, and reading this list with new features makes me want to switch to php5 immediately: better mysql support, better oo implementation, better xml and soap support, exception handling, and support for tidy. The only question is, when will it be stable enough for hosting companies to start using it?

7/15/2004

First impression Oracle BPEL Process Manager

Filed under: — andrejk @ 9:13 am

On my previous post about Oracle BPEL process manager Dave Ruzius asks:

Hi, we’re also busy investigating BPEL Process Manager options. Did you perform some own testing / developing yet ? Whats your opinion on the tool and future of it within the Oracle product stack ?

Oracle BPEL process manager look really complete. It has a full implementation of BPEL 1.1, can handle user interaction through the TaskManager service. This allows you to create workflow like solutions.

The designer plugin for Eclipse makes it easy to create new BPEL processes (although you’ll still need to know about xml, xpath, xml schema’s, etc. So i think there’s still a big learning curve). Also deployment to different environments (test,development,etc) has been handled in an Ant build file, which is very developer friendly.

I also like the BPEL console, it gives you insight into a lot information about your BPEL processes and their instances. It provides statistics, so you can optimize the runtime of your processes. Also usefull is that all information in the BPEL console is also available through a Java API. I’m not sure though if the BPEL console is very usefull if you have thousends of processes running daily. Maybe then you’ll need to implement your own management console using these API’s. One point of dissapointment is that the BPEL console doesn’t work correctly in firefox, hopefully this will be fixed in the next version.

My guess is that the Oracle BPEL process manager will replace Oracle ProcessConnect and maybe Oracle Workflow, probably somewhere next year. It will take Oracle some time to integrate BPEL process manager into Application Server Integration and BPEL designer into JDeveloper.

7/12/2004

JTSL and ADF problem with complex types

Filed under: — andrejk @ 1:49 pm

I’m working on what should be a simple ADF and JSTL application, but somehow i can’t get it to work. I’ve got two javabeans, employee and address. The employee class contains it’s number, firstname and lastname and also the employee’s address.

I want to create a jsp page with a table which lists all the employees and their addresses. So every row of the table will have a column employee number, first name, last name, and columns city, zipcode, etc.

I’ve created data controls for the javabeans, so they show up in the data control palette. Next i’ve dragged and dropped the employee data control onto the jsp page as a read only table. When you do this only the simle attributes of employee are displayed in the table: employee number, firstname and lastname. The address attributes aren’t added to the table.

I’ve you look in the jsp source code, there are jstl tags to get the values for the employee columns, e.g., ${Row.firstName}, ${Row.employeeNumber}, etc.

According to the jstl syntax, if you have a javabean employee containing a javabean address, you should be able to access it in your jsp with the following syntax: ${Row.address.city}. (The Row variable is specified by the forEach tag.) This doesn’t work though. Nothing is displayed. I’ve also tried ${Row[address.city]} and ${Row[address].city}, but nothing works.

When you create a data control for a javabean, jdeveloper creates an xml file which describes the javabean. For normal attributes it contains a tag Attribute which describes the attribute. For the address attribute it creates a AccessorAttribute tag. I’ve replaced the AccessorAttribute by an Attribute tag for address, now getting the city works with the following jstl: ${Row.address.city}. The weird thing is, you’re not supposed to change the xml file describing your javabean. The file is non-editable in jdeveloper. Instead you have to edit outside of jdeveloper.

All in all this looks like a bug in adf, i’ve posted a question on the OTN jdeveloper forum, but no replies so far.

7/8/2004

Installing Oracle BPEL process manager

Filed under: — andrejk @ 4:10 pm

On page 6 of the Oracle BPEL process manager test drive guide there are links to 2 eclipse plugins: the emf/sdo plugin and the xsd plugin. These links didn’t work for me, but you can download these plugins from the XSD, EMF, SDO download page. Unzip them in your existing Eclipse (3.0 m9 and up, I tried 3.0 production) directory and then run the Oracle BPEL installer. That’s all.

Powered by WordPress