<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-38586079</atom:id><lastBuildDate>Thu, 16 Jul 2009 22:43:13 +0000</lastBuildDate><title>One size doesn't fit all</title><description /><link>http://one-size-doesnt-fit-all.blogspot.com/</link><managingEditor>noreply@blogger.com (Chris Muir)</managingEditor><generator>Blogger</generator><openSearch:totalResults>234</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" href="http://feeds.feedburner.com/OneSizeDoesntFitAll" type="application/rss+xml" /><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-6035647955070793820</guid><pubDate>Tue, 14 Jul 2009 00:00:00 +0000</pubDate><atom:updated>2009-07-14T08:47:19.781+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>JDev 11gR1: the most obscure new IDE feature</title><description>Each new release of JDeveloper brings an explosion of blog posts from the excited JDeveloper advocates and Oracle staff.  Within a week or so all the major new features are identified and explained, leaving slow typers like me wondering what to cover to get readers excited.&lt;br /&gt;&lt;br /&gt;So for the latest JDeveloper 11gR1 release, I've taken the opportunity to explore for the most obscure feature, the feature hardly anybody is likely to see, or possibly even care about until they discover it.&lt;br /&gt;&lt;br /&gt;And today I think I found it.  Small celebratory "woohoo!" on my part.&lt;br /&gt;&lt;br /&gt;Take a look at this screenshot of the source code of a standard ADF Faces RC page in all its XML glory:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SlV8LDQVHNI/AAAAAAAAAwU/uf-9XX3Kitw/s1600-h/pic1.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 156px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SlV8LDQVHNI/AAAAAAAAAwU/uf-9XX3Kitw/s400/pic1.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5356323861121277138" /&gt;&lt;/a&gt;&lt;br /&gt;In the next picture I've deleted the af:inputText tag. Besides the removal of the tag, can you see the subtle change in the source code editor? Believe me you'll have to look really hard:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SlV8LcmDD_I/AAAAAAAAAwc/ULz8LH2qcL4/s1600-h/pic2.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 155px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SlV8LcmDD_I/AAAAAAAAAwc/ULz8LH2qcL4/s400/pic2.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5356323867923255282" /&gt;&lt;/a&gt;&lt;br /&gt;Spotted it? Let me point it out:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SlV8L-Y93cI/AAAAAAAAAwk/E9U0ZM218EI/s1600-h/pic3.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 155px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SlV8L-Y93cI/AAAAAAAAAwk/E9U0ZM218EI/s400/pic3.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5356323876995194306" /&gt;&lt;/a&gt;&lt;br /&gt;Can you see the little pastel pink colour in the new thin left margin that runs down the page?  If you float the mouse over the colour you get:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SlV8MJgNBeI/AAAAAAAAAws/NQ2CLIMEKro/s1600-h/pic4.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 155px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SlV8MJgNBeI/AAAAAAAAAws/NQ2CLIMEKro/s400/pic4.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5356323879978337762" /&gt;&lt;/a&gt;&lt;br /&gt;...a little popup that shows the code you deleted. The new margin feature shows visually the addition and removal of code as tied to the IDE's undo history. If you right click on the small colour segment you get a context menu that lets you work with the change:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SlV8Mds7OoI/AAAAAAAAAw0/Wh9kJ8GV99E/s1600-h/pic5.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 172px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SlV8Mds7OoI/AAAAAAAAAw0/Wh9kJ8GV99E/s400/pic5.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5356323885400406658" /&gt;&lt;/a&gt;&lt;br /&gt;As promised, I believe this to be the most obscure new feature in JDev11gR1. I set a friendly challenge to readers to find an even smaller obscure new feature in the latest release.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-6035647955070793820?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/LWPuOrxFfAw" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/LWPuOrxFfAw/jdev-11gr1-most-obscure-new-ide-feature.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/_5hhNK2aXwp8/SlV8LDQVHNI/AAAAAAAAAwU/uf-9XX3Kitw/s72-c/pic1.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/07/jdev-11gr1-most-obscure-new-ide-feature.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-6242865007391840494</guid><pubDate>Tue, 07 Jul 2009 04:08:00 +0000</pubDate><atom:updated>2009-07-07T13:33:21.593+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ADF Faces RC</category><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>Increasing/decreasing JDev 11g ADF Faces RC page font size at runtime</title><description>A feature seen on some web sites is buttons to increase and decrease the text font size.  While most browsers supply this functionality by default (eg. In Firefox you can press Ctrl plus or minus), giving web page buttons to do this can assist less computer literate users who may not now about the browser's inbuilt functions.&lt;br /&gt;&lt;br /&gt;The solution requires a javascript routine.  A quick Google on "javascript increase fontsize" returns a number of useful hits including this &lt;a href="http://www.white-hat-web-design.co.uk/articles/js-fontsize.php"&gt;one&lt;/a&gt; by White Hat Web Design.&lt;br /&gt;&lt;br /&gt;White Hat's code is a fairly common example available on the internet for doing just this in a standard web page.&lt;br /&gt;&lt;br /&gt;Providing this functionality in JDeveloper 11g's ADF Faces RC requires a bit of tweaking.  The following describes the bits of code you'll need.&lt;br /&gt;&lt;br /&gt;Javascript&lt;br /&gt;&lt;br /&gt;The following code takes the White Hat javascript and tweaks it:&lt;pre name="code" class="java"&gt;&lt;br /&gt;var fontMin=10;&lt;br /&gt;var fontMax=36;&lt;br /&gt;function increaseFontSize(event) {&lt;br /&gt;   event.cancel();&lt;br /&gt;   var p = document.getElementsByTagName('span'); // here&lt;br /&gt;   for(i=0; i &lt; p.length; i++) {&lt;br /&gt;      if(p[i].style.fontSize) {&lt;br /&gt;         var s = parseInt(p[i].style.fontSize.replace('px',''));&lt;br /&gt;      } else {&lt;br /&gt;         var s = 14;&lt;br /&gt;      }&lt;br /&gt;      if(s!=fontMax) {&lt;br /&gt;         s += 2;&lt;br /&gt;      }&lt;br /&gt;      p[i].style.fontSize = s+'px';&lt;br /&gt;   }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;function decreaseFontSize(event) {&lt;br /&gt;   event.cancel();&lt;br /&gt;   var p = document.getElementsByTagName('span'); // and here&lt;br /&gt;   for(i=0; i &lt; p.length;i++) {&lt;br /&gt;      if(p[i].style.fontSize) {&lt;br /&gt;         var s = parseInt(p[i].style.fontSize.replace('px',''));&lt;br /&gt;      } else {&lt;br /&gt;         var s = 12;&lt;br /&gt;      }&lt;br /&gt;      if(s!=fontMin) {&lt;br /&gt;         s -= 2;&lt;br /&gt;      }&lt;br /&gt;      p[i].style.fontSize = s+'px';&lt;br /&gt;   }   &lt;br /&gt;}&lt;/pre&gt;First tweaks to the original code, note that each method now takes an event object, and then cancels the event on executing the javascript.  While I'm not entirely over the need for this, my understanding is it hooks into the ADF Faces RC javascript engine and we'll see a bit further down in this post the usage of the clientListener tags to invoke this javascript.  (Some more documentation on the ADF javascript engine would be appreciated Oracle – hint hint).&lt;br /&gt;&lt;br /&gt;Secondly note the two commented lines. The original code searched for &amp;lt;p&gt; tags, while in ADF Faces RC pages we need to search for &amp;lt;span&gt; tags, as this is where ADF Faces RC places raw text.&lt;br /&gt;&lt;br /&gt;Load the javascript into JSF&lt;br /&gt;&lt;br /&gt;In the page we wish to include the javascript we include the following code:&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;trh:script source="js/fonts.js"/&gt;&lt;br /&gt;&lt;/pre&gt;...assuming you stored the above javascript in the ViewController public_html/js subdirectory as fonts.js.&lt;br /&gt;&lt;br /&gt;(Alternatively this tag could go into your JSF template so you only need to include it once)&lt;br /&gt;&lt;br /&gt;Note that this is in fact a Apache Trinidad component, not ADF Faces RC.  As such you also need to change your JSF page's &amp;lt;jsp:root&gt; tag to include the Trinidad HTML tag library as follows:&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;jsp:root&lt;br /&gt;  xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1" &lt;br /&gt;  xmlns:f="http://java.sun.com/jsf/core"&lt;br /&gt;  xmlns:h="http://java.sun.com/jsf/html"   &lt;br /&gt;  xmlns:af="http://xmlns.oracle.com/adf/faces/rich"&lt;br /&gt;  xmlns:trh="http://myfaces.apache.org/trinidad/html"&gt;&lt;br /&gt;&lt;/pre&gt;Buttons&lt;br /&gt;&lt;br /&gt;Next in order to provide buttons to call the javascript we include the following command controls on our page:&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;af:commandLink text="Smaller"&gt;&lt;br /&gt;  &lt;af:clientListener method="decreaseFontSize" type="action"/&gt;&lt;br /&gt;&lt;/af:commandLink&gt;&lt;br /&gt;&lt;af:commandLink text="Larger"&gt;&lt;br /&gt;  &lt;af:clientListener method="increaseFontSize" type="action"/&gt;&lt;br /&gt;&lt;/af:commandLink&gt;&lt;br /&gt;&lt;/pre&gt;Note the use of the clientListener tag to invoke the javascript functions we defined above.&lt;br /&gt;&lt;br /&gt;Near success&lt;br /&gt;&lt;br /&gt;At this point if you run your page you should see the fonts scale up and down when you press the relevant commandLink button.&lt;br /&gt;&lt;br /&gt;One thing you may notice is that if you have other text based command and go components on the page (eg. &amp;lt;af:commandLink&gt; &amp;lt;goLink&gt;), the text fails to grow or shrink on pressing your new buttons.  This occurs because the command and go components are rendered in a HTML &amp;lt; href&gt; tag rather than the &amp;lt;span&gt; tag we coded in our javascript. An easy solution to this is to modify your components as follows:&lt;br /&gt;&lt;br /&gt;Original&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;af:commandLink text="Do something really important"/&gt;&lt;br /&gt;&lt;/pre&gt;Fix&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;af:commandLink&gt;&lt;br /&gt;  &lt;af:outputText value="Do something really important" noWrap="true"/&gt;&lt;br /&gt;&lt;/af:commandLink&gt;&lt;br /&gt;&lt;/pre&gt;As the command control now uses a normal outputText component to render the text, this in turn is rendered as a HTML &amp;lt;span&gt; tag in the end HTML page and will be subject to our javascript routines results.&lt;br /&gt;&lt;br /&gt;One other thing you might notice, is in Firefox the font fails to shrink at all.  Remember that Firefox has a user preference that stops this from occurring under Tools -&gt; Options -&gt; Content -&gt; Fonts &amp;amp; Colours -&gt; Advanced -&gt; Minimum Font Size, a particularly useful feature on my laptop that runs at 1 sqwillion by 1 sqwillion resolution, where I can't see a d@mned thing.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-6242865007391840494?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/5ad_syAPiAo" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/5ad_syAPiAo/increasingdecreasing-jdev-11g-adf-faces.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/06/increasingdecreasing-jdev-11g-adf-faces.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-1851942676275633568</guid><pubDate>Tue, 30 Jun 2009 21:50:00 +0000</pubDate><atom:updated>2009-07-01T06:03:14.001+08:00</atom:updated><title>Oracle ACE Director of the Year</title><description>I had the very pleasent surprise at the end of the ODTUG conference this year to be told that I've won Oracle Magazine's Oracle ACE Director of the Year award for 2009.  With out a doubt this is an honour and I'm very appreciative to Oracle Corporation and its staff for this award, and especially to those who were kind enough to nominate me.&lt;br /&gt;&lt;br /&gt;I was joking with Grant Ronald a few months back that I received my original ACE Director nomination when my first daughter was born, so was looking forward to becoming the grand-poo-bar when my second arrived. Apparently such flippant remarks become reality.&lt;br /&gt;&lt;br /&gt;Thanks to everyone who has sent on their congratz via the other media channels including Twitter, LinkedIn, email and more.  &lt;br /&gt;&lt;br /&gt;I must also give a very special thanks to my "partner" in crime Jenny who gives her generous support and incredible patience in letting me pursue my Oracle activities.  Mind you I've kept my side of the bargain and neither of my children yet know what an Oracle database is.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-1851942676275633568?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/RoEsORnxugE" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/RoEsORnxugE/oracle-ace-director-of-year.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">8</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/07/oracle-ace-director-of-year.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-6287853299477841631</guid><pubDate>Sun, 28 Jun 2009 22:03:00 +0000</pubDate><atom:updated>2009-06-29T06:09:17.718+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">WebLogic Server</category><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>Making JDev just that little faster on WLS</title><description>During the ODTUG conference this year Lucas Jellema and myself discovered a little WebLogic Server feature (thanks to a presentation by Chris Bucchere) known as "fast-swap" that may have significant benefits in making the code-deploy-run cycle much shorter with JDeveloper.  As usual Lucas is the quickest to the blog punch, and has blogged it &lt;a href="http://technology.amis.nl/blog/5665/fast-swap-in-weblogic-103-and-jdeveloper-11g-redeploy-after-compile-in-running-application"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Take time to check it out.&lt;br /&gt;&lt;br /&gt;If anybody finds any limitations beyond those mentioned in Lucas's post, in particular those relating to JDev and ADF *please*let*us*know* as it will assist the entire JDev community.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-6287853299477841631?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/oAkgBegdO4A" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/oAkgBegdO4A/making-jdev-just-that-little-faster-on.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">4</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/06/making-jdev-just-that-little-faster-on.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-8639738272054590761</guid><pubDate>Tue, 23 Jun 2009 03:00:00 +0000</pubDate><atom:updated>2009-06-23T14:05:59.680+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Development</category><title>Stress &amp; load testing web applications (even ADF &amp; Apex) using Apache JMeter</title><description>A couple of years ago I presented &lt;a href="http://www.sagecomputing.com.au/papers_presentations/takealoadoff.pdf"&gt;Take a load off! Load testing your Oracle Apex or JDeveloper&lt;/a&gt; web applications at OOW and AUSOUG.  I can't recommend enough the importance of stress testing your web applications, it's saved my bacon a number of times.  Frequently as developers, we develop under a single user (developer) model where concurrency issues are easily avoided.  When our programs hit production, with just 1 more user, suddenly our programs grind to a halt or fall over in bizarre places.  Result, pie on developers' faces, users' faith in new technologies destroyed, and general gnashing of teeth all round.  Some simple stress and load tests can head off problems way before they hit production.&lt;br /&gt;&lt;br /&gt;(For the remainder of this post I'll infer "stress testing" and "load testing" as the same thing, though strictly speaking one tests for your application falling over, and the other how fast it responds under load)&lt;br /&gt;&lt;br /&gt;So how to go about stress testing a web application?&lt;br /&gt;&lt;br /&gt;There are numerous tools available to stress test web applications, paid and free.  This post will look at the setup and use of Apache's JMeter, my tool of choice, mainly because it is free! ... to undertake a very simple stress test.  Apache JMeter is available &lt;a href="http://jakarta.apache.org/jmeter/"&gt;here&lt;/a&gt;, version 2.3.3 at time of writing.&lt;br /&gt;&lt;br /&gt;On starting JMeter (&amp;lt;jmeter-home&gt;/bin/jmeter.bat on Windows) you'll see the following:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHFjBUI3CI/AAAAAAAAAvE/EfKsR_eRKuY/s1600-h/pic1.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 263px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHFjBUI3CI/AAAAAAAAAvE/EfKsR_eRKuY/s400/pic1.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271438104484898" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Creating a Thread Group&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;From here what we want to do is set up a Thread Group that simulates a number of users (concurrent sessions), done by right clicking the Test Plan node -&gt; Thread Group option.  This results in:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHFjH6mOSI/AAAAAAAAAvM/rfPxcyLlNGs/s1600-h/pic2.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 263px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHFjH6mOSI/AAAAAAAAAvM/rfPxcyLlNGs/s400/pic2.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271439876405538" /&gt;&lt;/a&gt;&lt;br /&gt;As you can see the Thread Group allows us to set a number of threads to simulate concurrent users/sessions, loop through tests and more.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Creating HTTP Requests&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;From here we can create a number of HTTP requests (Test Plan node right click -&gt; Add -&gt; Sampler -&gt; HTTP Requests) to simulate each HTTP request operation (Get, Post etc), HTTP headers, payloads and more.  However in a standard user session between server and browser there can be a huge array of these requests and configuring these HTTP requests within JMeter would be a major pain.&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;&lt;br /&gt;Configuring the HTTP Proxy Server&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;However there's an easier way.  Apache JMeter can work as a proxy between your browser and server and record a user's HTTP session, namely the individual HTTP requests, that can be re-played in a JMeter Thread Group later.&lt;br /&gt;&lt;br /&gt;To set this up instead right click the Workbench node, Add -&gt; Non-Test Elements -&gt; HTTP Proxy Server:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SjHFjavyVGI/AAAAAAAAAvU/Q_It9sCuUe8/s1600-h/pic3.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 230px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SjHFjavyVGI/AAAAAAAAAvU/Q_It9sCuUe8/s400/pic3.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271444931335266" /&gt;&lt;/a&gt;&lt;br /&gt;To configure the HTTP Proxy Server do the following:&lt;br /&gt;&lt;br /&gt;* Port – set to a number that wont clash with an existing HTTP server on your PC (say 8085)&lt;br /&gt;* Target Controller – set to "Test Plan &gt; Thread Group".  When the proxy server records the HTTP session between your browser and server, this setting implies the HTTP requests will be recorded against the Thread Group you created earlier, so we can reuse them later&lt;br /&gt;* URL Patterns to include – a regular expression based string that tells the proxy server which URLs to record, and those to ignore.  To capture everything set it to .* (dot star).  Be warned that during recording however, if you use your browser for anything else but accessing the server you wish to stress test, JMeter will also capture that traffic.  This includes periodic refreshes by web applications such as Gmail or Google Docs that you don't even initiate; I'm pretty sure when replaying your stress test, Google would prefer you not to stress test their infrastructure for them; stick to your own for now ;-)&lt;br /&gt;&lt;br /&gt;The end HTTP Proxy Server setting will look something like this:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHFjmE8_NI/AAAAAAAAAvc/GzomZai3r-c/s1600-h/pic4.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 230px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHFjmE8_NI/AAAAAAAAAvc/GzomZai3r-c/s400/pic4.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271447972904146" /&gt;&lt;/a&gt;&lt;br /&gt;You'll note the HTTP Proxy Server has a Start button.  We can't use this just yet.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Configuring your Browser&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;In order for the JMeter HTTP Proxy Server to capture the traffic between your server and browser, you need to make some changes to your browser's configuration.  I'm assuming you're using Firefox 3 in the following example, but same approximate steps are needed for Internet Explorer.&lt;br /&gt;&lt;br /&gt;Under Firefox open the Tools -&gt; Options menu, then Advanced icon, Network tab, Settings button which will open the Connection Settings dialog.&lt;br /&gt;&lt;br /&gt;In the Connection Settings dialog set the following:&lt;br /&gt;&lt;br /&gt;* Select the Manual proxy configuration radio button&lt;br /&gt;* HTTP Proxy – localhost&lt;br /&gt;* Port – 8085 as per the JMeter HTTP Proxy Server option we set earlier&lt;br /&gt;* No Proxy for – ensure that localhost and 127.0.0.1 aren't in the exclusion list&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SjHFj-9-cmI/AAAAAAAAAvk/A2KqnUDTwUs/s1600-h/pic5.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 387px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SjHFj-9-cmI/AAAAAAAAAvk/A2KqnUDTwUs/s400/pic5.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271454654526050" /&gt;&lt;/a&gt;&lt;br /&gt;The above setup makes an assumption that the server you want to access is accessibly without a further external proxy required.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Recording your HTTP session&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Once the browser's proxy is setup, to record a session between the browser and server do the following:&lt;br /&gt;&lt;br /&gt;1) In Apache JMeter hit the Start button on the HTTP Proxy Server page&lt;br /&gt;2) In your browser enter the URL of the first page in the application you want to stress test&lt;br /&gt;&lt;br /&gt;Thereafter as you navigate your web application, enter data and so on, JMeter will faithfully record each HTTP request between the browser in server against your Thread Group.  This may not be immediately obvious, but expand the Thread Group and you'll see each HTTP request made from the browser to server:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHF9zMjEOI/AAAAAAAAAvs/o6g0ZWhG3vk/s1600-h/pic6.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 222px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHF9zMjEOI/AAAAAAAAAvs/o6g0ZWhG3vk/s400/pic6.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271898171019490" /&gt;&lt;/a&gt;&lt;br /&gt;As can be seen, even visiting 1 web page can generate a huge amount of traffic.  Ensure to stop recording the HTTP session by selecting the Stop button in the JMeter HTTP Proxy Server page.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Configuring the Thread Group for replay&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Once you've recorded the session in the Thread Group there are a couple of extra things we need to achieve.&lt;br /&gt;&lt;br /&gt;For web application's that use Cookies and session IDs (JDeveloper's ADF uses a JSessionID for tracking sessions) to track each unique user session, we cannot replay the exact HTTP request sequence with the server through JMeter, as the session ID is pegged to the recorded session, not the upcoming stress test sessions.&lt;br /&gt;&lt;br /&gt;To solve this in JMeter right click the Thread Group -&gt; Add -&gt; Config Element -&gt; HTTP Cookie Manager.  This will be added as the last element to the Thread Group.  I usually move it to the top of the tree:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHF-KZ4yjI/AAAAAAAAAv0/R-hELvaCfIg/s1600-h/pic7.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 222px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHF-KZ4yjI/AAAAAAAAAv0/R-hELvaCfIg/s400/pic7.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271904400984626" /&gt;&lt;/a&gt;&lt;br /&gt;Next we need to configure the Thread Group to show us the results of the stress test.  There are a number of different ways to do this, from graphing the responses, to showing the raw HTTP responses.  In this post we'll take the later option.&lt;br /&gt;&lt;br /&gt;Right click the Thread Group -&gt; Add -&gt; Listener -&gt; View Results in Tree, which will add a View Results in Tree node to the end of the Thread Group:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHF-VSvE0I/AAAAAAAAAv8/c-5WPM4DSyQ/s1600-h/pic8.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 230px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHF-VSvE0I/AAAAAAAAAv8/c-5WPM4DSyQ/s400/pic8.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271907323777858" /&gt;&lt;/a&gt;&lt;br /&gt;Finally save the Thread Group by selecting it in the node tree, then File -&gt; Save.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Running the Thread Group&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;To commence your first stress test run, it's best to leave the number of spawned sessions to 1, just to see the overall test will work in it's most basic form.  The default Thread Group number of threads is set to 1, so there is no need to make a change to do this.&lt;br /&gt;&lt;br /&gt;To run the test, simply select the Run menu -&gt; Start.  On running the Thread Group, you'll see the top right of JMeter has a little box that tells if it's still running, and the number of tests to go vs total number of tests:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHF-v26n1I/AAAAAAAAAwE/WGCI1VwNoYA/s1600-h/pic9.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 221px; height: 106px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHF-v26n1I/AAAAAAAAAwE/WGCI1VwNoYA/s400/pic9.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271914454851410" /&gt;&lt;/a&gt;&lt;br /&gt;Once the tests are complete, this indicator will grey out.&lt;br /&gt;&lt;br /&gt;We can now visit the View Results Tree:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHF-sjMZkI/AAAAAAAAAwM/XR1iQKSVkyc/s1600-h/pic10.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 228px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SjHF-sjMZkI/AAAAAAAAAwM/XR1iQKSVkyc/s400/pic10.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5346271913566824002" /&gt;&lt;/a&gt;&lt;br /&gt;This shows the HTTP requests that were sent out and on selecting an individual request, you see the raw HTTP request and the actual response.  You'll note the small green triangles showing a successful HTTP 200 result.  If different HTTP errors occur the triangles show different colours.  Also remember that sometimes application errors don't perculate up to the HTTP layer in your web application, so you should check your application's logs too (in the case of a JEE application, this will be your container's internal logs).&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Running a Stress Test&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The obvious step from here is to change the Thread Group number of threads to a higher number.&lt;br /&gt;&lt;br /&gt;From here take time out to explore the other features in JMeter. It includes a wide range of features that in particular make it useful for regression testing.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Caveats&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Firstly remember when doing this you're not only stress testing your application, your stress testing a server, potentially stress testing databases, stress testing your networks and so on.  Therefore you can have an affect on anybody sharing those resources.  "Hard core" stress tests should be on separate infrastructure, after hours, aiming for as little impact on those around you!&lt;br /&gt;&lt;br /&gt;Also keep in mind, besides seeing your application fall over at 2 users, 10 users, 100 users, which is an important test, try to be realistic about your stress tests.  Stress testing you're brand-new-application to a 1 million concurrent users is probably not being realistic.  How many concurrent user requests do you really expect and what response times do you need?  Normally when I ask managers this question they'll answer with, "oh we have 1000 concurrent users, the application must support that many at any one time".  However what they really mean is the application has 1000 users, potentially all logged into the application (ie. sessions) at the same time, but not necessarily hitting the server with HTTP requests at any onetime.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-8639738272054590761?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/cDLj3J5-FRA" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/cDLj3J5-FRA/stress-load-testing-web-applications.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/_5hhNK2aXwp8/SjHFjBUI3CI/AAAAAAAAAvE/EfKsR_eRKuY/s72-c/pic1.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">6</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/06/stress-load-testing-web-applications.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-5971390444945648863</guid><pubDate>Tue, 16 Jun 2009 12:45:00 +0000</pubDate><atom:updated>2009-06-16T20:45:09.319+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Web Services</category><title>WLS 10.3 WSDL external policy attachment error</title><description>We recently encountered an issue with deploying JAX-WS web services to Oracle WebLogic Server 10.3 where the web service WSDL included a &amp;lt;wsp:policyReference&gt; external policy attachment.&lt;br /&gt;&lt;br /&gt;The error:&lt;pre name="code" class="java"&gt;&lt;br /&gt;javax.xml.ws.WebServiceException: weblogic.wsee.ws.init.WsDeploymentException: Unable to to retrieve policy from URI 'externalpolicy.xml'&lt;br /&gt; at weblogic.wsee.jaxws.framework.jaxrpc.TubelineDeploymentListener.createServer(TubelineDeploymentListener.java:85)&lt;br /&gt; at weblogic.wsee.jaxws.WLSTubelineAssemblerFactory$TubelineAssemblerImpl.createServer(WLSTubelineAssemblerFactory.java:74)&lt;br /&gt; at com.sun.xml.ws.server.WSEndpointImpl.&lt;init&gt;(WSEndpointImpl.java:152)&lt;br /&gt; at com.sun.xml.ws.server.EndpointFactory.createEndpoint(EndpointFactory.java:217)&lt;br /&gt; at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:467)&lt;br /&gt; Truncated. see log file for complete stacktrace &lt;br /&gt;&lt;/pre&gt;Note the name of the policy file in the error: externalpolicy.xml&lt;br /&gt;&lt;br /&gt;Our WSDL included the following binding options referring to the external policy file:&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;wsdl:binding name="ABC.1.0.SoapBinding" type="tns:ABC.1.0"&gt;&lt;br /&gt;  &lt;soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/&gt;&lt;br /&gt;  &lt;wsp:PolicyReference URI="externalpolicy.xml"/&gt;&lt;br /&gt;  &lt;wsdl:operation name="ABC"&gt;&lt;br /&gt;   &lt;soap:operation soapAction="http://obscured/abc/abc.1.service" soapActionRequired="true"/&gt;&lt;br /&gt;   &lt;wsdl:input name="RequestABC"&gt;&lt;br /&gt;    &lt;soap:body use="literal"/&gt;&lt;br /&gt;   &lt;/wsdl:input&gt;&lt;br /&gt;   &lt;wsdl:output name="ResponseABC"&gt;&lt;br /&gt;    &lt;soap:body use="literal"/&gt;&lt;br /&gt;   &lt;/wsdl:output&gt;&lt;br /&gt;  &lt;/wsdl:operation&gt;&lt;br /&gt; &lt;/wsdl:binding&gt;&lt;br /&gt;&lt;/pre&gt;Note the use of the &amp;lt;wsp:PolicyReference&gt; tag with the URI attribute referring to the externalpolicy.xml file located in the same src directory as the WSDL.&lt;br /&gt;&lt;br /&gt;The externalpolicy.xml included an MTOM policy, ultimately nothing special:&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;?xml version="1.0" encoding="UTF-8"?&gt;&lt;br /&gt;&lt;policies xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"&lt;br /&gt;          xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"&lt;br /&gt;          xmlns:wsoma="http://schemas.xmlsoap.org/ws/2004/09/policy/optimizedmimeserialization"&lt;br /&gt;          xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200512"&gt;&lt;br /&gt; &lt;wsp:Policy wsu:Id="abc.mtom.policy"&gt;&lt;br /&gt;  &lt;wsoma:OptimizedMimeSerialization/&gt;&lt;br /&gt; &lt;/wsp:Policy&gt;&lt;br /&gt;&lt;/policies&gt; &lt;br /&gt;&lt;/pre&gt;The deployment problem is caused because by default WLS isn't configured to search for external policy files on the CLASSPATH of the application.&lt;br /&gt;&lt;br /&gt;The fix is however simple (and somewhat obscurely documented &lt;a href="http://edocs.bea.com/wls/docs103/webserv_sec/message.html#wp289010"&gt;here&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;Locate your WLS %domain_home%/bin/startWebLogic.cmd file and replace the following line:&lt;br /&gt;&lt;br /&gt;set JAVA_OPTIONS=%SAVE_JAVA_OPTIONS%&lt;br /&gt; &lt;br /&gt;..to..&lt;br /&gt; &lt;br /&gt;set JAVA_OPTIONS=-Dweblogic.wsee.policy.LoadFromClassPathEnabled=true %SAVE_JAVA_OPTIONS%&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-5971390444945648863?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/l4QgJaipoL8" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/l4QgJaipoL8/jax-ws-throwing-generic-soapfaults.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/05/jax-ws-throwing-generic-soapfaults.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-7622688565954165754</guid><pubDate>Thu, 11 Jun 2009 04:10:00 +0000</pubDate><atom:updated>2009-06-11T12:12:07.600+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ADF Faces RC</category><title>ADF Faces RC: turning off the browser's autocomplete functionality</title><description>Modern browsers include an autocomplete function, effectively a poplist that shows the user's most recent entries for a set field in a list, for the user to choose from.&lt;br /&gt;&lt;br /&gt;There are times when this functionality isn't desirable, such as credit card numbers, password fields and similar.&lt;br /&gt;&lt;br /&gt;As detailed in the following Mozilla Developer Center &lt;a href="https://developer.mozilla.org/En/How_to_Turn_Off_Form_Autocompletion"&gt;page&lt;/a&gt;, both IE and FF support an autocomplete="off" attribute on form and input controls to suppress the browser's autocomplete functionality.  Unfortunately this feature is not part of the HTML standards, and in turn is not a property of the equivalent tags in ADF Faces RC for JDeveloper 11g build 5188 (ER with Oracle Support pending).&lt;br /&gt;&lt;br /&gt;There is a JavaScript solution that readers may be interested to see, and I thought this a good post because it shows the mechanism for calling JavaScript through the ADF Faces RC tags, something that I seem to be doing more and more.&lt;br /&gt;&lt;br /&gt;The following example shows how to turn the autocomplete off at the form level:&lt;br /&gt;&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;af:document&gt;&lt;br /&gt;  &lt;af:clientListener type="load" method="disableAutoComplete"/&gt;&lt;br /&gt;  &lt;trh:script text="&lt;br /&gt;    function disableAutoComplete(event) {&lt;br /&gt;      myForm = document.getElementById('myForm');&lt;br /&gt;      myForm.setAttribute('autocomplete', 'off');&lt;br /&gt;    }"/&gt;&lt;br /&gt;  &lt;af:form id="myForm" clientComponent="true"&gt;&lt;br /&gt;  ...so on...&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Points to note:&lt;br /&gt;&lt;br /&gt;* The use of the "load" clientListener at document level to call the disableAutoComplete.  This is the equivalent of the HTML body tags onLoad attribute.&lt;br /&gt;&lt;br /&gt;* The use of the clientComponent="true" attribute in the form tag.  This forces ADF Faces RC to generate a HTML form component with the same id in the resulting HTML page to be rendered.  This is essential as the disableAutoComplete method requires the form id in the DOM in order to find the form via it's call to getElementById and turn off the autocomplete function.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-7622688565954165754?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/Pv6bWXwULmI" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/Pv6bWXwULmI/adf-faces-rc-turning-off-browsers.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">2</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/06/adf-faces-rc-turning-off-browsers.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-1784712213652396225</guid><pubDate>Mon, 08 Jun 2009 12:47:00 +0000</pubDate><atom:updated>2009-06-08T21:02:57.072+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Interviews</category><title>Q&amp;A With Grant Ronald</title><description>(This is a reprint of an article published in the UKOUG's Select magazine early this year)&lt;br /&gt;&lt;br /&gt;When talking about Oracle Forms and JDeveloper, one Oracle personality stands out among others - long time blogger Grant Ronald from Oracle Corporation UK. Grant has for a long time “pimped” Oracle Forms and its big brother JDeveloper at Oracle events and user groups events around the world. His popularity is shown by his blog receiving on average 2000 hits per day. Lately, to reassure Oracle customers that Oracle intends to keep on supporting Oracle Forms and show that Forms has a future inline with JDeveloper, Grant has been responsible for the Oracle’s Forms Modernization message.&lt;br /&gt;&lt;br /&gt;Chris Muir from SAGE Computing Services Australia conducted the following Q&amp;A session with Grant to get the low down and latest on Forms and JDeveloper, as well as a little about Grant himself.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: What role do you currently play at Oracle and what does your day job entail?&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;&lt;br /&gt;Grant Ronald&lt;/span&gt;: Well, my title says “Group Product Manager” and the products I cover are Oracle Forms and Oracle JDeveloper. As a Product Manager you are responsible for the success of the products in your area. That encompasses everything from working with developers on features, the marketing department on campaigns or delivering presentations at events like Oracle World. In the morning you can be rolling your sleeves up and getting into code with a developer, and in the afternoon you can be meeting with the CTO. It’s that varied.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: How did you get into this Oracle gig anyhow? What’s your background at Oracle and computing in general?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: Back in the early ’80s, home computing was slowly starting to take off with computers like the Sinclair Spectrum, Vic20 and BBC home computers, and it seemed like a new an innovative field to get involved in when I left school. So I got my degree in Computing Science then joined a small IT outfit in the UK that eventually got consumed by EDS. It was a pretty typical development role for about seven years, mainly focused on military applications, and my last job was designing, developing and leading the team for the development of the user interface for a military email system.&lt;br /&gt;&lt;br /&gt;This took me up to 1996 when I fancied a change, and Oracle was looking for people with development experience on Unix and Motif in their support organization. So I joined Oracle Support where I eventually headed up the group who supported the local EMEA (Europe, Middle East, Africa) teams in Forms, Reports and Discoverer. Given that I was working closely with the Oracle Product Management team in this role, I was eventually persuaded to make the jump into Oracle Development!&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Ok, now for some tough questions worthy of any Q&amp;A: You’re currently known via your blog for discussions on Oracle development including Forms and SOA, and presentations in Oracle Developer Days around the world. Previously you were also known for you work on JDeveloper. Why the change? Has Oracle internally panicked about the impression (my emphasis) customers are getting that Oracle has killed Forms, and now the need for Forms advocates?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: There has not really been a change. The thing is, we’ve never stopped talking about Forms. I’ve got the air miles and passport stamps to show that we were still presenting Forms at Oracle World, ODTUG (Oracle Development Tools User Group), UKOUG (UK Oracle User Group), DOAG (German Oracle User Group) and dozens of other events covering EMEA, APAC and the Americas.&lt;br /&gt;&lt;br /&gt;The &lt;a href="http://otn.oracle.com/products/forms"&gt;Forms OTN page&lt;/a&gt; is still a hive of activity: news, events, whitepapers and how-to’s. Maybe people thought we had stopped talking about Forms because we were also talking about other technologies as well. Ten years ago if you developed on an Oracle database then you pretty much used Forms, simple as that. But the world has changed and there are other things to talk about now. Which makes sense, if you think about it; there is more need and more demand to be talking about the “new” stuff, especially when it is evolving at such a rate.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: On discussing Forms and considering that some Oracle customers are confused on the future of Forms, can you outline Oracle’s commitment to Forms in terms of existing versions and Oracle Support?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: I think the strongest statement we have is the fact that we published a statement of direction five years ago and that statement remains true today. We’ve always said that we are committed to Forms and that there have been no plans to desupport it. That line has never changed. Regarding support, we’ve recently just extended the support date for 10.1.2 (the latest release of Oracle Forms) and Forms 11g is in development, having already had positive reviews from our beta testers. So we are lengthening the support dates, we are working on the next release and we are also discussing enhancements and features for post 11g. I think that’s all good news.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Could the problem with Oracle Forms just be an image problem? It’s never been known for sexy development (a’la grey screens of boredom), and especially now that the web world, web rich clients, AJAX etc have taken off.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: The sweet spot for Oracle Forms has always been the ability to rapidly develop rich, transactional business applications. So you see Oracle Forms applications in your government offices, airlines and bank back-offices etc. The need for visual “bells and whistles” is less at the fore than, for example, an online shopping application where a user makes a snap decision, often based on visual aesthetics, as to whether they will use the site.&lt;br /&gt;&lt;br /&gt;But there is nothing to stop you pushing the boundaries of the visual aspects of Oracle Forms. We have customers who are using some of the features of Oracle Forms, like PJCs and Java beans, to really push the boundaries of the Forms UI. Like this &lt;a href="http://www.oracle.com/technology/products/forms/pdf/capula.pdf"&gt;story&lt;/a&gt;. So there is nothing to stop you modernizing your Forms application, starting with an update of the user interface.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: So what plans do Oracle have in addressing Forms customers?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: We are continuing to present at all the major events and user groups. In addition, we’ve launched a focus &lt;a href="http://otn.oracle.com/goto/formsmodernize"&gt;page&lt;/a&gt;. This includes recorded webcasts on Forms strategy, calling web services from Forms and Forms new features. There are also white papers and customer stories as well. This is also being backed up by a roadshow which to date has hit nearly 20 countries.&lt;br /&gt;&lt;br /&gt;For those Forms customers who are taking a step into the Java world, we have a dedicated site on &lt;a href="http://otn.oracle.com/formsdesignerj2ee"&gt;OTN&lt;/a&gt; as well as dedicated developers guides, books and Oracle University courses.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Consider an Oracle shop with a large legacy Oracle Forms application that is running well but in a desupported version of Forms. Should they have any intentions of upgrading their Forms installs and what are the risks if they don’t?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: Our roadmap for Forms customers is “upgrade and integrate”. So the first point to consider is upgrade. There are, of course, benefits of upgrading but you also have to consider the risk of not upgrading: running your business applications on desupported software that is neither security nor bug patched, or being certified on newer OS or database versions. Are you managing the risk that some piece of this stack may change and destabilise your applications (e.g. a forced O/S upgrade), or are you just hoping that this software tower will hold up with no means of support. It’s your call.&lt;br /&gt;&lt;br /&gt;Which takes us to the next point: integration. By web deploying your Forms on the application server, you are positioning yourself on a platform on which you can integrate both your legacy applications, and new services and applications.&lt;br /&gt;&lt;br /&gt;By following the “upgrade and integrate” roadmap, you can limit the risk to your business applications while still positioning yourself for your long-term strategic goals.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Consider an Oracle shop with a large amount of SQL and PL/SQL programmers who are cognisant in Forms. Which Oracle development technology should they pick for maintenance and extension of the existing system: Forms, Apex or JDeveloper/ADF?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: The simplest answer is really to pick the technology/tool that suits you best. If you are extending your existing Forms application it may be that you build new business logic in the database that could be shared between Forms, Java and Apex applications. Or you might decide that you really want to exploit the power of Java and so JDeveloper and ADF would be a natural choice. Many customers are closely aligned with Oracle’s business applications and so the Oracle Fusion technology stack may drive the choice of development tool. I try to discourage customers to think in binary terms when choosing tools. The reality is that you will probably have a mix.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: You mention that JDeveloper and ADF would be the natural choice for an Oracle developer. Why?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: As I mentioned earlier, I look after Oracle Forms and Oracle JDeveloper. One reason for this split in roles is to bring my 4GL Forms experiences into JDeveloper and Oracle ADF. When I first joined the JDeveloper team I was amazed how developers were willing to write lines of code for common actions that I set with the click of a checkbox in Forms. Part of my job is to ensure that the kind of rich features a Forms developer takes for granted are implemented in JDeveloper and Oracle ADF.&lt;br /&gt;&lt;br /&gt;JDeveloper and Oracle ADF is also a natural choice because it’s the route our own Applications Division is taking. Our next generation Fusion applications are being built using JDeveloper and ADF. So, as the technology choice for Oracle’s own Fusion Applications, the technology is built with the Forms/Database and PL/SQL developers in mind. No other tool or framework can make this claim.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: What skills do you see a Forms developer needing in moving to ADF, and what approach do you suggest to a development team in minimising this learning curve?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: There is a learning curve in moving to any new technology but with JDeveloper and ADF we are really smoothing out that learning curve and lowering the barrier at which you can start to become productive.&lt;br /&gt;&lt;br /&gt;Of course, the bottom line is that you will need some Java knowledge, but how much depends on how far you want to get below the covers and customize the behaviour of the framework.&lt;br /&gt;&lt;br /&gt;With an overview of ADF and some basic Java language skills, you can go a long way: building business services, validation, page flow, rich UI interaction, LOVs, graphs – stuff that you couldn’t even consider if you weren’t using ADF.&lt;br /&gt;&lt;br /&gt;But if you have made a strategic choice to develop on the Java platform, I’d expect you to still have some members of your team who have a more advanced knowledge of the platform so they can make architectural decisions and set up best practices. We are also working on giving you the learning aids to get up to speed. We have developed a number of Oracle University courses specifically targeted at the Forms audience moving to Java. There are a number of books already published and more in the pipeline that are aimed at opening up the platform. And of course, we have a dedicated focus page on &lt;a href="http://otn.oracle.com/formsdesignerj2ee"&gt;OTN&lt;/a&gt; and the essential ADF developer guides for 4GL developers.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Recently you’ve been focusing on SOA technology integration with Forms. Why advantages do you see this combination providing? What challenges do Forms programmers face with integration?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: The benefits of a service based approach are already well documented: loosely coupled, reusable implementations of business processes gives a more flexible, agile architecture that is better aligned to the business.&lt;br /&gt;&lt;br /&gt;Much of the work we are doing with Oracle Forms now is to allow your existing Forms application to hook into the SOA world. The ability to call out to web services and for those services to call back asynchronously is one example.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Grabbing your crystal ball, given your long-term experience in development, where do you see Oracle development in 10 years time?&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: I think the clearest view of the future can be seen in Oracle’s own business applications. Oracle’s Applications Division have upgraded to the most recent version of Forms, while looking to exploit the benefits of a services oriented architecture and a standards based platform. Using JDeveloper and Oracle ADF, they are taking developers from a background including Forms, PL/SQL and Peopletools, and making them productive on the Java platform.&lt;br /&gt;&lt;br /&gt;I think this gives the clearest indication of where Oracle development is heading and I think there is a great comfort in knowing that the technology choices you are making are the ones Oracle is betting its business applications on as well.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;CM&lt;/span&gt;: Finally, moving out of the Oracle arena, what keeps you kicking out of work? I know you play in a band.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Grant Ronald&lt;/span&gt;: I play a bit of keys in a band, and that mixed with a few weekends out biking helps balance out all the fun I have at Oracle!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-1784712213652396225?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/dptTVG0QZRo" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/dptTVG0QZRo/q-with-grant-ronald.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/06/q-with-grant-ronald.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-2779395218772261088</guid><pubDate>Tue, 02 Jun 2009 13:40:00 +0000</pubDate><atom:updated>2009-06-02T21:41:12.508+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><category domain="http://www.blogger.com/atom/ns#">Book Review</category><title>Book review - Processing XML Documents with JDeveloper 11g</title><description>I was recently asked to write a book review on &lt;a href="http://www.packtpub.com/processing-xml-documents-with-oracle-jdeveloper-11g/book"&gt;Processing XML Documents with JDeveloper 11g&lt;/a&gt; by Deepak Vohra, among several other bloggers &lt;a href=" http://kingsfleet.blogspot.com/2009/04/book-review-processing-xml-documents.html"&gt;here&lt;/a&gt;, &lt;a href=" http://db360.blogspot.com/2009/04/book-review-processing-xml-documents.html"&gt;here&lt;/a&gt;, &lt;a href="http://it.toolbox.com/blogs/oracle-guide/processing-xml-documents-with-oracle-jdeveloper-11g-31015?rss=1"&gt;here&lt;/a&gt; and &lt;a href="http://blogs.oracle.com/olaf/2009/05/book_review_processing_xml_doc.html"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;The thing about book reviews, like movie reviews, is the interpretation by the reviewer is subjective.  The trick is for you the review reader to work out does the reviewer have the same tastes and likes as you.  If yes that should mean that the book review will be relevant to you potentially giving a recommendation that suits your needs.  If no you might miss a really good book or waste a couple of those hard earned squid.&lt;br /&gt;&lt;br /&gt;So where do I come from to help you assess if I'm "your" type of reviewer?  I'm a both a consultant *and* a trainer.  I'm interested in how the story is told as much as what is told.  I'm looking for clear examples, a logical A-B-C progression path, and like everyone else something to keep me interested, especially important in the often dreary world of computing.  In addition I use XML and JDeveloper in my day to day job, so I should be a prime candidate for this book.&lt;br /&gt;&lt;br /&gt;In considering the book's title and what I'd expect to find between the book's covers, I'd want to see a discussion around the XML facilities in JDev 11g vs earlier versions, a comparison of JDev's XML facilities against the other IDEs, then a road-show through the XML features vs the common XML tasks in Java of creating/parsing XML, XML schemas &amp; validation etc.  Let's see how the book fairs.&lt;br /&gt;&lt;br /&gt;Firstly the Who-is-this-book-for section somewhat incorrectly states readers need to know just XML basics: "what an XML document is, what XSLT is, what XPath is, and what an XML schema is."  In the very first chapter it introduces the DOM and SAX parsing methods without any explanation of how they work or the differences, so it actually assumes more knowledge than stated.  Anybody with a limited knowledge of XML should definitely look at a book tailor fitted to explaining XML alone before reaching for this book.&lt;br /&gt;&lt;br /&gt;The book does receive bonus points for including the latest version of JDeveloper 11g.  On average, computing books have short half-lives because the technology they're based on is updated or replaced regularly. As a book purchaser you want your investment to last long as possible without becoming instantly redundant.  The fact this book is written against the latest JDev 11g release should help extend that investment, until Oracle does another rewrite of the IDE.&lt;br /&gt;&lt;br /&gt;Yet on considering my expectations for the book, it doesn't take the opportunity to discuss JDeveloper in general, nor its XML feature support.  This is a shame as it doesn't help to "sell" JDeveloper and its benefits in any direct manner.&lt;br /&gt;&lt;br /&gt;But in addressing my expectations again the book takes you through typical stuff you want to do with XML via Java, such as creating and parsing XML, working with XML schemas, XML validation, XPath and so on very much in a cookbook like fashion – here's a recipe now you follow it.  I somewhat don't understand the inclusion of chapters on XML to PDF, XML to Excel, and XML Publisher, as the book's title is about processing XML in JDeveloper, those chapters relate to specific XML use cases not a generalised XML requirement.  Their exclusion could have made this a concise JDev-XML guide.&lt;br /&gt;&lt;br /&gt;If I consider the writing style used, personally from reading around a zillion technical books I tend to lump technical books into 3 styles:&lt;br /&gt;&lt;br /&gt;a)  the "Head First" series which takes an extreme narrative style&lt;br /&gt;b) the other end which is just reams of code and specifications which isn't a book but rather a printed manual, it typically gives no narrative, just cold hard "this is how you do it" facts&lt;br /&gt;c) and the books that lie in between&lt;br /&gt;&lt;br /&gt;For me a good book is one that lies in that nice gray area "c".  I want the writer to keep me interested with a narrative style while reading the boring technical bits, information about the pros and cons, some background information, but not bury me in opinions and jokes (and crosswords and word puzzles for that matter).&lt;br /&gt;&lt;br /&gt;For me this book falls closer to "b", you can tell it's written by a programmer by its dry clinical dry style.  For instance chapter 1 introduces the fact that Oracle XDK 11g provides an API that extends JAXP, but then doesn't discuss what the Oracle XDK 11g is, why Oracle chose to override JAXP, and what benefits you'll get over using the non-standard libraries.  So you get a "this is how you do it" style rather than any discussion on the "why", which I think is important for learning.  Some readers might be smart enough (I know I'm not ;-) to conclude the "why" without any explicit description, so this book might suit you directly.&lt;br /&gt;&lt;br /&gt;If we take the fact the book includes a large amount of code, in particular XML, care by the author and the publisher needs to be taken to present code in a concise way,  well laid out code that is documented clearly, because code is central to the book's value.  There are numerous examples in the book where code stretches across several pages without explanation, code layout is messy in areas, and given the quantity of code at times it's hard to work out which bit I should be focusing on (a problem that is often magnified by the "over-wordiness" of XML).  I've no doubt given the amount of code in the book achieving this consistency is a very hard task, but again it detracts from the quality of the book.&lt;br /&gt;&lt;br /&gt;Finally I mentioned that it's important for technical books to present a logical A-B-C progression path in assisting the reader to learn.  Given this book's clinical style, where in each chapter it discusses the JDev environment setup, then a bullet point section walk through of the code, and how to run and see the results in the end, it does achieve this goal.  Again the "why" is often missing in this book, but you do see the A-B-C progression path which is important.&lt;br /&gt;&lt;br /&gt;In summary would I recommend this book?  If you're simply looking for a cookbook like style technical book the answer is yes, but (and there is always a but)....  for myself I miss the "why" in this book, the part that helps me learn the peripheral issues, so the answer is no.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-2779395218772261088?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/VpBajW3gcUg" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/VpBajW3gcUg/book-review-processing-xml-documents.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/06/book-review-processing-xml-documents.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-1810101668874045569</guid><pubDate>Thu, 28 May 2009 13:58:00 +0000</pubDate><atom:updated>2009-05-28T21:59:12.584+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>OTN Article - Taking an Oracle ADF Application from Design to Reality</title><description>I'm happy to announce that a 5 part article &lt;a href="http://www.oracle.com/technology/pub/articles/adf-from-design-to-reality/index.html"&gt;Taking an Oracle ADF Application from Design to Reality&lt;/a&gt; authored by Penny Cookson and myself has been published on Oracle's Technology Network.&lt;br /&gt;&lt;br /&gt;I'd like to thank Penny for her assistance in writing the article, Steve Muench and John Stegeman for their ideas (supplied directly and indirectly), Grant Ronald for his review and Justin Kestelyn's OTN team for their hard work.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-1810101668874045569?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/9SE16KLKx64" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/9SE16KLKx64/otn-article-taking-oracle-adf.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/05/otn-article-taking-oracle-adf.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-1486324216978297823</guid><pubDate>Wed, 27 May 2009 04:47:00 +0000</pubDate><atom:updated>2009-05-27T13:33:48.551+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>Java Developer Journal - JDeveloper - an IDE that moves with the times</title><description>I'm happy to announce that an article of mine has recently been published in the Java Developer Journal, titled "JDeveloper - an IDE that moves with the times".  You can pick up the full JDJ magazine &lt;a href="http://www2.sys-con.com/java/pdfs/JDJ_14-2%20_spread.pdf"&gt;here&lt;/a&gt; or the online article &lt;a href="http://java.sys-con.com/node/951686"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Thanks to Teri Whitaker and Shay Shmeltzer for their assistance with this article.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-1486324216978297823?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/e9AeQ4u8Evk" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/e9AeQ4u8Evk/java-developer-journal-jdeveloper-ide.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/05/java-developer-journal-jdeveloper-ide.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-7410381686262890355</guid><pubDate>Tue, 26 May 2009 07:47:00 +0000</pubDate><atom:updated>2009-05-26T16:04:50.182+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>JDeveloper next version - new features sneak preview</title><description>Jakub Pawlowski has &lt;a href="http://kuba.zilp.pl/?id=801"&gt;spotted&lt;/a&gt; the &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/index.htm"&gt;beta documentation&lt;/a&gt; for the next release of JDev, great work Jakub.  Best to check it out now, as the URL indicates this is a beta release and the URL may not be there for long.&lt;br /&gt;&lt;br /&gt;As Jakub has pointed out, there's a great new &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/web.1111/b31973/af_calendar.htm#BABIDBCE"&gt;calendar&lt;/a&gt; component arriving.  I remember asking for something like this a year or so ago, and the Oracle Gods have delivered.  Great work :-)&lt;br /&gt;&lt;br /&gt;Some other things I spotted from a quick scan:&lt;br /&gt;&lt;br /&gt;1) &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/web.1111/b31973/af_orgpage.htm#CACJAJGI"&gt;Dashboard component&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;2) &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/web.1111/b31973/dv_intro.htm#sthref1834"&gt;Hierarchy Viewer&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;3) ADF BC - &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/web.1111/b31974/bcextservices.htm#CJAJGIEB"&gt;Integrating Service-Enabled Application Modules&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;4) Whole new manual &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/web.1111/e10139/toc.htm"&gt;Desktop Integration Developer's Guide&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;5) Manual for potentially a new product &lt;a href="http://otnbeta.oracle.com/fmw11g/582tj30eapvb/doc.1111/e14149/toc.htm"&gt;Oracle Help&lt;/a&gt; (at least I hadn't heard of it before)&lt;br /&gt;&lt;br /&gt;...and so on... it's worth a stroll through the documentation to check out new features.  I'd appreciate if you find any more, to post them as a comment on this blog post please.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-7410381686262890355?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/kLicPQ5KSlI" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/kLicPQ5KSlI/jdeveloper-next-version-new-features.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">4</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/05/jdeveloper-next-version-new-features.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-8082649063106611809</guid><pubDate>Sun, 10 May 2009 12:49:00 +0000</pubDate><atom:updated>2009-05-10T20:54:48.813+08:00</atom:updated><title>I'm happy to announce...</title><description>I'm happy to announce the arrival of Jessica Muir, a calm and collected little 3.5 kilo girl.  Mum and Jessica are doing just fine, while Dad is running a quick "education" campaign with Jessica's 2yr old sister about the merits of little sisters. &lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SgbOVfBQ-rI/AAAAAAAAAuE/RGMfd2UiJ6I/s1600-h/DSC01831.JPG"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 240px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SgbOVfBQ-rI/AAAAAAAAAuE/RGMfd2UiJ6I/s400/DSC01831.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5334177677166312114" /&gt;&lt;/a&gt;&lt;br /&gt;Our new arrival spells a few weeks break from blogging, normal services will resume shortly.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-8082649063106611809?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/0tLhA2ZpF5w" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/0tLhA2ZpF5w/im-happy-to-announce.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/_5hhNK2aXwp8/SgbOVfBQ-rI/AAAAAAAAAuE/RGMfd2UiJ6I/s72-c/DSC01831.JPG" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">17</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/05/im-happy-to-announce.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-8325947815970948056</guid><pubDate>Wed, 06 May 2009 12:59:00 +0000</pubDate><atom:updated>2009-05-26T21:06:05.581+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Web Services</category><title>JAX-WS: Throwing generic SOAPFaults under WLS 10.3</title><description>(With apologies I accidentally deleted this post. This is a repost).&lt;br /&gt;&lt;br /&gt;Typically thanks to the WSDL operations including a &amp;lt;soap:fault&gt; element, when generating JAX-WS 2.1.x endpoints from the WSDL, the JAX-WS engine will also create @WebFault classes to mirror the &amp;lt;soap:fault&gt;. As such the programmer can throw the @WebFault class to cause a SOAP fault to be returned to the caller.&lt;br /&gt;&lt;br /&gt;However what if the WSDL operation doesn't include an explicitly defined fault for the operation? How does the programmer throw a fault without a @WebFault class? The simple answer is add it to the WSDL and regenerate, but some of us don't have that luxury, the WSDLs are given to us.&lt;br /&gt;&lt;br /&gt;If you're using SOAP 1.1 the following code will allow you throw a generic SOAP fault from your JAX-WS endpoint:&lt;pre name="code" class="java"&gt;&lt;br /&gt;SOAPFactory fac = SOAPFactory.newInstance();&lt;br /&gt;SOAPFault sf = fac.createFault("Your error message", new QName("http://schemas.xmlsoap.org/soap/envelope/", "Client"));&lt;br /&gt;throw new SOAPFaultException(sf); &lt;br /&gt;&lt;/pre&gt;Note the QName uses the SOAP 1.1 namespace and "Client" fault code.&lt;br /&gt;&lt;br /&gt;The SOAP 1.2 equivalent code:&lt;pre name="code" class="java"&gt; &lt;br /&gt;SOAPFactory fac = SOAPFactory.newInstance();&lt;br /&gt;SOAPFault sf = fac.createFault("Your error message", new QName("http://www.w3.org/2003/05/soap-envelope", " Receiver"));&lt;br /&gt;throw new SOAPFaultException(sf);&lt;/pre&gt;&lt;br /&gt;In this example the QName uses the SOAP 1.2 namespace and "Receiver" fault code.&lt;br /&gt;&lt;br /&gt;(Later edit – for the record both these mechanisms can also be used in a custom JAX-WS protocol (SOAP handler) or logical handler).&lt;br /&gt;&lt;br /&gt;In the SOAP 1.2 case you'll see something like the following SOAP fault returned from the web service call:&lt;pre name="code" class="xml"&gt; &lt;br /&gt;&lt;s:envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope"&gt;  &lt;br /&gt;   &lt;s:body&gt;  &lt;br /&gt;      &lt;s:fault xmlns:ns4="http://schemas.xmlsoap.org/soap/envelope/"&gt;  &lt;br /&gt;         &lt;s:code&gt;  &lt;br /&gt;            &lt;s:value&gt;S:Receiver&lt;/s:value&gt;  &lt;br /&gt;         &lt;/s:code&gt;  &lt;br /&gt;         &lt;s:reason&gt;  &lt;br /&gt;            &lt;s:text xml:lang="en"&gt;Your error message&lt;/s:text&gt;  &lt;br /&gt;         &lt;/s:reason&gt;  &lt;br /&gt;         &lt;s:detail&gt;  &lt;br /&gt;            &lt;ns2:exception class="java.lang.RuntimeException" note="To disable this feature, set com.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptureStackTrace system property to false" xmlns:ns2="http://jax-ws.dev.java.net/"&gt;  &lt;br /&gt;               &lt;message&gt;javax.xml.ws.soap.SOAPFaultException: Your error message &lt;/message&gt;  &lt;br /&gt;               &lt;ns2:stacktrace&gt;  &lt;br /&gt;                 &lt;!-- stack trace snipped --&gt;  &lt;br /&gt;               &lt;/ns2:stacktrace&gt;  &lt;br /&gt;            &lt;/ns2:exception&gt;  &lt;br /&gt;         &lt;/s:detail&gt;  &lt;br /&gt;      &lt;/s:fault&gt;  &lt;br /&gt;   &lt;/s:body&gt;  &lt;br /&gt;&lt;/s:envelope&gt; &lt;br /&gt;&lt;/pre&gt;Specifically for Oracle's WebLogic Server (WLS) v10.3, we need to make a slight change to the SOAP 1.2 code by supplying the specific SOAP protocol to the SOAPFactory.newInstance call:&lt;pre name="code" class="java"&gt;&lt;br /&gt;SOAPFactory fac = SOAPFactory.newInstance(SOAPConstants.SOAP_1_2_PROTOCOL);&lt;br /&gt;SOAPFault sf = fac.createFault("Your error message", new QName("http://www.w3.org/2003/05/soap-envelope", " Receiver"));&lt;br /&gt;throw new SOAPFaultException(sf);&lt;br /&gt;&lt;/pre&gt;If you don't do this the web service will return an empty HTTP body (though the HTTP header will include a "500 internal server error"), and you'll see the following Java Stack Trace:&lt;pre name="code" class="java"&gt;&lt;br /&gt;java.lang.RuntimeException: javax.xml.ws.soap.SOAPFaultException: Your error message&lt;br /&gt;&lt;br /&gt;6/05/2009 10:18:23 com.sun.xml.internal.messaging.saaj.soap.ver1_1.Fault1_1Impl getFaultSubcodes&lt;br /&gt;SEVERE: SAAJ0303: Operation getFaultSubcodes not supported by SOAP 1.1 &lt;br /&gt;6/05/2009 10:18:23 com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit handle&lt;br /&gt;SEVERE: Not supported in SOAP 1.1&lt;br /&gt;java.lang.UnsupportedOperationException: Not supported in SOAP 1.1&lt;br /&gt; at com.sun.xml.internal.messaging.saaj.soap.ver1_1.Fault1_1Impl.getFaultSubcodes(Fault1_1Impl.java:220)&lt;br /&gt; at com.sun.xml.ws.fault.SOAPFaultBuilder.createSOAP12Fault(SOAPFaultBuilder.java:404)&lt;br /&gt; at com.sun.xml.ws.fault.SOAPFaultBuilder.createSOAPFaultMessage(SOAPFaultBuilder.java:172)&lt;br /&gt; at com.sun.xml.ws.server.WSEndpointImpl$2.process(WSEndpointImpl.java:249)&lt;br /&gt; at com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit.handle(HttpAdapter.java:444)&lt;br /&gt; at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:244)&lt;br /&gt; at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:134)&lt;br /&gt; at weblogic.wsee.jaxws.HttpServletAdapter$AuthorizedInvoke.run(HttpServletAdapter.java:272)&lt;br /&gt; at weblogic.wsee.jaxws.HttpServletAdapter.post(HttpServletAdapter.java:185)&lt;br /&gt; at weblogic.wsee.jaxws.JAXWSServlet.doPost(JAXWSServlet.java:180)&lt;br /&gt; at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)&lt;br /&gt; at weblogic.wsee.jaxws.JAXWSServlet.service(JAXWSServlet.java:64)&lt;br /&gt; at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)&lt;br /&gt; at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)&lt;br /&gt; at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)&lt;br /&gt; at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)&lt;br /&gt; at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)&lt;br /&gt; at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3498)&lt;br /&gt; at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)&lt;br /&gt; at weblogic.security.service.SecurityManager.runAs(Unknown Source)&lt;br /&gt; at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2180)&lt;br /&gt; at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2086)&lt;br /&gt; at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1406)&lt;br /&gt; at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)&lt;br /&gt; at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)&lt;br /&gt;&lt;/pre&gt;(I don't usually include the complete stack trace in a blog post, but in this case the error is so obscure, it'll help others with Google searches)&lt;br /&gt;&lt;br /&gt;I'm currently unclear on why this occurs under WLS. Having tested the original code on Netbeans 6.5 &amp; Glassfish 2, it doesn't have the same issue. I note WLS 10.3 uses JAX-WS 2.1.3 and Glassfish 2 uses JAX-WS 2.1.4, so it may be a simple fix in the later JAX-WS release.&lt;br /&gt;&lt;br /&gt;Thanks very much to &lt;a href="http://kingsfleet.blogspot.com/"&gt;Gerard Davison&lt;/a&gt; from Oracle UK for his assistance on resolving this one.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-8325947815970948056?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/kUqza4I7UH0" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/kUqza4I7UH0/jax-ws-throwing-generic-soapfaults_06.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/05/jax-ws-throwing-generic-soapfaults_06.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-5955813495835543134</guid><pubDate>Tue, 05 May 2009 00:56:00 +0000</pubDate><atom:updated>2009-05-05T08:56:55.638+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Web Services</category><title>JAX-WS: A @SchemaValidation custom handler to alter framework SOAP faults</title><description>A few days ago I &lt;a href="http://one-size-doesnt-fit-all.blogspot.com/2009/04/jax-ws-schemavalidation-suppressing.html"&gt;blogged&lt;/a&gt; about suppressing the SOAP fault detail Java stack trace on WebLogic Server when using the JAX-WS @SchemaValidation annotation for your web services.&lt;br /&gt;&lt;br /&gt;One of the problems with the @SchemaValidation annotation is dependent on the error in your incoming SOAP payload, you may get all sorts of potential errors returned in a SOAP fault.  In some cases it might be useful or a requirement that a generic SOAP fault message be sent back in this case.  How to do this?&lt;br /&gt;&lt;br /&gt;As usual I'm documenting my research and solution here for my own purposes, but hopefully helpful to others.  Your mileage may vary.&lt;br /&gt;&lt;br /&gt;Consider the following JAX-WS endpoint:&lt;br /&gt;&lt;br /&gt;&lt;pre name="code" class="java"&gt;&lt;br /&gt;@WebService&lt;br /&gt;@SchemaValidation&lt;br /&gt;public class WebServiceClass {&lt;br /&gt;&lt;br /&gt;  @WebMethod&lt;br /&gt;  public MyResponse lodgeReport(@WebParam MyRequest request)&lt;br /&gt;    throws GenericSoapFault {&lt;br /&gt;    // do some stuff&lt;br /&gt;  }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;(I've clipped a lot of the detail from above to focus on the specifics)&lt;br /&gt;&lt;br /&gt;Notice the @SchemaValidation annotation.  By default this will enforce that the incoming SOAP payload conforms to the XML schema for the operation.  For instance an invalid payload may throw the following error:&lt;br /&gt;&lt;br /&gt;&lt;pre name="code" class="xml"&gt;&lt;br /&gt;&lt;S:Envelope xmlns:S="http://www.w3.org/2003/05/soap-envelope"&gt;&lt;br /&gt;   &lt;S:Body&gt;&lt;br /&gt;      &lt;S:Fault xmlns:ns4="http://schemas.xmlsoap.org/soap/envelope/"&gt;&lt;br /&gt;         &lt;S:Code&gt;&lt;br /&gt;            &lt;S:Value&gt;S:Receiver&lt;/S:Value&gt;&lt;br /&gt;         &lt;/S:Code&gt;&lt;br /&gt;         &lt;S:Reason&gt;&lt;br /&gt;            &lt;S:Text xml:lang="en"&gt;org.xml.sax.SAXParseException: cvc-datatype-valid.1.2.1: '?' is not a valid value for 'dateTime'.&lt;/S:Text&gt;&lt;br /&gt;         &lt;/S:Reason&gt;&lt;br /&gt;      &lt;/S:Fault&gt;&lt;br /&gt;   &lt;/S:Body&gt;&lt;br /&gt;&lt;/S:Envelope&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Note the reason/text part of the SOAP fault may be virtually any SAXParseException error message depending on the error discovered in the incoming SOAP payload.&lt;br /&gt;&lt;br /&gt;We can however override the @SchemaValidation annotation to specify the actual error handler.  We change the endpoint code as such:&lt;br /&gt;&lt;br /&gt;&lt;pre name="code" class="java"&gt;&lt;br /&gt;@WebService&lt;br /&gt;@SchemaValidation(handler = SchemaValidationErrorHandler.class)&lt;br /&gt;public class WebServiceClass {&lt;br /&gt;&lt;br /&gt;  @WebMethod&lt;br /&gt;  public MyResponse lodgeReport(@WebParam MyRequest request)&lt;br /&gt;    throws GenericSoapFault {&lt;br /&gt;    // do some stuff&lt;br /&gt;  }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Note the handler attribute specifying the SchemaValidationErrorHandler class for the @SchemaValidation annotation.  In turn the SchemaValidationErrorHandler is implemented as follows:&lt;br /&gt;&lt;br /&gt;&lt;pre name="code" class="java"&gt;&lt;br /&gt;import com.sun.xml.ws.developer.ValidationErrorHandler;&lt;br /&gt;import org.xml.sax.SAXParseException;&lt;br /&gt;&lt;br /&gt;public class SchemaValidationErrorHandler extends ValidationErrorHandler {&lt;br /&gt;&lt;br /&gt;  public void warning(SAXParseException exception) { }&lt;br /&gt;&lt;br /&gt;  public void error(SAXParseException exception) {  }&lt;br /&gt;&lt;br /&gt;  public void fatalError(SAXParseException exception) { }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Any warning, error or fatal error for the @SchemaValidation will now be passed through to the methods above.  Remembering our goal to supplement a custom error message for any of the errors above (well, maybe not warning, we'll ignore warnings), we'd like to return our own SOAP fault.  Unfortunately we can't do that from the handler, we need to pass the error back to the endpoint method.  This is done by using the com.sun.xml.ws.api.message.Packet that is available from the ValidationErrorHandler super class.  In essence we can change our handler class as follows:&lt;br /&gt;&lt;br /&gt;&lt;pre name="code" class="java"&gt;&lt;br /&gt;public class SchemaValidationErrorHandler extends ValidationErrorHandler {&lt;br /&gt;&lt;br /&gt;  public static final String WARNING = "SchemaValidationWarning";&lt;br /&gt;  public static final String ERROR = "SchemaValidationError";&lt;br /&gt;  public static final String FATAL_ERROR = "SchemaValidationFatalError";&lt;br /&gt;&lt;br /&gt;  public void warning(SAXParseException exception) {&lt;br /&gt;    packet.invocationProperties.put(WARNING, exception);&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  public void error(SAXParseException exception) {&lt;br /&gt;    packet.invocationProperties.put(ERROR, exception);&lt;br /&gt;  }&lt;br /&gt;&lt;br /&gt;  public void fatalError(SAXParseException exception) {&lt;br /&gt;    packet.invocationProperties.put(FATAL_ERROR, exception);&lt;br /&gt;  }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;I can't for the life of me find the JavaDoc for the Packet class, but what I believe it does is wrap the overall web service message context, and we can drop properties into the packet to be retrieved elsewhere by our JAX-WS solution , specifically our end point.&lt;br /&gt;&lt;br /&gt;Returning to the JAX-WS endpoint we need to inject the web service message context, and then we can retrieve each of the individual errors from the SchemaValidationErrorHandler above:&lt;br /&gt;&lt;br /&gt;&lt;pre name="code" class="java"&gt;&lt;br /&gt;@WebService&lt;br /&gt;@SchemaValidation(handler = SchemaValidationErrorHandler.class)&lt;br /&gt;public class WebServiceClass {&lt;br /&gt;&lt;br /&gt;  @Resource&lt;br /&gt;  WebServiceContext wsContext;&lt;br /&gt;&lt;br /&gt;  @WebMethod&lt;br /&gt;  public MyResponse lodgeReport(@WebParam MyRequest request)&lt;br /&gt;    throws GenericSoapFault {&lt;br /&gt;    &lt;br /&gt;    MessageContext messageContext = wsContext.getMessageContext();&lt;br /&gt;    // We'll ignore warnings&lt;br /&gt;    // SAXParseException warningException = (SAXParseException)messageContext.get(SchemaValidationErrorHandler.WARNING);&lt;br /&gt;    SAXParseException errorException = (SAXParseException)messageContext.get(SchemaValidationErrorHandler.ERROR);&lt;br /&gt;    SAXParseException fatalErrorException =       (SAXParseException)messageContext.get(SchemaValidationErrorHandler.FATAL_ERROR);&lt;br /&gt;&lt;br /&gt;    String errorMessage = null;&lt;br /&gt;&lt;br /&gt;    if (errorException != null)&lt;br /&gt;      errorMessage = errorException.getMessage();&lt;br /&gt;    else if (fatalErrorException != null)&lt;br /&gt;      errorMessage = fatalErrorException.getMessage();&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;     if (errorMessage != null)&lt;br /&gt;       throw new GenericSoapFault(errorMessage);&lt;br /&gt;&lt;br /&gt;     // Otherwise process the request&lt;br /&gt;  }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Note the @Resource annotation in the class injecting the web service context, then within our endpoint method fetching the MessageContext from the wsContext, which gives us the ability to retrieve the properties we inserted in the SchemaValidationErrorHandler class.&lt;br /&gt;&lt;br /&gt;As per the solution above, instead of just checking if the errorMessage is null and passing that to the GenericSoapFault, you could instead replace the SAXParseException with a more generic error message.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-5955813495835543134?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/uBjqEb9g-cU" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/uBjqEb9g-cU/jax-ws-schemavalidation-custom-handler.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/04/jax-ws-schemavalidation-custom-handler.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-7231084464368667317</guid><pubDate>Tue, 28 Apr 2009 02:24:00 +0000</pubDate><atom:updated>2009-04-28T10:25:29.483+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">WebLogic Server</category><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>Standalone WLS ADF deployment – Be careful which URL you use</title><description>We hit a problem with JDeveloper 11g ADF applications deployed to WebLogic Server 10.3 that's worth sharing.&lt;br /&gt;&lt;br /&gt;Under JDev 10.1.3 we could access our remotely deployed ADF applications on OAS through a URL similar to:&lt;br /&gt;&lt;br /&gt;http://host:port/context-root/faces/page.jspx&lt;br /&gt;&lt;br /&gt;...this is in fact how JDev 10.1.3 ran apps on the integrated OAS/OC4J container.&lt;br /&gt;&lt;br /&gt;However on attempting to run a new ADF 11g application on a standalone WebLogic Server, if we used a similar URL as above, then attempted to navigate to any other page via a JSF navigation rule and command control, the original page would show, no navigation would occur, no errors in the logs would be reported.&lt;br /&gt;&lt;br /&gt;It's very hard to debug without an error at least somewhere.  This left us scratching our heads, and a SR to Oracle Support followed.&lt;br /&gt;&lt;br /&gt;Turns out under JDev 11g you cannot include the page file extension in the URL any longer when accessing an ADF application (regardless if it's on an integrated or standalone WLS).  You must use:&lt;br /&gt;&lt;br /&gt;http://host:port/context-root/faces/page&lt;br /&gt;&lt;br /&gt;If I'd carefully looked at how JDev 11g deploys and runs the ADF applications on the integrated WLS I would have realised this because that's what appears in the log window, but I hadn't noticed the subtle change in the URL.  It's possibly something that wouldn't catch somebody new to JDev/ADF, but more likely to catch us old hands out with prior 10.1.3 knowledge.  You're more likely to hit this problem on a standalone WLS as when running applications within JDev it forms the URL for you for the integrated WLS, but on the standalone WLS you need to work it out for yourself.&lt;br /&gt;&lt;br /&gt;Note that the JDev 11g Fusion Guide under &lt;a href="http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/deployment_topics.htm#CIHFEFID"&gt;section 32.9&lt;/a&gt; notes the URL syntax as:&lt;br /&gt;&lt;br /&gt;"http://&amp;lt;host&gt;:port/&amp;lt;context root&gt;/faces/&amp;lt;page&gt;"&lt;br /&gt;&lt;br /&gt;....but what it doesn't bother to note is &amp;lt;page&gt; should be the page name without the file extension.&lt;br /&gt;&lt;br /&gt;Thanks to the Oracle Support staff and the Oracle JDev development team behind the scenes who discovered my error.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-7231084464368667317?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/BgHQ_CoCIA8" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/BgHQ_CoCIA8/standalone-wls-adf-deployment-be.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/04/standalone-wls-adf-deployment-be.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-4725335296102895631</guid><pubDate>Thu, 23 Apr 2009 03:10:00 +0000</pubDate><atom:updated>2009-04-23T11:16:32.467+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">WebLogic Server</category><category domain="http://www.blogger.com/atom/ns#">Web Services</category><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>JAX-WS @SchemaValidation: suppressing the SOAP fault detail Java stack trace on WLS</title><description>This post gives a solution that has been given in numerous other locations and the solution is even fairly obvious, but I needed a location to record it, so here it is.&lt;br /&gt;&lt;br /&gt;Recently &lt;a href="http://kingsfleet.blogspot.com/2009/01/schema-validation-for-jax-ws.html"&gt;Gerard Davison&lt;/a&gt; at Oracle UK detailed the JAX-WS @SchemaValidation tag.&lt;br /&gt;&lt;br /&gt;The default behaviour of Oracle's WebLogic Server 10.3 on receiving a SOAP payload that doesn't conform to the WSDL/XSDs in a JAX-WS endpoint method with the @SchemaValidation annotation is to throw a SOAP fault.&lt;br /&gt;&lt;br /&gt;Under &lt;a href=" http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383507"&gt;SOAP 1.1&lt;/a&gt; the SOAP fault payload returned to the client includes a faultcode, faultstring, faultactor (optional) and detail (optional) component.&lt;br /&gt;&lt;br /&gt;Under &lt;a href="http://www.w3.org/TR/2007/REC-soap12-part1-20070427/#soapfault"&gt;SOAP 1.2&lt;/a&gt; the SOAP fault includes a Code, Reason, Node (optional), Role (optional) and Detail (optional) component.&lt;br /&gt;&lt;br /&gt;Assuming SOAP v1.2, given the @SchemaValidation annotation and invalid SOAP payload, we may see the following SOAP result from our JAX-WS web service:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/Se_clXcTusI/AAAAAAAAAsI/xPqJQH82Jws/s1600-h/pic1.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 133px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/Se_clXcTusI/AAAAAAAAAsI/xPqJQH82Jws/s400/pic1.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5327719418708605634" /&gt;&lt;/a&gt;&lt;br /&gt;(Click the picture to expand it)&lt;br /&gt;&lt;br /&gt;As you can see the SOAP 1.2 fault includes the Code, Reason and Detail components.  As can also been seen the Detail component includes the full Java stack trace(I've snipped the stack trace for brevity).&lt;br /&gt;&lt;br /&gt;It may be undesirable to return the complete Java stack trace in the SOAP fault and you may wish to turn this off.  If you look closely at the error message the answer in how to do this is revealed.  Effectively we need to configure the WLS server to include the following option on startup:&lt;br /&gt;&lt;br /&gt;-Dcom.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptureStackTrace=false&lt;br /&gt;&lt;br /&gt;For WLS 10.3 this entry should be included in your startWebLogic.cmd file.&lt;br /&gt;&lt;br /&gt;For a standalone WLS this file is found under:&lt;br /&gt;&lt;br /&gt;&amp;lt;WLS_HOME&gt;/user_projects/domains/&amp;lt;YOUR_DOMAIN&gt;/bin&lt;br /&gt;&lt;br /&gt;For the integrated WLS within JDeveloper 11g it's found under:&lt;br /&gt;&lt;br /&gt;&amp;lt;JDEV_HOME&gt;\system\system11.1.1.0.31.51.88\DefaultDomain\bin&lt;br /&gt;&lt;br /&gt;Locate the following entry in the startWebLogic.cmd file:&lt;br /&gt;&lt;br /&gt;set JAVA_OPTIONS=%SAVE_JAVA_OPTIONS%&lt;br /&gt;&lt;br /&gt;..and change it to:&lt;br /&gt;&lt;br /&gt;set JAVA_OPTIONS=-Dcom.sun.xml.ws.fault.SOAPFaultBuilder.disableCaptureStackTrace=false %SAVE_JAVA_OPTIONS%&lt;br /&gt;&lt;br /&gt;On restarting the WLS server, and reinvoking the web service with an invalid SOAP payload, the SOAP fault will now look like:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/Se_clUeAb_I/AAAAAAAAAsQ/SOEwcj61Wvo/s1600-h/pic2.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 77px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/Se_clUeAb_I/AAAAAAAAAsQ/SOEwcj61Wvo/s400/pic2.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5327719417910423538" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-4725335296102895631?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/VX8MBASFmZc" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/VX8MBASFmZc/jax-ws-schemavalidation-suppressing.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/_5hhNK2aXwp8/Se_clXcTusI/AAAAAAAAAsI/xPqJQH82Jws/s72-c/pic1.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/04/jax-ws-schemavalidation-suppressing.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-2977537488922760869</guid><pubDate>Wed, 15 Apr 2009 04:57:00 +0000</pubDate><atom:updated>2009-04-15T14:01:59.954+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ADF Faces RC</category><title>ADF Faces RC – displaying user help</title><description>ADF Faces RC under JDeveloper 11g supports different mechanisms for displaying runtime help to users linked with an on-screen component.  I had a chance to play with this today and (once again) thought I'd document my findings here as I found the Oracle documentation somewhat confusing (or maybe it's just me).&lt;br /&gt;&lt;br /&gt;The Oracle documentation that describes how to get this working can be found in section &lt;a href="http://download.oracle.com/docs/cd/E12839_01/web.1111/b31973/af_message.htm#CHDHIGIA"&gt;16.5 Displaying Help for Components&lt;/a&gt; of the Oracle &lt;a href="http://download.oracle.com/docs/cd/E12839_01/web.1111/b31973/toc.htm"&gt;JDev 11g Fusion Web Developer's Guide&lt;/a&gt;.  It's worth noting you should read the entire section &lt;a href="http://download.oracle.com/docs/cd/E12839_01/web.1111/b31973/af_message.htm#CACCFEFA"&gt;16 Displaying Tips, Messages, and Help&lt;/a&gt; as there are a few assumptions in section 16.5 that you've read the earlier parts.&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;br /&gt;Help types&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;A subset of the ADF Faces RC components include support for displaying help, through the inclusion of the helpTopicId attribute on the component's tag.&lt;br /&gt;&lt;br /&gt;ADF Faces RC provides for 3 different help types for the components that support help:&lt;br /&gt;&lt;br /&gt;· Definition – places a question mark icon near the component which when the user hovers the mouse over the component, help text is displayed.  The exact location of the question mark icon relative to the component depends on the type of component.  Section 16.5 of the Oracle documentation dictates this.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVqawv4S_I/AAAAAAAAAq4/Zags2a8dZGQ/s1600-h/pic1.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 393px; height: 79px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVqawv4S_I/AAAAAAAAAq4/Zags2a8dZGQ/s400/pic1.png" alt="" id="BLOGGER_PHOTO_ID_5324779142430346226" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;· Instructions – typically displays a note window (that looks like a speech bubble) over the component when the user clicks in the field, where the note window shows the help text.  For panel headers and query object components the help text appears inline with the component rather than as a note window.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVr86SwvnI/AAAAAAAAArA/z80ZJmYXK80/s1600-h/pic2.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 400px; height: 60px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVr86SwvnI/AAAAAAAAArA/z80ZJmYXK80/s400/pic2.png" alt="" id="BLOGGER_PHOTO_ID_5324780828619751026" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;· External URL – displays a similar question mark icon to the "Definition" help type above, except when the user clicks on the icon (rather than hovers over the icon with the mouse pointer), launches a separate browser window opening an external URL.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SeVwBmP_eeI/AAAAAAAAArI/iI1b3Nwo92g/s1600-h/pic3.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 246px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SeVwBmP_eeI/AAAAAAAAArI/iI1b3Nwo92g/s400/pic3.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324785307185281506" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Providing Definition or Instructions based help&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The setup for providing either Definition or Instructions based help is as follows:&lt;br /&gt;&lt;br /&gt;1. Within your ViewController project create a Java class that extends oracle.adf.view.rich.help.ResourceBundleHelpProvider.  In the following example I've created the class MyHelpProvider under the package view.help&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SeVw1ndvVWI/AAAAAAAAArQ/VLrNJjFEYxw/s1600-h/pic4.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 127px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SeVw1ndvVWI/AAAAAAAAArQ/VLrNJjFEYxw/s400/pic4.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324786200864576866" /&gt;&lt;/a&gt;&lt;br /&gt;2. We next need to create the file adf-settings.xml to configure the custom ResoureBundleHelpProvider.  This file is meant to go under the ADF META-INF node in the Application Resources options within the Application Navigator:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SeVxtiXcZUI/AAAAAAAAArY/bTWCDgYY6F0/s1600-h/pic5.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 333px; height: 385px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SeVxtiXcZUI/AAAAAAAAArY/bTWCDgYY6F0/s400/pic5.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324787161568666946" /&gt;&lt;/a&gt;&lt;br /&gt;Unfortunately I can't find an easy way to create this file under this node.  The easiest way seems to be to locate the &amp;lt;app_dir&gt;\.adf\META-INF directory under Windows explorer or similar, and manually create the XML file in there.  Once done return to JDeveloper and restart it.  On JDeveloper reopening you should see the file added as per above.&lt;br /&gt;&lt;br /&gt;(The Oracle documentation is incorrect in instructing you to create the adf-settings.xml file under the ViewController's META-INF directory.  It should be the &amp;lt;app_dir&gt;\.adf\META-INF directory as specified above).&lt;br /&gt;&lt;br /&gt;The contents of the adf-settings.xml file are as follows:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SeVygRgvfZI/AAAAAAAAArg/ZNhrUbiU4g8/s1600-h/pic6.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 187px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SeVygRgvfZI/AAAAAAAAArg/ZNhrUbiU4g8/s400/pic6.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324788033217592722" /&gt;&lt;/a&gt;&lt;br /&gt;Note the help-provider-class mapping that points to the package.name of our Java class, namely view.help.MyHelpProvider.&lt;br /&gt;&lt;br /&gt;The &amp;lt;property&gt;'s tags define the resource properties file that contain our help text to display for each help-enabled component.  In this example I've created a file helpFile.properties (the extension is dropped in the adf-settings.xml file) in the view.resources package.  We'll look at this next.  The property-name as far as I can tell can be anything you want and has no effect elsewher. I'm not entirely sure why it's included; presumably it's possible to have multiple resource files?&lt;br /&gt;&lt;br /&gt;3. The contents of helpFile.properties file are as follows:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVysrD5BRI/AAAAAAAAAro/kIbof8XHTzQ/s1600-h/pic7.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 91px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVysrD5BRI/AAAAAAAAAro/kIbof8XHTzQ/s400/pic7.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324788246234334482" /&gt;&lt;/a&gt;&lt;br /&gt;As you can see in the properties file we have key-value pairs, specifically the help ID and the associated text.  Of special note, see that each key is either completed with the word DEFINITION or INSTRUCTIONS.  It is this that determines the help type for the component.  (Somewhat confusingly INSTRUCTIONS is a plural, and DEFINTION is singular)&lt;br /&gt;&lt;br /&gt;4. Finally we need to bind the help key from the properties file to the actual ADF Faces RC component on a web page:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/SeV07dI_v8I/AAAAAAAAArw/vtPxDQm6t6c/s1600-h/pic8.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 206px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/SeV07dI_v8I/AAAAAAAAArw/vtPxDQm6t6c/s400/pic8.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324790699218943938" /&gt;&lt;/a&gt;&lt;br /&gt;Note for the 2 input text controls above the helpTopicId parameter.  Note how these map back to what I had in the properties file minus the DEFINITION or INSTRUCTIONS suffix.  Those suffixes are only included in the properties file.  As such the properties file determines the behaviour of the help and components in this case.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Providing External URL based help&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;To configure the external URL help type we return to our custom MyHelpProvider class and override the super getExternalUrl method as follows:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeV1OaGyPgI/AAAAAAAAAr4/KGJDHKcNCrU/s1600-h/pic9.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 272px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeV1OaGyPgI/AAAAAAAAAr4/KGJDHKcNCrU/s400/pic9.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324791024821878274" /&gt;&lt;/a&gt;&lt;br /&gt;In the 2nd if statement we've added the ability to capture the helpTopicId and return an alternative URL which will be used for the new browser window.  As you add more components that require help, you simply add more if statements with associated URLs.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Further functionality&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;If you wish to configure multiple helper classes the adf-settings.xml file allows you to include a filter via the prefix attribute on the help-provider tag as follows:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SeV31fYRg5I/AAAAAAAAAsA/pw4Y0kKdt_8/s1600-h/pic10.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 179px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SeV31fYRg5I/AAAAAAAAAsA/pw4Y0kKdt_8/s400/pic10.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5324793895275561874" /&gt;&lt;/a&gt;&lt;br /&gt;In this case only helpTopicIds with the prefix MYHELP_ will be passed to the MyHelpProvider class.&lt;br /&gt;&lt;br /&gt;In addition the Oracle documentation specifies how to use a managed bean help file, which is relatively simple, or XLIFF based help files.  I don't have any experience with XLIFF files so I'll leave readers to read the Oracle documentation.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Credit&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Thanks to user518058 and Frank Nimphius on the &lt;a href="http://forums.oracle.com/forums/thread.jspa?threadID=870363&amp;amp;tstart=0"&gt;JDev OTN Forums&lt;/a&gt; for posting about a couple of the implementation issues with the user-help.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-2977537488922760869?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/DgrqAWMMhJk" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/DgrqAWMMhJk/adf-faces-rc-displaying-user-help.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_5hhNK2aXwp8/SeVqawv4S_I/AAAAAAAAAq4/Zags2a8dZGQ/s72-c/pic1.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/04/adf-faces-rc-displaying-user-help.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-7544247251736677829</guid><pubDate>Tue, 31 Mar 2009 08:34:00 +0000</pubDate><atom:updated>2009-03-31T16:59:21.020+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">WebLogic Server</category><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>JNDI failure for WLS deployed ADF applications</title><description>One runtime error I've hit a few times now when setting up an ADF application to use a JNDI Data Source via WebLogic Server (WLS) is the following:&lt;br /&gt;&lt;br /&gt;(I'll document this issue here to save myself grief later on and hopefully help a few other people out)&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SdHZDtR1rNI/AAAAAAAAAqQ/mhL4xz-w8N8/s1600-h/pic0.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 279px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SdHZDtR1rNI/AAAAAAAAAqQ/mhL4xz-w8N8/s400/pic0.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5319271292618517714" /&gt;&lt;/a&gt;&lt;br /&gt;The specific error text:&lt;br /&gt;&lt;br /&gt;JNDI failure. Unable to lookup Data Source at context jdbc/appDS&lt;br /&gt;Unable to resolve 'jdbc.appDS'. Resolved 'jdbc'.&lt;br /&gt;&lt;br /&gt;Note that the text "jdbc/appDS" or "jdbc.appDS" may differ in your specific case dependent on what you did in the following steps.&lt;br /&gt;&lt;br /&gt;The error comes about as I've:&lt;br /&gt;&lt;br /&gt;1) Modified my ADF BC Application Module AppModuleLocal configuration to use a JDBC DataSource connection type, specifying a datasource name of jdbc/appDS.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SdHZI0PMg-I/AAAAAAAAAqY/tVIFEOcNnhk/s1600-h/pic1.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 391px; height: 400px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SdHZI0PMg-I/AAAAAAAAAqY/tVIFEOcNnhk/s400/pic1.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5319271380385825762" /&gt;&lt;/a&gt;&lt;br /&gt;Accessed via Model project -&gt; Application Module right click -&gt; Configurations -&gt; select AppModuleLocal then Edit button -&gt; Application Module tab.&lt;br /&gt;&lt;br /&gt;2) On the WebLogic Server I've created a data source as following:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_5hhNK2aXwp8/SdHZtWKx2kI/AAAAAAAAAqg/gQt-iyuNUiw/s1600-h/pic2.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 344px;" src="http://2.bp.blogspot.com/_5hhNK2aXwp8/SdHZtWKx2kI/AAAAAAAAAqg/gQt-iyuNUiw/s400/pic2.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5319272007969397314" /&gt;&lt;/a&gt;&lt;br /&gt;This is accessed via opening your WLS console + logging in -&gt; Domain Structure -&gt; Services -&gt; JDBC -&gt; Data Sources.&lt;br /&gt;&lt;br /&gt;First note the AppDataSource that I've created, then the JNDI Name that maps back to that specified in the previous step.&lt;br /&gt;&lt;br /&gt;Then note that the Targets entry is empty for my configured data source.  Effectively I've created the data source in WLS but forgotten to assign it to any WLS server and in this case is what's causing my problem.&lt;br /&gt;&lt;br /&gt;To rectify this I click on the data source name -&gt; Targets tab then assign the data source to each server I'm interested in (in this case just the JDev 11g integrated WLS DefaultServer):&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SdHas4uCLiI/AAAAAAAAAqo/aGD37x5537Q/s1600-h/pic3.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 344px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SdHas4uCLiI/AAAAAAAAAqo/aGD37x5537Q/s400/pic3.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5319273099575832098" /&gt;&lt;/a&gt;&lt;br /&gt;On saving the changes and returning to the Data Sources page you should see:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_5hhNK2aXwp8/SdHa0aQ4A4I/AAAAAAAAAqw/m25CrdElslg/s1600-h/pic4.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 344px;" src="http://1.bp.blogspot.com/_5hhNK2aXwp8/SdHa0aQ4A4I/AAAAAAAAAqw/m25CrdElslg/s400/pic4.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5319273228839420802" /&gt;&lt;/a&gt;&lt;br /&gt;And the problem should now be resolved.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-7544247251736677829?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/xQWeC2x4rUw" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/xQWeC2x4rUw/jndi-failure-for-wls-deployed-adf.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_5hhNK2aXwp8/SdHZDtR1rNI/AAAAAAAAAqQ/mhL4xz-w8N8/s72-c/pic0.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/03/jndi-failure-for-wls-deployed-adf.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-2081682130257423621</guid><pubDate>Fri, 20 Mar 2009 02:11:00 +0000</pubDate><atom:updated>2009-03-20T11:17:55.182+09:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ADF Business Components</category><title>ADF BC: Using Groovy to fetch sequence numbers Part II</title><description>I recently posted &lt;a href="http://one-size-doesnt-fit-all.blogspot.com/2009/03/adf-bc-using-groovy-to-fetch-sequence.html"&gt;ADF BC: Using Groovy to fetch sequence numbers for EO/VO attribute default values&lt;/a&gt;.  This post showed the power of what you can get away with in the new Groovy expressions of ADF Business Components in JDeveloper 11g.&lt;br /&gt;&lt;br /&gt;Though power is good (muhahaha!, um, cough), simple is better. &lt;br /&gt;&lt;br /&gt;&lt;a href="http://radio.weblogs.com/0118231/"&gt;Steve Muench&lt;/a&gt; suggested the following to make retrieving sequence numbers a breeze via the Groovy expression facilities.&lt;br /&gt;&lt;br /&gt;Readers will be familiar with the common recommendation for ADF Business Components to create a layer of framework extensions, as per &lt;a href="http://download.oracle.com/docs/cd/E12839_01/web.1111/b31974/bcadvgen.htm#insertedID2"&gt;Section 33.2&lt;/a&gt; of the JDeveloper 11g Fusion Guide.&lt;br /&gt;&lt;br /&gt;With this in mind we can create the following helper method seqNextVal() to fetch the next value for a named sequence in our custom EntityImpl:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/ScL8C8UHqtI/AAAAAAAAAqA/iaPkISwSwcI/s1600-h/seqNextValCode.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 321px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/ScL8C8UHqtI/AAAAAAAAAqA/iaPkISwSwcI/s400/seqNextValCode.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5315087637731060434" /&gt;&lt;/a&gt;&lt;br /&gt;...which we can then make use of in our Groovy expression in the Entity Object attribute's default value field:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_5hhNK2aXwp8/ScL8DeCmPNI/AAAAAAAAAqI/4z7tfyHC550/s1600-h/attrDialog.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 250px;" src="http://4.bp.blogspot.com/_5hhNK2aXwp8/ScL8DeCmPNI/AAAAAAAAAqI/4z7tfyHC550/s400/attrDialog.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5315087646784371922" /&gt;&lt;/a&gt;&lt;br /&gt;Remember to set the Value Type = Expression.&lt;br /&gt;&lt;br /&gt;Thanks to Steve for his suggestion.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-2081682130257423621?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/uRC08k_f2gE" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/uRC08k_f2gE/adf-bc-using-groovy-to-fetch-sequence_20.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_5hhNK2aXwp8/ScL8C8UHqtI/AAAAAAAAAqA/iaPkISwSwcI/s72-c/seqNextValCode.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/03/adf-bc-using-groovy-to-fetch-sequence_20.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-5462197727755145210</guid><pubDate>Tue, 17 Mar 2009 10:58:00 +0000</pubDate><atom:updated>2009-03-17T19:59:53.256+09:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>Advert: AUSOUG-Western Australia: Why You can No Longer Avoid JDeveloper</title><description>&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;&lt;span class='newsItem'&gt;&lt;div style='margin: 0cm 0cm 10pt; line-height: normal;'&gt;&lt;span class='newsItem'&gt;&lt;span class='newsItem'&gt;&lt;span style='font-size: 10pt;'&gt;Oracle are building their Fusion Application suite using JDeveloper and the ADF framework. If we think about how long Oracle Forms has been a core development product for Oracle it seems obvious that this new platform will have similar relevance.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br/&gt;&lt;span style='font-size: 10pt;'&gt;&lt;br/&gt;A confirmed JDeveloper cynic, Penny Cookson has finally been bitten by the JDeveloper bug, and like any Oracle geek can be found playing with the new features in her office in the small hours of the morning (CM - really, it's true ;-)&lt;br/&gt;&lt;/span&gt;&lt;/div&gt; &lt;div style='margin: 0cm 0cm 10pt; line-height: normal;'&gt;&lt;span style='font-size: 10pt;'&gt;If you're interested in learning why Penny, a long time Apex advocate is now preaching about JDeveloper, and you're located in Perth Western Australia, join us on April 2nd to hear Penny's &lt;a href='http://www.ausoug.org.au/wa'&gt;AUSOUG-WA&lt;/a&gt; presentation about JDeveloper 11g.  Penny will discuss&lt;/span&gt;&lt;span class='newsItem'&gt;&lt;span class='newsItem'&gt;&lt;span style='font-size: 10pt;'&gt; why you should look at JDeveloper and demonstrate some of the smart and cute new features in JDeveloper 11g.&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;br/&gt;&lt;span style='font-size: 10pt;'&gt;&lt;br/&gt;More details about the event can be found &lt;a href='http://www.ausoug.org.au/pls/portal30/docs/FOLDER/WACONTENTAREA/EBULLETINS/EBULLETINMAR2009.HTML'&gt;here&lt;/a&gt;.&lt;br/&gt;&lt;br/&gt;AUSOUG-Western Australia is also looking for more presenters at their monthly meetings.  If you're interested in presenting please drop me an email.  Email me at chrisSTOPmuirATsagecomputingSTOPcomSTOPau.&lt;br/&gt;&lt;/span&gt;&lt;/div&gt;&lt;/span&gt;&lt;br/&gt;&lt;br/&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-5462197727755145210?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/5pgqzB7l_kg" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/5pgqzB7l_kg/advert-ausoug-western-australia-why-you.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/03/advert-ausoug-western-australia-why-you.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-8186387614874068546</guid><pubDate>Tue, 10 Mar 2009 04:07:00 +0000</pubDate><atom:updated>2009-03-10T13:14:24.786+09:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ADF Business Components</category><title>ADF BC: Using Groovy to fetch sequence numbers for EO/VO attribute default values</title><description>&lt;div xmlns='http://www.w3.org/1999/xhtml'&gt;I've recently been fooling around with the new ADF Business Component support for Groovy expressions in JDeveloper 11g, and thought I'd share the following discovery.&lt;br/&gt;&lt;br/&gt;(Usual caveat this hasn't yet been tested in a production system, so your mileage may vary)&lt;br/&gt;&lt;br/&gt;JDeveloper's ADF BC supports a number of different mechanisms to fetch database sequence numbers for Entity Object &amp;amp; View Object primary key attributes when a new record is created.&lt;br/&gt;&lt;br/&gt;One such method is to override the create(AttributeList) method in the Entity Object and include the following Java code:&lt;br/&gt;&lt;br/&gt;&lt;font face='Courier New'&gt;@Override&lt;br/&gt;public void create(AttributeList attributeList) {&lt;br/&gt;  super.create(attributeList);&lt;br/&gt;   SequenceImpl seq = new SequenceImpl("LOG_SEQ", getDBTransaction());&lt;br/&gt;   Number seqNextval = seq.getSequenceNumber();&lt;br/&gt;   setId(seqNextval);&lt;br/&gt;}&lt;/font&gt;&lt;br/&gt;&lt;br/&gt;This example retrieves the next value from the database's LOG_SEQ sequence and writes it to the local Entity Object's ID attribute via a call to setId().&lt;br/&gt;&lt;br/&gt;This minor piece of code can now be replaced with a Groovy expression in JDeveloper 11g's ADF Business Components.&lt;br/&gt;&lt;br/&gt;If we open the Entity Object editor, then double click the primary key attribute we're interested in populating with the sequence number, we can now enter the following Groovy expression for the Value field with the Expression radio button selected:&lt;br/&gt;&lt;br/&gt;&lt;font face='Courier New'&gt;(new oracle.jbo.server.SequenceImpl("LOG_SEQ", (cont)&lt;br/&gt;object.getDBTransaction())). (cont)&lt;br/&gt;getSequenceNumber()&lt;/font&gt;&lt;br/&gt;&lt;div class='ii gt' id=':12'&gt; &lt;br/&gt;The following picture shows the entry in context of the Edit Attribute dialog:&lt;br/&gt;&lt;br/&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SbXoPyVMn1I/AAAAAAAAAp4/GyA7OTnSbYs/s1600-h/groovy.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 240px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SbXoPyVMn1I/AAAAAAAAAp4/GyA7OTnSbYs/s400/groovy.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5311406693459730258" /&gt;&lt;/a&gt;Note in the expression how we must explicitely name the package + Java class for the SequenceImpl as we don't have a mechanism for importing classes in the simple Groovy expression.  In addition for the getDBTransaction() call we need to make reference to the Groovy "object" expression (or is that class? Whatever).  "object" passes a copy of the Entity Object class to the Groovy expression evaluator allowing it to call methods of the Entity Object, in this example getDBTransaction().  More information on Groovy expressions can be found in Steve Muench's following blog &lt;a href='http://radio.weblogs.com/0118231/2007/05/22.html'&gt;post&lt;/a&gt;.&lt;br/&gt;&lt;br/&gt;The advantage of this Groovy approach is one less reason to code in Java in JDeveloper if you feel the desire (though the Java code example from above isn't exactly difficult).  The disadvantage of this approach, I can imagine it would be difficult to debug if something went wrong.&lt;br/&gt;&lt;br/&gt;In conclusion we can see the power of the new Groovy expressions supported through JDeveloper 11g and ADF Business Components.&lt;/div&gt;&lt;/div&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-8186387614874068546?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/Rv88bHypKkg" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/Rv88bHypKkg/adf-bc-using-groovy-to-fetch-sequence.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_5hhNK2aXwp8/SbXoPyVMn1I/AAAAAAAAAp4/GyA7OTnSbYs/s72-c/groovy.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/03/adf-bc-using-groovy-to-fetch-sequence.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-1179628986452152645</guid><pubDate>Thu, 05 Mar 2009 07:05:00 +0000</pubDate><atom:updated>2009-03-05T16:14:11.199+09:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ADF Enterprise Methodology Group</category><title>Join 180 members of the ADF Enterprise Methodology Group (+ minor name change)</title><description>Just a small note for the millions of my readers (hi Mum!) who care about such, that the ADF Methodology group (that's group with a lower g) has been renamed the ADF Enterprise Methodology Group (that's group with an upper G) to better reflect, um, well if you're really interested it's documented &lt;a href="http://groups.google.com/group/adf-methodology/msg/07f96f3886912362?hl=en"&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;(It would be appreciated if Oracle employee's in charge of websites and similar that link to the original group could update any link names please)&lt;br /&gt;&lt;br /&gt;For those who'd like to know more about the group, following is a little marketing spin to drag you in:&lt;br /&gt;&lt;br /&gt;You can easily tell when a tool has matured to being a productive environment. Software developers move from playing and learning features, to supporting production systems and discussing best practices and development methodologies to ensure the success of their next project.&lt;br /&gt;&lt;br /&gt;The ADF Enterprise Methodology Group is such a place for community discussions based around JDeveloper best practices and methodologies for ADF Enterprise development. On a day by day bases ADF "experts" (that's anyone that knows what ADF stands for ;-) chat about high level ADF concepts, beyond the how-do-I-get-it-to-work posts on the OTN JDeveloper Forums.&lt;br /&gt;&lt;br /&gt;If you'd like to discuss best practices, steps and processes for a successful ADF project, please join us at:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://groups.google.com/group/adf-methodology"&gt;http://groups.google.com/group/adf-methodology&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;We look forward to talking to you on the group soon.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-1179628986452152645?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/pdjXZmWCYJo" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/pdjXZmWCYJo/join-180-members-of-adf-enterprise.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/03/join-180-members-of-adf-enterprise.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-3617841523056090549</guid><pubDate>Tue, 03 Mar 2009 01:35:00 +0000</pubDate><atom:updated>2009-03-03T10:53:21.905+09:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>JDev IDE: defaulting to the source code editor for web pages</title><description>Recently &lt;a href="http://adfjsf.blogspot.com/"&gt;Vivek Kumar&lt;/a&gt; posted about &lt;a href="http://adfjsf.blogspot.com/2009/02/improving-performance-in-jdeveloper-11g.html"&gt;Improving Performance in JDeveloper 11g&lt;/a&gt;.  Among other suggestions his second one caught my eye: "Configure JDeveloper to open jsp/jsff's in source view".  This particular suggestion applies not only to JDev 11g, but also JDev 10g (and possibly earlier versions too, none of which I have installed to check).  Unfortunately Vivek didn't give details of how to configure this so I thought I'd do it here.&lt;br /&gt;&lt;br /&gt;On opening a web page in the IDE, there is a noticable delay while JDev initializes the WYSIWYG design editor.  This becomes painful if you want to only make a small code change in the web page's source code.  It becomes doubly painful as there is an infrequent bug in JDev 11g build 5188 where the design editor refuses to show the page's contents unless you flick between the source code and design editor views.&lt;br /&gt;&lt;br /&gt;As such Vivek's suggestion took my eye and reminded me we can easily change the default behaviour of JDev to open web pages in the source code editor instead, to avoid these minor annoyances.&lt;br /&gt;&lt;br /&gt;The option to do this is under the Preferences dialog invoked via the Tools menu, then selecting the File Types node:&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_5hhNK2aXwp8/SayKuTs7EiI/AAAAAAAAApw/bka8-iq0evA/s1600-h/picFileTypes.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 286px;" src="http://3.bp.blogspot.com/_5hhNK2aXwp8/SayKuTs7EiI/AAAAAAAAApw/bka8-iq0evA/s400/picFileTypes.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5308770588930282018" /&gt;&lt;/a&gt;&lt;br /&gt;As can be seen from the above picture, selecting the Default Editors tab displays all the different file types JDeveloper works with.  For standard JSF pages with an extension of .jsp or .jspx, we can select the JSP Source option and switch its Default Editor option from Design to Source as I've done in this example.  &lt;br /&gt;&lt;br /&gt;One minor caveat to note is JDeveloper does remember for each file what editor type you were last using, so this change only applies to new files.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-3617841523056090549?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/3DHLOXeSseo" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/3DHLOXeSseo/jdev-ide-defaulting-to-source-code.html</link><author>noreply@blogger.com (Chris Muir)</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/_5hhNK2aXwp8/SayKuTs7EiI/AAAAAAAAApw/bka8-iq0evA/s72-c/picFileTypes.png" height="72" width="72" /><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">1</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/03/jdev-ide-defaulting-to-source-code.html</feedburner:origLink></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-38586079.post-7666960468510147711</guid><pubDate>Wed, 18 Feb 2009 06:54:00 +0000</pubDate><atom:updated>2009-02-18T16:13:26.217+09:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Training</category><category domain="http://www.blogger.com/atom/ns#">JDeveloper</category><title>Advert: JDeveloper 11g training course</title><description>I'm very happy to announce the arrival of our 5 day JDeveloper 11g training course in Australia.&lt;br /&gt;&lt;br /&gt;At &lt;a href="http://www.sagecomputing.com.au/"&gt;SAGE Computing Services&lt;/a&gt; we've updated our JDeveloper 10.1.3 course to include the latest ADF Business Component and ADF Faces Rich Client technologies bundled with JDeveloper 11g, the core technology set behind Oracle's upcoming Fusion Applications.&lt;br /&gt;&lt;br /&gt;This training course has been updated in conjunction with Netherland's Fusion Middleware and Oracle specialists &lt;a href="http://www.amis-uk.com/"&gt;AMIS&lt;/a&gt;, drawing upon Fusion expertise from both sides of the globe.  We're very excited by this relationship, formed by Oracle ACE Directors Lucas Jellema and myself Chris Muir, and much hard work behind the scenes by both AMIS and SAGE staff (my extensive thanks to all involved).&lt;br /&gt;&lt;br /&gt;If my Google searches prove correct, we may be the first organisations in the world to provide comprehensive ADF BC/ADF Faces RC JDeveloper 11g training besides Oracle itself, a great achievement in my honest opinion.&lt;br /&gt;&lt;br /&gt;Interested in checking out our course?&lt;br /&gt;&lt;br /&gt;View the complete course agenda in our &lt;a href="http://www.sagecomputing.com.au/courses/COURSES.pdf"&gt;course catalogue&lt;/a&gt; or visit our &lt;a href="http://www.sagecomputing.com.au/oracle_training_australia.html"&gt;training&lt;/a&gt; web page for more information.&lt;br /&gt;&lt;br /&gt;Also check out SAGE's other latest Oracle 11g training courses in Australia including:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;11g New Features for Developers (1 day)&lt;/li&gt;&lt;li&gt;SQL 11g (4 days)&lt;/li&gt;&lt;li&gt;    PL/SQL 11g (3 days)&lt;/li&gt;&lt;li&gt;Application Tuning 11g (3 days)&lt;/li&gt;&lt;li&gt;Database Administration 11g (5 days)&lt;/li&gt;&lt;/ul&gt;... plus all your favourite previous versions and other Oracle products, we have most of them, even Oracle Browser would you believe?!&lt;br /&gt;&lt;br /&gt;For further enquiries hit our web site and follow the &lt;a href="http://www.sagecomputing.com.au/contact_sage_computing_services.html"&gt;contact us&lt;/a&gt; details.  We look forward to hearing from you soon.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/38586079-7666960468510147711?l=one-size-doesnt-fit-all.blogspot.com'/&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/OneSizeDoesntFitAll/~4/d2ZFC0FyK2s" height="1" width="1"/&gt;</description><link>http://feedproxy.google.com/~r/OneSizeDoesntFitAll/~3/d2ZFC0FyK2s/advert-jdeveloper-11g-training-course.html</link><author>noreply@blogger.com (Chris Muir)</author><thr:total xmlns:thr="http://purl.org/syndication/thread/1.0">0</thr:total><feedburner:origLink>http://one-size-doesnt-fit-all.blogspot.com/2009/02/advert-jdeveloper-11g-training-course.html</feedburner:origLink></item></channel></rss>
