Posts tagged xquery
One of my colleagues had an interesting challenge. In an Oracle Database he has a table that contains an XMLType column. The column contains XML documents with people collections. This data is retrieved and transformed inside the database using an XSLT stylesheet, to a format – for example XHTML – that can be served directly to an end user in a browser. However, the XMLType contains a country code element where the displayed data should show the name of the country. There is a lookup table that contains the country data; this table can be used to enrich the data in the XMLType. The question now was: what is the best moment in the processing pipeline (query => transform => output) to perform this enrichment. The definition of ‘best’ should include performance, scalability, programming effort and (infrastructural) complexity.
One of the options we discussed was enriching in the first stage of the pipeline, as part of the retrieval step. This would be done using an XQuery operation against the XMLType, producing another [enriched] XMLType that would be fed into the XSLT transformation. This article shows how that could be done. Using the experienced insights of my colleague Marco More >
This article accompanies an article on the Architecture section of Oracle Technology Network (OTN): Implementing the Enterprise Service Bus Pattern to Expose Database Backed Services. It provides a detailed description of the implementation of the ESB architecture design pattern – the same that is introduced in the article on OTN – using Oracle Service Bus. This OSB based implementation is in terms of structure, architecture design and functionality the replica of the pure Java based implementation described in the OTN-article. OSB adds productivity, agility and many run time administrative benefits over the pure Java solution.The challenge
The challenge the organization – let us call them Stuff Inc. – is facing is simple and common: external parties have requested access to information through Web Services. This information is held in the enterprise (Oracle) database at Stuff Inc.
The architecture team decides that the implementation of the service should be done according to the ESB architecture pattern.
Their initial implementation is based on custom Java Classes, XSLT stylesheets and JDBC calls.
After some time having worked with this initial set up, they decide to More >
While preparing for the new SOA for Java Professionals training program at AMIS, I was recently working on a section discussing XQuery and more specifically the ability to use XQuery from Java as an alternative to JAXB binding to POJOs on the one hand and DOM based XPath searches on the other.
The XQJ API for XQuery support from Java is relatively new and unknown. Implementations of the API are not yet part of Java 6 SE (I am not sure about Java 7) and the number of resources on the internet is still limited.
This article shows the steps for running a simple Java program for inspecting an RSS feed and printing titles for RSS items that concern Java. It also shows how to configure a Java application in JDeveloper 11g using the Oracle XDK implementation of XQJ.