<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6616712419102560713</id><updated>2024-08-31T19:41:12.213+05:30</updated><category term="wicket"/><category term="oracle 8.1.7"/><category term="spring"/><category term="sql server"/><category term="ajax"/><category term="apache"/><category term="eclipse"/><category term="excel"/><category term="free"/><category term="horizontal result set"/><category term="java fx"/><category term="jdk"/><category term="multiple daos"/><category term="multiple datasources"/><category term="value"/><category term="weblogic"/><category term="windows"/><category term="1.3.7"/><category term="add"/><category term="analytics"/><category term="annotations"/><category term="ant"/><category term="auto"/><category term="autowire"/><category term="awr report"/><category term="boot"/><category term="castor"/><category term="chain"/><category term="change"/><category term="classes"/><category term="collation"/><category term="collections"/><category term="comparator"/><category term="compatible"/><category term="complete"/><category term="concurrent"/><category term="container"/><category term="content"/><category term="creat"/><category term="data source"/><category term="database"/><category term="debug"/><category term="design"/><category term="desktop"/><category term="display"/><category term="div"/><category term="driver"/><category term="dump"/><category term="ear"/><category term="efficient"/><category term="esb"/><category term="europa"/><category term="execution plans"/><category term="explain plan"/><category term="faq"/><category term="features"/><category term="files"/><category term="firefox"/><category term="form"/><category term="forum"/><category term="galileo"/><category term="google"/><category term="heap"/><category term="hints"/><category term="hosting"/><category term="ie"/><category term="incompatible"/><category term="indexes"/><category term="intellij"/><category term="jdbc"/><category term="jrmc"/><category term="jrockit"/><category term="key"/><category term="management studio"/><category term="map"/><category term="metainf"/><category term="migration"/><category term="mockups"/><category term="modal window"/><category term="multi"/><category term="mysql"/><category term="nested modal window"/><category term="net beans"/><category term="netbeans"/><category term="not visible"/><category term="ojdbc"/><category term="old"/><category term="onclick"/><category term="onsubmit"/><category term="open source"/><category term="oracle"/><category term="panel"/><category term="parent"/><category term="password"/><category term="pdf"/><category term="pencil"/><category term="performance"/><category term="pivot"/><category term="plugin"/><category term="png"/><category term="prefer"/><category term="profiling"/><category term="programatically"/><category term="project"/><category term="qualifier"/><category term="real"/><category term="remote"/><category term="rest"/><category term="rpc"/><category term="runtime"/><category term="save"/><category term="scroll"/><category term="server start"/><category term="session"/><category term="sid"/><category term="single datasource connection suppressclose"/><category term="soa"/><category term="soap"/><category term="sqlyog"/><category term="stackoverflow"/><category term="standalone"/><category term="switch"/><category term="testng . junit"/><category term="tracing"/><category term="tracking"/><category term="tuning"/><category term="unit . test"/><category term="username"/><category term="util"/><category term="version"/><category term="view"/><category term="visitor"/><category term="visualvm"/><category term="vnc"/><category term="web page"/><category term="web service"/><category term="weblogic 10.3"/><category term="weblogic-application"/><category term="website"/><category term="work"/><category term="xml beans"/><category term="z-index"/><title type='text'>Some facts I have known about coding</title><subtitle type='html'>I guess this is a page to share all issues I have troubleshooted and found interesting enough to share.&#xa;&#xa;Also a place to give back something , in return of all the help I have received or taken from forums.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default?redirect=false'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default?start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>32</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-3164878987082101167</id><published>2013-03-06T16:48:00.000+05:30</published><updated>2013-03-06T16:48:14.920+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="awr report"/><category scheme="http://www.blogger.com/atom/ns#" term="execution plans"/><category scheme="http://www.blogger.com/atom/ns#" term="explain plan"/><category scheme="http://www.blogger.com/atom/ns#" term="hints"/><category scheme="http://www.blogger.com/atom/ns#" term="indexes"/><category scheme="http://www.blogger.com/atom/ns#" term="oracle"/><category scheme="http://www.blogger.com/atom/ns#" term="performance"/><category scheme="http://www.blogger.com/atom/ns#" term="profiling"/><category scheme="http://www.blogger.com/atom/ns#" term="sid"/><category scheme="http://www.blogger.com/atom/ns#" term="tracing"/><category scheme="http://www.blogger.com/atom/ns#" term="tuning"/><title type='text'>Oracle - Execution Plans , Explain Plans, AWR Reports, Tuning  - A handy Guide</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
There is an inherent different between explain plans and execution plans , and I almost got confused that they were the same.&lt;br /&gt;
&lt;br /&gt;
In order to capture an execution plan , we need to follow the steps:&lt;br /&gt;
&lt;br /&gt;
The user who will be running the sql for which you want the execution plan , should have permissions to alter session in order to enable trace.(This is not mandatory , if you can run the sqls via the user who has permissions then that is also fine)&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
Grant permission:&lt;/h2&gt;
grant alter session to &lt;user&gt;;&lt;/user&gt;&lt;br /&gt;
revoke alter session from &lt;user&gt;;&lt;/user&gt;&lt;br /&gt;
&lt;h2&gt;
Enable SQL TRACING&lt;/h2&gt;
&lt;div&gt;
To enable Trace run the following DCL:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
ALTER SESSION SET sql_trace = true;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
To specify trace file identifier which helps to locate specific trace files easily&lt;/div&gt;
&lt;div&gt;
ALTER SESSION SETtracefile_identifier =tracing_example;&lt;/div&gt;
&lt;/div&gt;
&lt;br /&gt;
To specify the trace destination other than the oracle default , we could perform below&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
ALTER SESSION SET user_dump_dest=&lt;location&gt;&lt;/location&gt;&lt;br /&gt;
&lt;div&gt;
Default vaues for the various parameters above can also be found using TOAD-&amp;gt;Database-&amp;gt;Administer-&amp;gt;Parameters&lt;/div&gt;
&lt;br /&gt;
&lt;h2&gt;
Explain Plan&lt;/h2&gt;
Using toad , this can be achieved by following the steps below:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;ol&gt;
&lt;li&gt;&amp;nbsp;Connect to the Oracle SID&lt;/li&gt;
&lt;li&gt;Open a SQL editor, and write the SQL query for which the explain plan is required.&lt;/li&gt;
&lt;li&gt;CTRL+E will produce the explain plan for the query - which basically means , this is the most likely path oracle will chose while executing the SQL.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Analyze the cost of the query , and identify the areas which are causing the cost to grow high.&lt;/li&gt;
&lt;li&gt;Mostly this happens when full table access is performed, or hashed joins are used , instead of full index scans and nested loops.&lt;/li&gt;
&lt;li&gt;This is the fastest way to identify if a query you have written has some tuning gaps and can be rewritten to perform better in distributed and scalable high volume environments.&lt;/li&gt;
&lt;/ol&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
Enable SNAPSHOTS&lt;/h2&gt;
&lt;div&gt;
By enabling snapshots we will be able to capture the Oracle activity between regular periods identified by snapshot ids. To view the current snapshot interval we can run the following:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
select * from DBA_HIST_WR_CONTROL&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
To enable snapshots for every 15 minutes , we can run the following procedure. We can change the snapshot interval based on approximately how much time would a process(which we are interested in profiling / tuning ) takes to run .&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
BEGIN &lt;b&gt;dbms_workload_repository.modify_snapshot_settings&lt;/b&gt;(interval =&amp;gt; &lt;b&gt;15&lt;/b&gt;, retention =&amp;gt; null); END;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
Generate AWR Report&lt;/h2&gt;
&lt;div&gt;
An AWR report captures all Oracle activity between given snapshots. This can be helpful to monitor the queries which are taking longer than expected and also identify tuning paramters.&lt;/div&gt;
&lt;div&gt;
To generate an AWR report we can perform the following steps:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
&lt;ol&gt;
&lt;li&gt;Invoke @&lt;b&gt;awrrpt&lt;/b&gt;.sql from ..\oracle\product\&lt;version&gt;\dbhome_1\RDBMS\ADMIN&lt;/version&gt;&lt;/li&gt;
&lt;li&gt;Choose report type as &lt;b&gt;html&lt;/b&gt;&lt;/li&gt;
&lt;li&gt;Provide &lt;b&gt;number of days&lt;/b&gt; you want the report to span for snapshot ids&lt;/li&gt;
&lt;li&gt;Provide the &lt;b&gt;snapshots&lt;/b&gt; which we want to capture in our report.&amp;nbsp;&lt;/li&gt;
&lt;li&gt;Provide a valid report &lt;b&gt;name&lt;/b&gt;.&lt;/li&gt;
&lt;li&gt;AWR report is generated in the&amp;nbsp;..\oracle\product\&lt;version&gt;\dbhome_1\RDBMS\ADMIN&amp;nbsp;folder with the name provided.&lt;/version&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;div&gt;
Many of the above options can be chosen as default as well.&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;h2&gt;
Capturing SQL ID&lt;/h2&gt;
&lt;div&gt;
If we do not have a AWR report , but still want to identify the the SQL id based on the query content the following can be used:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
SELECT sql_id, child_number, substr(sql_text, 1, 300) sqltxt from v$sql WHERE sql_text LIKE %&lt;query text=&quot;&quot;&gt;%&#39; ;&lt;/query&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
Also the various execution plans used by oracle for this SQL can be generated using:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;div&gt;
set linesize 150&lt;/div&gt;
&lt;div&gt;
set pagesize 2000&lt;/div&gt;
&lt;div&gt;
SELECT * FROM table(DBMS_XPLAN.&lt;b&gt;DISPLAY_AWR&lt;/b&gt;(&#39;&lt;b&gt;SQL_ID&lt;/b&gt;&#39;));&lt;/div&gt;
&lt;/div&gt;
&lt;h2&gt;
Execution Plan&lt;/h2&gt;
&lt;div&gt;
Execution plan on the other hand is the actual path /plan used by oracle to execute a query.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
To extract an execution plan, you will have to perform a few more steps as below:&lt;/div&gt;
&lt;div&gt;
&lt;ol&gt;
&lt;li&gt;Enable snapshots for the SID which you will be executing the queries from.Set the snapshot interval based on your specific enviroment , sql process running&lt;/li&gt;
&lt;li&gt;Execute the SQL procedure, process or DBMS transaction which you want to tune.&lt;/li&gt;
&lt;li&gt;Generate &lt;b&gt;AWR &lt;/b&gt;report for the snapsots we are interested in.&lt;/li&gt;
&lt;li&gt;Browse the sql statistics to identify which queries are taking up the most time , in terms of execution , io waits , cpu etc&lt;/li&gt;
&lt;li&gt;Each SQL will have a unique &lt;b&gt;SQL_ID &lt;/b&gt;, capture that.&lt;/li&gt;
&lt;li&gt;Invoke @&lt;b&gt;awrsqrpt&lt;/b&gt;.sql from ..\oracle\product\&lt;version&gt;\dbhome_1\RDBMS\ADMIN&lt;/version&gt;&lt;/li&gt;
&lt;li&gt;Provide the sql id for which we want to generate the execution plan&lt;/li&gt;
&lt;li&gt;Provide snapshot ids&lt;/li&gt;
&lt;li&gt;Provide a name for the plan report&lt;/li&gt;
&lt;li&gt;Execution plan is generated in the&amp;nbsp;..\oracle\product\&lt;version&gt;\dbhome_1\RDBMS\ADMIN&amp;nbsp;folder with the name provided.&lt;/version&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
&lt;br /&gt;
This plan will provide the exact path , and can be used to identify whats causing the costs for SQL runtime to go high.&lt;br /&gt;
&lt;br /&gt;
&lt;h2&gt;
&lt;i&gt;&lt;span style=&quot;color: purple;&quot;&gt;Tuning Options:&lt;/span&gt;&lt;/i&gt;&lt;/h2&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;Disable tracing&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;Disable all SQL profilers&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;Perform Database connections monitoring - if connections are being returned once transactions complete&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;reduce redo logs&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;add hints wherever costs of queries are more due to joins and full table scans&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;add appropriate indexes&amp;nbsp;&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;Check Init.ORA for Oracle settings ,and modify based on the needs&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;li&gt;&lt;i&gt;&lt;b&gt;&lt;span style=&quot;color: purple;&quot;&gt;The list if huge .......&lt;/span&gt;&lt;/b&gt;&lt;/i&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/3164878987082101167/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2013/03/oracle-execution-plans-explain-plans.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3164878987082101167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3164878987082101167'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2013/03/oracle-execution-plans-explain-plans.html' title='Oracle - Execution Plans , Explain Plans, AWR Reports, Tuning  - A handy Guide'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-6305008260759274092</id><published>2012-05-22T22:30:00.000+05:30</published><updated>2013-03-06T17:43:21.612+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="debug"/><category scheme="http://www.blogger.com/atom/ns#" term="dump"/><category scheme="http://www.blogger.com/atom/ns#" term="heap"/><category scheme="http://www.blogger.com/atom/ns#" term="jdk"/><category scheme="http://www.blogger.com/atom/ns#" term="jrmc"/><category scheme="http://www.blogger.com/atom/ns#" term="jrockit"/><category scheme="http://www.blogger.com/atom/ns#" term="visualvm"/><category scheme="http://www.blogger.com/atom/ns#" term="weblogic"/><category scheme="http://www.blogger.com/atom/ns#" term="windows"/><title type='text'>Generating Java Heap Dumps on the go !</title><content type='html'>&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
Ever come across a stituation where you need to take a look at the heap dumps , as to whats eating up the memory ?&lt;br /&gt;
&lt;br /&gt;
Well depends which version of JDK u r on. The couple I know of are:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;ol style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&lt;b&gt;jmap &lt;/b&gt;- a very old command which is now un supported . If u r using old versions of JDK prior to 1.5 this command is handy.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;jconsole &lt;/b&gt;- you can aquire the heap dump using the hotspotdiagnostics using the javax Mbeans. For jconsole to recognize the process , we should start the java process with the following :&lt;/li&gt;
&lt;/ol&gt;
&lt;span style=&quot;font-family: Calibri, sans-serif; font-size: 11pt;&quot;&gt;&lt;div style=&quot;text-align: justify;&quot;&gt;
&lt;span style=&quot;font-size: 11pt;&quot;&gt;-Dcom.sun.management.jmxremote.port=&amp;lt;&lt;/span&gt;&lt;b style=&quot;font-size: 11pt;&quot;&gt;PORT&lt;/b&gt;&lt;span style=&quot;font-size: 11pt;&quot;&gt;&amp;gt; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;/span&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot; style=&quot;text-align: justify;&quot; trbidi=&quot;on&quot;&gt;
&lt;span style=&quot;font-family: Calibri, sans-serif; font-size: 11pt;&quot;&gt;-Dcom.sun.management.jmxremote.authenticate=&lt;b&gt;false&lt;/b&gt;&amp;nbsp;&lt;/span&gt;&lt;/div&gt;
&lt;div dir=&quot;ltr&quot; style=&quot;text-align: left;&quot; trbidi=&quot;on&quot;&gt;
&lt;div style=&quot;text-align: justify;&quot;&gt;
&lt;span style=&quot;font-family: Calibri, sans-serif; font-size: 11pt;&quot;&gt;-Dcom.sun.management.jmxremote.ssl=&lt;/span&gt;&lt;b style=&quot;font-family: Calibri, sans-serif; font-size: 11pt;&quot;&gt;false&lt;/b&gt;&lt;/div&gt;
&lt;ol style=&quot;text-align: left;&quot;&gt;
&lt;li&gt;&lt;b&gt;jrmc &lt;/b&gt;- jrockit mission control - If you are on the latest versions of JDK from jrockit , this is an ultra cool utility provided to be able to diagnose and monitor and profile your jvm. Go to the Advanced -&amp;gt;Diagnose-&amp;gt;heapdumpprof util and generate the heap dump at the desired location.&lt;/li&gt;
&lt;li&gt;When you startup the jvm add the arguments&amp;nbsp;&lt;span style=&quot;font-size: x-small;&quot;&gt;&lt;span style=&quot;background-color: white; font-family: Tahoma, sans-serif; text-align: -webkit-auto;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; font-family: Tahoma, sans-serif; font-weight: bold; text-align: -webkit-auto;&quot;&gt;-XX:+|-HeapDumpOnOutOfMemoryError and &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;background-color: white; font-family: Tahoma, sans-serif; text-align: -webkit-auto;&quot;&gt;&lt;b&gt;-XX:HeapDumpPath=&amp;lt;&lt;/b&gt;&lt;i&gt;Location where the dump should be written to&lt;/i&gt;&lt;b&gt;&amp;gt;&lt;/b&gt;&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;background-color: white; font-family: Tahoma, sans-serif; font-size: xx-small; text-align: -webkit-auto;&quot;&gt;Alternatively if you are &amp;nbsp;using Jrockit you can provide the following startup arguments &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;b&gt;-D&lt;/b&gt;&lt;/span&gt;&lt;b&gt;&lt;span style=&quot;text-indent: -0.25in;&quot;&gt;jrockit.oomdiagnostics=true and&amp;nbsp;&lt;/span&gt;&lt;span style=&quot;font-family: Symbol; text-indent: -0.25in;&quot;&gt;&lt;span style=&quot;font-family: &#39;Times New Roman&#39;; font-size: 7pt;&quot;&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;text-indent: -0.25in;&quot;&gt;-Djrockit.oomdiagnostics.filename=d:\heapdump.log&lt;/span&gt;&lt;/b&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;text-indent: -0.25in;&quot;&gt;You could also monitor the memory using &lt;b&gt;visualvm &lt;/b&gt;provided in latest jdks which give you better insight on the young heap and the old heap.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span style=&quot;text-indent: -0.25in;&quot;&gt;&lt;b&gt;Eclipse memory analyzer&lt;/b&gt; can also be used to generate a heap dump and also view the dum generated by any of the above processes. This is very helpful m when you want to identify memory leaks etc&lt;/span&gt;&lt;/li&gt;
&lt;li style=&quot;text-indent: -24px;&quot;&gt;&lt;br /&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;div style=&quot;text-indent: -24px;&quot;&gt;
&lt;span style=&quot;color: #1f497d; font-weight: bold;&quot;&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/span&gt;&amp;nbsp; The dump thus generated usually can is a log file which you can read or a hprof file which can be analysed using a memory analyzer(eclipse plugin&amp;nbsp;&lt;a href=&quot;http://www.eclipse.org/mat/downloads.php&quot;&gt;http://www.eclipse.org/mat/downloads.php&lt;/a&gt;).&lt;/div&gt;
&lt;div style=&quot;text-indent: -24px;&quot;&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div style=&quot;text-indent: -24px;&quot;&gt;
&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/div&gt;
&lt;/div&gt;
</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/6305008260759274092'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/6305008260759274092'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2012/05/generating-java-heap-dumps-on-go.html' title='Generating Java Heap Dumps on the go !'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-5241248153558395432</id><published>2010-12-10T21:19:00.002+05:30</published><updated>2010-12-10T21:19:00.557+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="castor"/><category scheme="http://www.blogger.com/atom/ns#" term="esb"/><category scheme="http://www.blogger.com/atom/ns#" term="faq"/><category scheme="http://www.blogger.com/atom/ns#" term="java fx"/><category scheme="http://www.blogger.com/atom/ns#" term="rest"/><category scheme="http://www.blogger.com/atom/ns#" term="rpc"/><category scheme="http://www.blogger.com/atom/ns#" term="soa"/><category scheme="http://www.blogger.com/atom/ns#" term="soap"/><category scheme="http://www.blogger.com/atom/ns#" term="web service"/><category scheme="http://www.blogger.com/atom/ns#" term="xml beans"/><title type='text'>Web Services - FAQs</title><content type='html'>&lt;span style=&quot;font-size:85%;&quot;&gt;&lt;span style=&quot;font-style: italic; font-family: lucida grande;&quot;&gt;Note: This is how I understand Web services. I have mostly worked on SOAP based implementations of Web services which use &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_0&quot;&gt;ESB&lt;/span&gt; to transport the messages back and forth between the provider and the consumer. The SOAP contract is available to understand how to make use of a web service. I have used XML Beans, AXIS, Castor in the process.&lt;/span&gt;&lt;/span&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;&lt;br /&gt;&lt;br /&gt;My knowledge on REST is limited at this stage.&lt;br /&gt;&lt;br /&gt;Q&lt;/span&gt;: &lt;span style=&quot;font-weight: bold;&quot;&gt;What exactly is a web service. ?&lt;br /&gt;A:  &lt;/span&gt;A web service is a service provided by an application , such that it can be used by applications(internal , external) with minimal coupling. An example could be &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_1&quot;&gt;rss&lt;/span&gt; feeds.&lt;br /&gt;Where in a newspaper provides all its article in the &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_2&quot;&gt;RSS&lt;/span&gt; format , for other websites to include in their web apps.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Q: When should a functionality be exposed as  a &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_3&quot;&gt;webservice&lt;/span&gt; ?&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A: &lt;/span&gt;When a functionality could be useful to other applications , and the functionality needs to be available out of the box (language independent , platform independent)&lt;span style=&quot;font-weight: bold;&quot;&gt; . &lt;/span&gt;With the only constraint being XML as a medium of communication.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Q: What ways can a &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_4&quot;&gt;webservice&lt;/span&gt; be consumed ?&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A:&lt;/span&gt; Interestingly this depends , on how the service provider expects the request to be.&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_5&quot;&gt;RPC&lt;/span&gt; - tight coupling exists , message broker , stub , binding , registration, &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_6&quot;&gt;lookup&lt;/span&gt; etc are terms often used when we speak about &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_7&quot;&gt;RPC&lt;/span&gt; , similar to Java  &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_8&quot;&gt;RPC&lt;/span&gt;/&lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_9&quot;&gt;CORBA&lt;/span&gt;. More Service Oriented.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;SOAP - Communication based on XML written in specific formats as defined is service &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_10&quot;&gt;XSD&#39;s&lt;/span&gt; and invoke services as defined in the &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_11&quot;&gt;WSDL&lt;/span&gt;. Message Oriented.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;REST - Communication based on XML  over Http but using specific set of functions like GET , POST etc.&lt;br /&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Q:What exactly is the &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_12&quot;&gt;wsdl&lt;/span&gt; used for in a &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_13&quot;&gt;webservice&lt;/span&gt; ?&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A: &lt;/span&gt;It basically is a document to describe which functionalities are exposed for consumption by the client.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A: What exactly is a contract  in terms of &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_14&quot;&gt;webservice&lt;/span&gt; ?&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A:&lt;/span&gt; Its is a document to describe how to invoke a web service , what are the inputs and the output formats applicable and also if a client is registered to use this service(public or private)&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Q: What are the types &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_15&quot;&gt;Webservice&lt;/span&gt; implementations available in java?&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A: &lt;/span&gt; &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_16&quot;&gt;CORBA&lt;/span&gt;, &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_17&quot;&gt;Restlets&lt;/span&gt; etc&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Q:What are the various &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_18&quot;&gt;marshalling&lt;/span&gt;/ &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_19&quot;&gt;unmarshalling&lt;/span&gt; frameworks available in Java?&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;A:&lt;/span&gt; Castor, &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_20&quot;&gt;XMLBeans&lt;/span&gt; , &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_21&quot;&gt;JIBX&lt;/span&gt; etc&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Q: What is an &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_22&quot;&gt;ESB&lt;/span&gt; ?&lt;br /&gt;A:&lt;/span&gt; An enterprise service bus acts as a interface to many systems which communicate with each other. The systems communicate to the &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_23&quot;&gt;ESB&lt;/span&gt; with a message and the &lt;span class=&quot;blsp-spelling-error&quot; id=&quot;SPELLING_ERROR_24&quot;&gt;ESB&lt;/span&gt; will thereafter process the message (forward it to the correct service provider, wait for the reply , send the reply back to the client).</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/5241248153558395432/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/12/web-services-faqs.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/5241248153558395432'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/5241248153558395432'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/12/web-services-faqs.html' title='Web Services - FAQs'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-1256298092567600135</id><published>2010-07-09T22:24:00.000+05:30</published><updated>2010-07-09T22:24:00.604+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="ajax"/><category scheme="http://www.blogger.com/atom/ns#" term="display"/><category scheme="http://www.blogger.com/atom/ns#" term="excel"/><category scheme="http://www.blogger.com/atom/ns#" term="onclick"/><category scheme="http://www.blogger.com/atom/ns#" term="onsubmit"/><category scheme="http://www.blogger.com/atom/ns#" term="pdf"/><category scheme="http://www.blogger.com/atom/ns#" term="view"/><category scheme="http://www.blogger.com/atom/ns#" term="wicket"/><title type='text'>Wicket - Displaying a PDF onclick of a link or onSubmit of a Button</title><content type='html'>Very simple scenario , I wanted to display a PDF or an Excel on click of a link/ on submit of a button.&lt;br /&gt;&lt;br /&gt;Since wicket offers flavors of ajaxbutton and ajax link one can easily make a mistake of the using them to render the pdf or excel.&lt;br /&gt;&lt;br /&gt;I did the same. everything seemed to work unit the point where the response needed to be rendered and i would see a pdf or excel.&lt;br /&gt;&lt;br /&gt;The problem was that using an ajax button or link we can only render a ajax response, but in this case i wanted to render a pdf or excel response (bytes).&lt;br /&gt;&lt;br /&gt;It only clicked to me after a while of debugging that the browser had no way to identify how to render the ajax response which contained pdf bytes.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Lesson learnt , always use a Normal Button or a link to render the pdf as the web response.&lt;br /&gt;&lt;br /&gt;an example would be like this:&lt;br /&gt;Link excelLink = new Link(&amp;quot;linForExcel&amp;quot;){&lt;br /&gt;@Override&lt;br /&gt;            public void onClick() {&lt;br /&gt;                final OutputStream excelOutputStream = methodToReturnTheExcelOutputStream();&lt;br /&gt;                final ByteArrayResource byteArrayResource = new ByteArrayResource(&amp;quot;application/vnd.ms-excel&amp;quot;, ((ByteArrayOutputStream) excelOutputStream).toByteArray());&lt;br /&gt;                IResourceStream resourceStream = byteArrayResource.getResourceStream();&lt;br /&gt;                getRequestCycle().setRequestTarget(new ResourceStreamRequestTarget(resourceStream) {&lt;br /&gt;                    public String getFileName() {&lt;br /&gt;                        return &amp;quot;NameOfExcel.csv&amp;quot;;&lt;br /&gt;                    }&lt;br /&gt;                });&lt;br /&gt;}</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/1256298092567600135/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/07/wicket-displaying-pdf-onclick-of-link.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/1256298092567600135'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/1256298092567600135'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/07/wicket-displaying-pdf-onclick-of-link.html' title='Wicket - Displaying a PDF onclick of a link or onSubmit of a Button'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-5145297053299413678</id><published>2010-06-24T21:40:00.001+05:30</published><updated>2010-06-24T21:40:00.533+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="ajax"/><category scheme="http://www.blogger.com/atom/ns#" term="container"/><category scheme="http://www.blogger.com/atom/ns#" term="div"/><category scheme="http://www.blogger.com/atom/ns#" term="horizontal result set"/><category scheme="http://www.blogger.com/atom/ns#" term="programatically"/><category scheme="http://www.blogger.com/atom/ns#" term="scroll"/><category scheme="http://www.blogger.com/atom/ns#" term="wicket"/><title type='text'>Wicket - Programattically Scroll a Div Horizontally</title><content type='html'>I came across a user case where I had to programatically scroll the contents of a div to the right. This was&lt;br /&gt;to be performed on a click of an ajax link. This is how I achieved the same:&lt;br /&gt;&lt;br /&gt;onSubmit(AjaxTarget....)&lt;br /&gt;{&lt;br /&gt;.... body of onsubmit , additional operations.&lt;br /&gt;target.appendJavascript(&amp;quot;var obj = document.getElementById(&#39;divid&#39;);obj.scrollLeft = 500;&amp;quot;);      &lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;some additional methods which could be used on the window itself rather than a div are&lt;br /&gt;&lt;br /&gt;scrollBy&lt;br /&gt;scrollTo&lt;br /&gt;moveBy</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/5145297053299413678/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/wicket-programattically-scroll-div.html#comment-form' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/5145297053299413678'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/5145297053299413678'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/wicket-programattically-scroll-div.html' title='Wicket - Programattically Scroll a Div Horizontally'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-4328681778328031055</id><published>2010-06-24T21:23:00.000+05:30</published><updated>2010-06-24T21:23:00.765+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="form"/><category scheme="http://www.blogger.com/atom/ns#" term="nested modal window"/><category scheme="http://www.blogger.com/atom/ns#" term="panel"/><category scheme="http://www.blogger.com/atom/ns#" term="parent"/><category scheme="http://www.blogger.com/atom/ns#" term="value"/><category scheme="http://www.blogger.com/atom/ns#" term="web page"/><category scheme="http://www.blogger.com/atom/ns#" term="wicket"/><title type='text'>Wicket - Nested Modal Windows - Parent window not getting refreshed</title><content type='html'>Recently while trying to use nested modal windows I came across this wierd issue where the value being returned from the child modal window was not being refreshed and shown on the parent modal window.&lt;br /&gt;&lt;br /&gt;My heirarchy was like this:&lt;br /&gt;-&amp;gt;&amp;lt;html&amp;gt;&lt;br /&gt;--&amp;gt;&amp;lt;form&amp;gt;&lt;br /&gt;----&amp;gt;&amp;lt;div wicket:id=&amp;quot;parentModalWindow&amp;quot;&amp;gt;&lt;br /&gt;------&amp;gt;&amp;lt;wicket:panel&amp;gt;&lt;br /&gt;--------&amp;gt;&amp;lt;form&amp;gt; -- Parent Modal Window Form&lt;br /&gt;----------&amp;gt;&amp;lt;div wicket:id=&amp;quot;childModalWindow&amp;quot;&amp;gt;&lt;br /&gt;------------&amp;gt;&amp;lt;wicket:panel&amp;gt;&lt;br /&gt;--------------&amp;gt;&amp;lt;form&amp;gt; --Child Modal window form&lt;br /&gt;--------------&amp;gt;&amp;lt;/form&amp;gt;&lt;br /&gt;------------&amp;gt;&amp;lt;/wicket:panel&amp;gt;&lt;br /&gt;----------&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;--------&amp;gt;&amp;lt;form&amp;gt;&lt;br /&gt;------&amp;gt;&amp;lt;wicket:panel&amp;gt;&lt;br /&gt;----&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;--&amp;gt;&amp;lt;/form&lt;br /&gt;-&amp;gt;&amp;lt;html&amp;gt;&lt;br /&gt;&lt;br /&gt;When using such a design of components the child modal window was always submitting a null value for the form components. And hence the form processing was not happening correctly.&lt;br /&gt;&lt;br /&gt;I thereafter was suggested to use a web page instead of a panel for the child modal window as panel -&gt; form  - &gt; panel - &gt; form  hierarchy didnt work well. Form within form was supported.&lt;br /&gt;&lt;br /&gt;Hence I update my child modal window content to be created from a web page. And used a page creator to set content.&lt;br /&gt;&lt;br /&gt;Now I went a step ahead as I could see the value being returned to the parent  i submitted the child form and but the parent modal window components were not refreshed .&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I then realised that I had to overide&lt;br /&gt;&lt;br /&gt;childModalWindow.setCloseButtonCallback(new ModalWindow.CloseButtonCallback()&lt;br /&gt;                 {&lt;br /&gt;                  public boolean onCloseButtonClicked(AjaxRequestTarget target) {&lt;br /&gt;                        target.addComponent(parentWindowComponent);&lt;br /&gt;                       &lt;br /&gt;                     return true;&lt;br /&gt;                    }&lt;br /&gt;                });   &lt;br /&gt;                   &lt;br /&gt;                childModalWindow.setWindowClosedCallback(new ModalWindow.WindowClosedCallback()&lt;br /&gt;                     {   &lt;br /&gt;                        public void onClose(AjaxRequestTarget target) {&lt;br /&gt;                             target.addComponent(parentWindowComponent);&lt;br /&gt;                            &lt;br /&gt;                    }&lt;br /&gt;                 });&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This fixed the final problem as well the container in the parent window also updated to show the new value submitted by the child modal window.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/4328681778328031055/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/wicket-nested-modal-windows-parent.html#comment-form' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/4328681778328031055'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/4328681778328031055'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/wicket-nested-modal-windows-parent.html' title='Wicket - Nested Modal Windows - Parent window not getting refreshed'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-3636295586461942544</id><published>2010-06-24T21:11:00.000+05:30</published><updated>2010-06-24T21:11:00.584+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="1.3.7"/><category scheme="http://www.blogger.com/atom/ns#" term="auto"/><category scheme="http://www.blogger.com/atom/ns#" term="complete"/><category scheme="http://www.blogger.com/atom/ns#" term="firefox"/><category scheme="http://www.blogger.com/atom/ns#" term="ie"/><category scheme="http://www.blogger.com/atom/ns#" term="modal window"/><category scheme="http://www.blogger.com/atom/ns#" term="not visible"/><category scheme="http://www.blogger.com/atom/ns#" term="wicket"/><category scheme="http://www.blogger.com/atom/ns#" term="z-index"/><title type='text'>Wicket - Auto Complete inside a ModalWindow</title><content type='html'>While trying to include an autocomplete field inside a modalwindow I came across this issue where the ajax response being sent was rendered behind the modal window on IE. Windows XP, Wicket 1.3.7&lt;br /&gt;&lt;br /&gt;In other words the lookup values were not visible as they were placed behind the modal window container. This however worked fine on firefox.&lt;br /&gt;&lt;br /&gt;The same auto complete text field worked fine on a normal web page. Both on IE and Firefox.&lt;br /&gt;&lt;br /&gt;Searching through forums I realised that the z-index of the autocomplete text field was much lower than the container hence it was always behind other containers and components.&lt;br /&gt;&lt;br /&gt;The Wicket AutoComplete .js can be browsed through to see what exactly was happening.&lt;br /&gt;&lt;br /&gt; function getOffsetParentZIndex(obj) {&lt;br /&gt;        obj=typeof obj==&amp;quot;string&amp;quot;?Wicket.$(obj):obj;&lt;br /&gt;        obj=obj.offsetParent;&lt;br /&gt;        var index=&amp;quot;auto&amp;quot;;&lt;br /&gt;        do {&lt;br /&gt;            var pos=getStyle(obj,&amp;quot;position&amp;quot;);           &lt;br /&gt;            if(pos==&amp;quot;relative&amp;quot;||pos==&amp;quot;absolute&amp;quot;||pos==&amp;quot;fixed&amp;quot;) {&lt;br /&gt;                index=getStyle(obj,&amp;quot;z-index&amp;quot;);&lt;br /&gt;            }&lt;br /&gt;            obj=obj.offsetParent;            &lt;br /&gt;        } while (obj &amp;amp;&amp;amp; index == &amp;quot;auto&amp;quot;);&lt;br /&gt;        return index;&lt;br /&gt;    }&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This method above always returned zero for the modal window container and hence the auto complete z index was set to 0 + 1 = 1 which was much lower than the other containers.&lt;br /&gt;&lt;br /&gt;Also something noticeable was on IE all container pos came out as static is not being processed in the method and hence the method goes right upto the last parent to get the z-index.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;As a workaround we came up with a solution where we added &lt;span style=&quot;font-weight: bold; font-style: italic; color: rgb(255, 0, 0);&quot;&gt;style=&amp;quot;position:relative;z-index=99999;&amp;quot;&lt;/span&gt; to the element containing the text field , this could be the div, form , td etc in your case.&lt;br /&gt;&lt;br /&gt;What this will do is to allow the above method process the container and send back 99999 as the z-index and your auto complete&#39;s z-index would then be 99999 +1 and hence it will render above the container.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Problem Solved.&lt;br /&gt;&lt;br /&gt;Another work around would be change the modal window content to be a web page instead of the Panel.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/3636295586461942544/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/wicket-auto-complete-inside-modalwindow.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3636295586461942544'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3636295586461942544'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/wicket-auto-complete-inside-modalwindow.html' title='Wicket - Auto Complete inside a ModalWindow'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-1820893794415301777</id><published>2010-06-21T21:41:00.000+05:30</published><updated>2010-06-24T15:46:38.787+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="apache"/><category scheme="http://www.blogger.com/atom/ns#" term="chain"/><category scheme="http://www.blogger.com/atom/ns#" term="collections"/><category scheme="http://www.blogger.com/atom/ns#" term="comparator"/><category scheme="http://www.blogger.com/atom/ns#" term="multiple daos"/><category scheme="http://www.blogger.com/atom/ns#" term="util"/><title type='text'>Apache Commons Collections - Chaining Comparators</title><content type='html'>I came across this useful Util class provided by Apache Commons Collections.&lt;br /&gt;&lt;br /&gt;ComparatorUtils&lt;br /&gt;&lt;br /&gt;one of the useful methods here is chainedComparator which allows us to chain comparators to achieve sorting on multiple attributes of an object.&lt;br /&gt;&lt;br /&gt;if the results from the first comparator result in 0 then the next comparator is invoked.&lt;br /&gt;&lt;br /&gt;I remember writing a Util for myself for the same. But This class is much more robust and accessible.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/1820893794415301777/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/apache-commons-collections-chaining.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/1820893794415301777'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/1820893794415301777'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/apache-commons-collections-chaining.html' title='Apache Commons Collections - Chaining Comparators'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-5561470918621476504</id><published>2010-06-15T21:47:00.000+05:30</published><updated>2010-06-24T15:50:48.933+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="features"/><category scheme="http://www.blogger.com/atom/ns#" term="migration"/><category scheme="http://www.blogger.com/atom/ns#" term="testng . junit"/><title type='text'>Migrating From Junit 4 to TestNG</title><content type='html'>Testing next generation sounds good , for which recently I had migrated some of my unit tests written in JUnit 4 to Test NG.&lt;br /&gt;&lt;br /&gt;Some useful features I have used and liked:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Annotations&lt;/li&gt;&lt;li&gt;Dependent Method&lt;/li&gt;&lt;li&gt;Groups&lt;/li&gt;&lt;li&gt;Printable and User Friendly Reports&lt;/li&gt;&lt;li&gt;CSS Configuration for reports&lt;/li&gt;&lt;li&gt;Tests runnable for various granularities like suites , groups, class , package etc&lt;/li&gt;&lt;li&gt;Eclipse plugin available&lt;/li&gt;&lt;li&gt;Data Provider&lt;/li&gt;&lt;li&gt;Spring compatibily&lt;/li&gt;&lt;li&gt;XML configuration&lt;br /&gt;&lt;/li&gt;&lt;li&gt;Many more which can be read from the Test NG documentation&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/5561470918621476504/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/migrating-from-junit-4-to-testng.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/5561470918621476504'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/5561470918621476504'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/06/migrating-from-junit-4-to-testng.html' title='Migrating From Junit 4 to TestNG'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-897955103406671094</id><published>2010-03-22T21:10:00.001+05:30</published><updated>2010-03-23T12:53:17.963+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="classes"/><category scheme="http://www.blogger.com/atom/ns#" term="compatible"/><category scheme="http://www.blogger.com/atom/ns#" term="data source"/><category scheme="http://www.blogger.com/atom/ns#" term="ojdbc"/><category scheme="http://www.blogger.com/atom/ns#" term="oracle 8.1.7"/><category scheme="http://www.blogger.com/atom/ns#" term="prefer"/><category scheme="http://www.blogger.com/atom/ns#" term="spring"/><category scheme="http://www.blogger.com/atom/ns#" term="standalone"/><category scheme="http://www.blogger.com/atom/ns#" term="weblogic 10.3"/><title type='text'>Connecting to Oracle 8.1.7 from Weblogic10.3</title><content type='html'>This has been a nail biting issues for me where I had to connect to an older unsupported version of oracle from a newer version of Weblogic.&lt;br /&gt;&lt;br /&gt;An upgrade document on weblogic 10.3 states that 8.1.7 is no longer supported by weblogic.&lt;br /&gt;http://download.oracle.com/docs/cd/E15919_01/wlp.1032/e14253/upgrade_process.htm&lt;br /&gt;This is true as we will not be able to simply create a datasource from weblogic 10.3 to oracle 8.1.7&lt;br /&gt;coz the driver (ojdbc6.ja and ojdbc5.jar) as packaged with weblogic are not compatible with the same.&lt;br /&gt;&lt;br /&gt;Hence the search began to find a suitable driver. The Drivers as mentioned by oracle for 8.1.7 can be viewed here:&lt;br /&gt;&lt;a href=&quot;http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/htdocs/jdbc817.html&quot;&gt;http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/htdocs/jdbc817.html&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Of course I started off with downloading classes12.jar&lt;br /&gt;&lt;br /&gt;and I realised that though my standalone unit tests(JUNIT 4 using spring AbstractTransactionalDataSourceSpringContextTests) worked fine with some tweaks here and there.&lt;br /&gt;&lt;br /&gt;However when the same spring config&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;&amp;lt;bean id=&quot;testDataSource&quot; class=&quot;org.springframework.jdbc.datasource.DriverManagerDataSource&quot;&amp;gt;&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;        &amp;lt;property name=&quot;driverClassName&quot;&amp;gt;&amp;lt;value&amp;gt;oracle.driver.jdbc.OracleDriver&amp;lt;/value&amp;gt;&amp;lt;/property&amp;gt;&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;        &amp;lt;property name=&quot;url&quot;&amp;gt;&amp;lt;value&amp;gt;jdbc:oracle:thin:@host:port:databasename&amp;lt;/value&amp;gt;&amp;lt;/property&amp;gt;&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;        &amp;lt;property name=&quot;username&quot;&amp;gt;&amp;lt;value&amp;gt;USERNAME&amp;lt;/value&amp;gt;&amp;lt;/property&amp;gt;&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;        &amp;lt;property name=&quot;password&quot;&amp;gt;&amp;lt;value&amp;gt;PASSWORD&amp;lt;/value&amp;gt;&amp;lt;/property&amp;gt;&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;      &amp;lt;/bean&amp;gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;was used within an app deployed on weblogic to connect to the database I got a weird exception:&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;java.lang.ArrayIndexOutOfBoundsException: 4&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at oracle.jdbc.driver.T4C8TTIdty.marshal(T4C8TTIdty.java:465)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:329)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at oracle.jdbc.driver.PhysicalConnection.&amp;lt;init&amp;gt;(PhysicalConnection.java:&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;490)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at oracle.jdbc.driver.T4CConnection.&amp;lt;init&amp;gt;(T4CConnection.java:202)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtensio&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;n.java:33)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:474)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at java.sql.DriverManager.getConnection(DriverManager.java:582)&lt;/span&gt; &lt;span style=&quot;font-weight: bold;&quot;&gt;at java.sql.DriverManager.getConnection(DriverManager.java:185)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The problem was obvious Weblogic class loader was trying to return the Oracle Driver as present in ojdbc6.jar or ojdbc5.jar and completely ignored my classes12.jar which I had in the classpath.&lt;br /&gt;&lt;br /&gt;Hence I had to start from scratch again. I instead added classes12.jar to the weblogic classpath and tried creating a datasource using the weblogic console , even then I gotthe&lt;br /&gt;&lt;br /&gt;same exception as above. I wondered if upgrading to another jar would help. I hence downloaded ojdbc14.jar and added it to the weblogic classpath and tried creating a datasource&lt;br /&gt;&lt;br /&gt;and it was successful.&lt;br /&gt;&lt;br /&gt;However I wondered if there was  away of not changing the weblogic classpath and instead using ojdbc14.jar from within my application to be loaded in preference as ooposed to&lt;br /&gt;&lt;br /&gt;odjbc6.jar/ojdbc5.jar as present in weblogic classpath.&lt;br /&gt;&lt;br /&gt;I later added&lt;br /&gt;&lt;br /&gt;  &amp;lt;container-descriptor&amp;gt;&lt;br /&gt;    &amp;lt;prefer-web-inf-classes&amp;gt;true&amp;lt;/prefer-web-inf-classes&amp;gt;&lt;br /&gt;  &amp;lt;/container-descriptor&amp;gt;&lt;br /&gt;&lt;br /&gt;to my weblogic.xml so as to change the classloader preference.&lt;br /&gt;&lt;br /&gt;Some forums suggested using the weblogic-application.xml to achieve the same by adding&lt;br /&gt;&lt;br /&gt;    &amp;lt;prefer-application-packages&amp;gt;&lt;br /&gt;        &amp;lt;package-name&amp;gt;oracle.jdbc.driver.*&amp;lt;/package-name&amp;gt;       &lt;br /&gt;    &amp;lt;/prefer-application-packages&amp;gt;&lt;br /&gt;&lt;br /&gt;Both will change the order for class loader preferences.&lt;br /&gt;&lt;br /&gt;However for me the first option worked.&lt;br /&gt;&lt;br /&gt;So now I am able to connect to oracle 8.1.7 from an application which has ojdbc14.jar in web-inf/lib and the weblogic.xml says to prefer the same.&lt;br /&gt;&lt;br /&gt;The datasource is not a jndi datasource as can be done in weblogic but it is a spring configured datasource.&lt;br /&gt;&lt;br /&gt;I guess this is a neater and an easier option for me as it saves me the task of upgrading to a newer oracle or downgrading to a older weblogic</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/897955103406671094'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/897955103406671094'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/connecting-to-oracle-817-from.html' title='Connecting to Oracle 8.1.7 from Weblogic10.3'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-9064228973429723666</id><published>2010-03-19T21:50:00.000+05:30</published><updated>2010-03-19T21:50:00.322+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="add"/><category scheme="http://www.blogger.com/atom/ns#" term="ant"/><category scheme="http://www.blogger.com/atom/ns#" term="ear"/><category scheme="http://www.blogger.com/atom/ns#" term="files"/><category scheme="http://www.blogger.com/atom/ns#" term="metainf"/><category scheme="http://www.blogger.com/atom/ns#" term="weblogic-application"/><title type='text'>Ant Ear -Adding weblogic-application.xml</title><content type='html'>One of the extensions we can add to an application is for weblogic.&lt;br /&gt;&lt;br /&gt;We can do so by adding an xml called weblogic-application.xml to an ear&#39;s meta-inf directory and also mention the preferences.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;To add the same to the ear file simply update you ant target for creating the ear file to something like this:&lt;br /&gt;&lt;br /&gt;&amp;lt;ear earfile=&amp;quot;${ear file name}&amp;quot;   appxml=&amp;quot;${meta-inf-directory}/application.xml&amp;quot;&amp;gt;&lt;br /&gt;            &amp;lt;metainf dir=&amp;quot;${meta-inf-directory}&amp;quot; excludes=&amp;quot;application.xml, .mf&amp;quot;&amp;gt;               &lt;br /&gt;            &amp;lt;/metainf&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;One reason you we might want to add this file to your ear file is when we want to provide class loader filtering for certain packages.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/9064228973429723666/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/ant-ear-adding-weblogic-applicationxml.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/9064228973429723666'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/9064228973429723666'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/ant-ear-adding-weblogic-applicationxml.html' title='Ant Ear -Adding weblogic-application.xml'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-4550406360980360306</id><published>2010-03-18T21:55:00.000+05:30</published><updated>2010-03-18T21:55:00.592+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="change"/><category scheme="http://www.blogger.com/atom/ns#" term="multiple datasources"/><category scheme="http://www.blogger.com/atom/ns#" term="runtime"/><category scheme="http://www.blogger.com/atom/ns#" term="spring"/><category scheme="http://www.blogger.com/atom/ns#" term="switch"/><title type='text'>Switching between datasources during runtime</title><content type='html'>Many a times we might want to unit test daos across multiple instances of the same database.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Many a times we might want to update multiple instance of a same database schema , so in such cases we would implement all dao methos in one dao however want to execute the method across multiple databases. In such cases we would want to switch the datasource the dao is connected to during runtime.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;font-size:130%;&quot; &gt;AbstractRoutingDataSource&lt;/span&gt; is the answer I have found for my problem.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;One blog worth mentioning here is &lt;a href=&quot;http://blog.springsource.com/2007/01/23/dynamic-datasource-routing/&quot;&gt;http://blog.springsource.com/2007/01/23/dynamic-datasource-routing/&lt;/a&gt; which helped me understand the whole concept and implement the same.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/4550406360980360306'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/4550406360980360306'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/switching-between-datasources-during.html' title='Switching between datasources during runtime'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-7011940875861584463</id><published>2010-03-18T21:15:00.000+05:30</published><updated>2010-03-18T21:15:00.152+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="apache"/><category scheme="http://www.blogger.com/atom/ns#" term="key"/><category scheme="http://www.blogger.com/atom/ns#" term="map"/><category scheme="http://www.blogger.com/atom/ns#" term="multi"/><category scheme="http://www.blogger.com/atom/ns#" term="value"/><title type='text'>MultiKeyMap , MultiValueMap - Apache commons</title><content type='html'>Very interesting implementation for a map. Something which I have been trying to implement or use for a while.&lt;br /&gt;&lt;br /&gt;This has proved to be very useful, when we are iterating over collection of entities whose primary keys are composite then in such cases multi key maps can be used.&lt;br /&gt;&lt;br /&gt;Simply use it like this&lt;br /&gt;For example if an employee is uniquely identified by his id and department id then we can add it like this.&lt;br /&gt;MultiKeyMap map = new MultiKeyMap();&lt;br /&gt;map.put(employeeID, deptID, employee);&lt;br /&gt;&lt;br /&gt;when getting the value back simply say :&lt;br /&gt;&lt;br /&gt;map.get(employeeID, deptID);&lt;br /&gt;&lt;br /&gt;On the other hand if we wish to store a collection of objects for a given key we can use MultiValueMap.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7011940875861584463'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7011940875861584463'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/multikeymap-multivaluemap-apache.html' title='MultiKeyMap , MultiValueMap - Apache commons'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-3766465227554905388</id><published>2010-03-18T21:01:00.001+05:30</published><updated>2010-03-18T21:01:00.509+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="annotations"/><category scheme="http://www.blogger.com/atom/ns#" term="autowire"/><category scheme="http://www.blogger.com/atom/ns#" term="multiple daos"/><category scheme="http://www.blogger.com/atom/ns#" term="multiple datasources"/><category scheme="http://www.blogger.com/atom/ns#" term="qualifier"/><category scheme="http://www.blogger.com/atom/ns#" term="spring"/><category scheme="http://www.blogger.com/atom/ns#" term="unit . test"/><title type='text'>Unit Testing with multiple daos - AbstractTransactionalDataSourceSpringContextTests</title><content type='html'>I had a scenario where I wanted to unit test my dao methods , however some of the daos depended on data being provided from other daos to run successfully.&lt;br /&gt;&lt;br /&gt;In order to achieve the same I required to be able to configure multiple data sources in my spring config and inject the data sources as and when required.&lt;br /&gt;&lt;br /&gt;I used AbstractTransactionalDataSourceSpringContextTests for my Junit test cases.&lt;br /&gt;&lt;br /&gt;And my spring config xml looked like :&lt;br /&gt;&lt;br /&gt;&lt;br /&gt; &lt;br /&gt;    &amp;lt;!-- Database 1--&amp;gt;&lt;br /&gt;  &amp;lt;bean id=&amp;quot;testDataSource1&amp;quot; class=&amp;quot;org.springframework.jdbc.datasource.SingleConnectionDataSource&amp;quot;&amp;gt;&lt;br /&gt;      &lt;br /&gt;    &amp;lt;/bean&amp;gt;&lt;br /&gt;  &lt;br /&gt;     &amp;lt;!-- Database 2 --&amp;gt;&lt;br /&gt;  &amp;lt;bean id=&amp;quot;testDataSource2&amp;quot; class=&amp;quot;org.springframework.jdbc.datasource.SingleConnectionDataSource&amp;quot;&amp;gt;&lt;br /&gt;      &lt;br /&gt;    &amp;lt;/bean&amp;gt;&lt;br /&gt;&lt;br /&gt;  &amp;lt;bean id=&amp;quot;dao1&amp;quot; class=&amp;quot;Dao1Impl&amp;quot;&amp;gt;&lt;br /&gt;      &amp;lt;property name=&amp;quot;dataSource&amp;quot; ref=&amp;quot;testDataSource1&amp;quot;&amp;gt;&lt;br /&gt;  &amp;lt;/property&amp;gt;&amp;lt;/bean&amp;gt;&lt;br /&gt;&lt;br /&gt;  &amp;lt;bean id=&amp;quot;dao2&amp;quot; class=&amp;quot;Dao2Impl&amp;quot;&amp;gt;&lt;br /&gt;      &amp;lt;property name=&amp;quot;dataSource&amp;quot; ref=&amp;quot;testDataSource2&amp;quot;&amp;gt;&lt;br /&gt;  &amp;lt;/property&amp;gt;&amp;lt;/bean&amp;gt;&lt;br /&gt;&lt;br /&gt;  &amp;lt;bean id=&amp;quot;txManager&amp;quot; class=&amp;quot;org.springframework.jdbc.datasource.DataSourceTransactionManager&amp;quot;&amp;gt;&lt;br /&gt;      &amp;lt;property name=&amp;quot;dataSource&amp;quot; ref=&amp;quot;testDataSource1&amp;quot;&amp;gt;&lt;br /&gt;  &amp;lt;/property&amp;gt;&amp;lt;/bean&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;When I re ran the unit test . I came across the following error:&lt;br /&gt;&lt;br /&gt;org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name &#39;DaoTest&#39;: Unsatisfied dependency expressed through bean property &#39;dataSource&#39;: No unique bean of type [javax.sql.DataSource] is defined: expected single matching bean but found 2: [testDataSource1, testDataSource2]&lt;br /&gt;&lt;br /&gt;I had to change my unit test so that it looked like below:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;import javax.sql.DataSource;&lt;br /&gt;&lt;br /&gt;import org.springframework.beans.factory.annotation.Autowired;&lt;br /&gt;import org.springframework.beans.factory.annotation.Qualifier;&lt;br /&gt;import org.springframework.test.AbstractTransactionalDataSourceSpringContextTests;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;public abstract class BaseTest extends AbstractTransactionalDataSourceSpringContextTests {&lt;br /&gt; &lt;br /&gt; @Autowired&lt;br /&gt; Dao1 dao1;&lt;br /&gt; &lt;br /&gt; @Autowired&lt;br /&gt; Dao2 dao2;&lt;br /&gt; &lt;br /&gt; @Autowired&lt;br /&gt; DataSource testDataSource1;&lt;br /&gt; &lt;br /&gt; @Autowired&lt;br /&gt; DataSource testDataSource2;&lt;br /&gt; &lt;br /&gt; /* (non-Javadoc)&lt;br /&gt;  * @see org.springframework.test.AbstractSingleSpringContextTests#getConfigPath()&lt;br /&gt;  */&lt;br /&gt; @Override&lt;br /&gt; protected String getConfigPath() {&lt;br /&gt;  return &amp;quot;spring-test-config.xml&amp;quot;;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; @Override&lt;br /&gt; @Autowired&lt;br /&gt; public void setDataSource(@Qualifier(&amp;quot;testDataSource1&amp;quot;) final DataSource dataSource){&lt;br /&gt;  super.setDataSource(dataSource);&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @return the dao1&lt;br /&gt;  */&lt;br /&gt; public Dao1 getDao1() {&lt;br /&gt;  return dao1;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @param dao1 the dao1 to set&lt;br /&gt;  */&lt;br /&gt; public void setDao1(Dao1 dao1) {&lt;br /&gt;  this.dao1 = dao1;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @return the dao2&lt;br /&gt;  */&lt;br /&gt; public Dao2 getDao2() {&lt;br /&gt;  return dao2;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @param dao2 the dao2 to set&lt;br /&gt;  */&lt;br /&gt; public void setDao2(Dao2 dao2) {&lt;br /&gt;  this.dao2 = dao2;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @return the testDataSource1&lt;br /&gt;  */&lt;br /&gt; public DataSource getTestDataSource1() {&lt;br /&gt;  return testDataSource1;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @param testDataSource1 the testDataSource1 to set&lt;br /&gt;  */&lt;br /&gt; public void setTestDataSource1(@Qualifier(&amp;quot;testDataSource1&amp;quot;) DataSource testDataSource1) {&lt;br /&gt;  this.testDataSource1 = testDataSource1;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @return the testDataSource2&lt;br /&gt;  */&lt;br /&gt; public DataSource getTestDataSource2() {&lt;br /&gt;  return testDataSource2;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; /**&lt;br /&gt;  * @param testDataSource2 the testDataSource2 to set&lt;br /&gt;  */&lt;br /&gt; public void setTestDataSource2(@Qualifier(&amp;quot;testDataSource2&amp;quot;) DataSource testDataSource2) {&lt;br /&gt;  this.testDataSource2 = testDataSource2;&lt;br /&gt; }&lt;br /&gt; &lt;br /&gt; &lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;the interesting thing above is the @Qualifier annotation which allows us to reference which data sources to inject while initializing the beans.&lt;br /&gt;&lt;br /&gt;Now while writing my test cases I can simply switch between the datasources like :&lt;br /&gt;&lt;br /&gt;setDataSource(getTestDataSource2());&lt;br /&gt;// Perform transaction related to data source 2&lt;br /&gt;setDataSource(getTestDataSource1());&lt;br /&gt;// Set the data source back to the main data source &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I know Unit test cases must be independent , and should be testing on real time data , however if in case a need arises to be able to test the same without having to worry about re deploying and re starting application servers , this method is useful.</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3766465227554905388'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3766465227554905388'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/unit-testing-with-multiple-daos.html' title='Unit Testing with multiple daos - AbstractTransactionalDataSourceSpringContextTests'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-7866394805694364567</id><published>2010-03-17T14:18:00.000+05:30</published><updated>2010-03-17T18:59:36.811+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="driver"/><category scheme="http://www.blogger.com/atom/ns#" term="incompatible"/><category scheme="http://www.blogger.com/atom/ns#" term="jdk"/><category scheme="http://www.blogger.com/atom/ns#" term="old"/><category scheme="http://www.blogger.com/atom/ns#" term="oracle 8.1.7"/><category scheme="http://www.blogger.com/atom/ns#" term="version"/><title type='text'>Oracle Old Driver Vs New Driver</title><content type='html'>exception:code:&lt;span style=&quot;font-weight: bold; color: rgb(0, 0, 153);&quot;&gt;java.lang.ArrayIndexOutOfBoundsException: 4at oracle.jdbc.driver.T4C8TTIdty.marshal(T4C8TTIdty.java:465)&lt;/span&gt;at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:329)at oracle.jdbc.driver.PhysicalConnection.&lt;init&gt;(PhysicalConnection.java:490)at oracle.jdbc.driver.T4CConnection.&lt;init&gt;(T4CConnection.java:202)at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:33)at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:474)at&lt;br /&gt;&lt;br /&gt;Recently while trying to work with an oracle database I came across this wierd error. Thanks to some help which I recieved from forums. I was able to get rid of this problem&lt;br /&gt;&lt;br /&gt;This problem occurs when you are working with a new version of JDK with an older version of Oracle.&lt;br /&gt;&lt;br /&gt;Its often good practice to check the compatibility tables for JDK , Oracle database and driver versions before trying to code.&lt;br /&gt;&lt;br /&gt;In my case I was using ojdbc6.jar which is the latest an compatible for oracle 11g as well and works well with JDK 6. However the database I was trying to connect to was Oracle &lt;span style=&quot;font-weight: bold; color: rgb(255, 0, 0);&quot;&gt;8.1.7&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Hence this wierd error.&lt;br /&gt;&lt;br /&gt;To solve the problem I simply added an older version driver namely &lt;span style=&quot;font-weight: bold; color: rgb(0, 102, 0);&quot;&gt;classes12.jar&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Other thing to note is there is a significant difference in the package name for the OracleDriver class.&lt;br /&gt;&lt;br /&gt;In order to find the current version of oracle you are running we can use:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-style: italic; font-weight: bold; color: rgb(255, 102, 0);&quot;&gt;select * from product_component_version&lt;/span&gt;</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/7866394805694364567/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/oracle-old-driver-vs-new-driver.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7866394805694364567'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7866394805694364567'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/oracle-old-driver-vs-new-driver.html' title='Oracle Old Driver Vs New Driver'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-1878050783525880104</id><published>2010-03-17T01:59:00.000+05:30</published><updated>2010-03-17T19:06:14.636+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="jdbc"/><category scheme="http://www.blogger.com/atom/ns#" term="oracle 8.1.7"/><category scheme="http://www.blogger.com/atom/ns#" term="single datasource connection suppressclose"/><title type='text'>SingleConnectionDataSource Oracle supressClose</title><content type='html'>org.springframework.transaction.CannotCreateTransactionException: Could not open JDBC Connection for transaction; nested exception is java.sql.SQLException: Connection was closed in SingleConnectionDataSource. Check that user code checks shouldClose() before closing Connections, or set &#39;suppressClose&#39; to &#39;true&#39;&lt;br /&gt;    at org.springframework.jdbc.datasource.DataSourceTransactionManager.doBegin(DataSourceTransactionManager.java:238)&lt;br /&gt;    at org.springframework.transaction.support.AbstractPlatformTransactionManager.getTransaction(AbstractPlatformTransactionManager.java:377)&lt;br /&gt;    at org.springframework.test.AbstractTransactionalSpringContextTests.startNewTransaction(AbstractTransactionalSpringContextTests.java:387)&lt;br /&gt;    at org.springframework.test.AbstractTransactionalSpringContextTests.onSetUp(AbstractTransactionalSpringContextTests.java:217)&lt;br /&gt;    at org.springframework.test.AbstractSingleSpringContextTests.setUp(AbstractSingleSpringContextTests.java:103)&lt;br /&gt;    at junit.framework.TestCase.runBare(TestCase.java:132)&lt;br /&gt;    at org.springframework.test.ConditionalTestCase.runBare(ConditionalTestCase.java:76)&lt;br /&gt;    at junit.framework.TestResult$1.protect(TestResult.java:110)&lt;br /&gt;    at junit.framework.TestResult.runProtected(TestResult.java:128)&lt;br /&gt;    at junit.framework.TestResult.run(TestResult.java:113)&lt;br /&gt;    at junit.framework.TestCase.run(TestCase.java:124)&lt;br /&gt;    at junit.framework.TestSuite.runTest(TestSuite.java:232)&lt;br /&gt;    at junit.framework.TestSuite.run(TestSuite.java:227)&lt;br /&gt;    at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:83)&lt;br /&gt;    at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:45)&lt;br /&gt;    at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)&lt;br /&gt;    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)&lt;br /&gt;    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)&lt;br /&gt;    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)&lt;br /&gt;    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)&lt;br /&gt;Caused by: java.sql.SQLException: Connection was closed in SingleConnectionDataSource. Check that user code checks shouldClose() before closing Connections, or set &#39;suppressClose&#39; to &#39;true&#39;&lt;br /&gt;    at org.springframework.jdbc.datasource.SingleConnectionDataSource.getConnection(SingleConnectionDataSource.java:190)&lt;br /&gt;    at org.springframework.jdbc.datasource.lookup.AbstractRoutingDataSource.getConnection(AbstractRoutingDataSource.java:133)&lt;br /&gt;    at org.springframework.jdbc.datasource.DataSourceTransactionManager.doBegin(DataSourceTransactionManager.java:200)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;While trying to perform unit tests on the various dao methods I had written for an Oracle database (8.1.7) using a SingleConnectionDatasource i came across this exception.&lt;br /&gt;&lt;br /&gt;As a result I had to set suppressClose to true for the data source and manually close the transaction after each test case, using the tearDown method like following:&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;@Override&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;    protected void onTearDown() throws Exception {&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;        super&lt;/span&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;.onTearDown();&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;        Connection con = DataSourceUtils.getConnection(getJdbcTemplate().getDataSource());&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;        DataSourceUtils.releaseConnection(con, getJdbcTemplate().getDataSource());&lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;        &lt;/span&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold; font-style: italic;&quot;&gt;    }&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This helps to avoid the above problem</content><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/1878050783525880104'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/1878050783525880104'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2010/03/singleconnectiondatasource-oracle.html' title='SingleConnectionDataSource Oracle supressClose'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-2857258582914546863</id><published>2009-08-03T08:27:00.002+05:30</published><updated>2010-03-18T13:23:52.912+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="eclipse"/><category scheme="http://www.blogger.com/atom/ns#" term="java fx"/><category scheme="http://www.blogger.com/atom/ns#" term="net beans"/><category scheme="http://www.blogger.com/atom/ns#" term="plugin"/><title type='text'>JavaFX Plugins available for Eclipse.</title><content type='html'>I started by installing the plugin created by Sun.  Then I migrated to the plugin created by exadel.&lt;br /&gt;&lt;br /&gt;Found the exadel plugin to be more friendly and less error prone .&lt;br /&gt;&lt;br /&gt;However lack of context assist and code coloring in eclipse kind of turned me down.&lt;br /&gt;&lt;br /&gt;Net beans is I guess the best IDE to work with javaFX as far as playing around and getting to know is concerned.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/2857258582914546863/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/08/javafx-plugins-available-for-eclipse.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/2857258582914546863'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/2857258582914546863'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/08/javafx-plugins-available-for-eclipse.html' title='JavaFX Plugins available for Eclipse.'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-4093263716658754677</id><published>2009-08-01T07:43:00.003+05:30</published><updated>2009-08-01T07:50:52.749+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="management studio"/><category scheme="http://www.blogger.com/atom/ns#" term="mysql"/><category scheme="http://www.blogger.com/atom/ns#" term="sql server"/><category scheme="http://www.blogger.com/atom/ns#" term="sqlyog"/><title type='text'>MySQL SQLyog</title><content type='html'>&lt;div&gt;I have been actively using SQL Server 2005 for the past three four years. One of the things I like about it is its management studio , most of times I spend trying to design my queries , optimize them and add indexes accordingly.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Its graphical nature helps me work around SQL&#39;s in a better manner. I have not tried the express edition which is free .&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;One of the opensource databases around includes MySQL. It lacks a elegant GUI management portal. The Query Browser provides some features but not all.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I have recently come across this GUI management tool for the same called SQLyog. It provides all features similar to MS SQL Server management studio.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Convenient to make ER diagrams.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Powerful report generation.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Monitoring Support. etc&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;I will keep updating this post as and when I come across some more useful features.&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/4093263716658754677/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/08/mysql-sqlyog.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/4093263716658754677'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/4093263716658754677'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/08/mysql-sqlyog.html' title='MySQL SQLyog'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-3092118126405753466</id><published>2009-07-24T14:14:00.000+05:30</published><updated>2009-07-24T14:14:00.177+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="forum"/><category scheme="http://www.blogger.com/atom/ns#" term="stackoverflow"/><category scheme="http://www.blogger.com/atom/ns#" term="work"/><title type='text'>StackOverflow</title><content type='html'>Nabble, ExpertExchange, Technology Forums and StackOverFlow.&lt;br /&gt;&lt;br /&gt;All friends in time of need. Quality of questions and answers has been good so far on Stackoverflow.&lt;br /&gt;&lt;br /&gt;One can login using Google as the open ID and easy p easy there on.&lt;br /&gt;&lt;br /&gt;quest and anst journey begins</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/3092118126405753466/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/stackoverflow.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3092118126405753466'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3092118126405753466'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/stackoverflow.html' title='StackOverflow'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-8001918244156334117</id><published>2009-07-23T14:38:00.000+05:30</published><updated>2009-07-23T14:38:00.183+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="creat"/><category scheme="http://www.blogger.com/atom/ns#" term="design"/><category scheme="http://www.blogger.com/atom/ns#" term="free"/><category scheme="http://www.blogger.com/atom/ns#" term="mockups"/><category scheme="http://www.blogger.com/atom/ns#" term="open source"/><category scheme="http://www.blogger.com/atom/ns#" term="pencil"/><category scheme="http://www.blogger.com/atom/ns#" term="png"/><category scheme="http://www.blogger.com/atom/ns#" term="save"/><title type='text'>Free Mockup Designer - Pencil - FireFox</title><content type='html'>As a matter of interest I was trying to find out more about how to create digital mockups of software.&lt;br /&gt;&lt;br /&gt;I have seen people using Visio, Adobe illustrator etc in the past. But in the world of open source there is a need of a good mockup designer.&lt;br /&gt;&lt;br /&gt;Google my friend showed me some options.&lt;br /&gt;&lt;br /&gt;ForeUI - Trial period - 7 days - not worth it , big download and no advantage&lt;br /&gt;DesignerVista - Trial period - 20 days - save and print feature disabled - good for nothing&lt;br /&gt;Balasmiq - Again we need to buy it aftera few days of trial, but good for its purpose i have read.&lt;br /&gt;&lt;br /&gt;Fnally i chose Pencil , a plugin for firefox 3 onwards. Its allows the user to create mockups using windows widgets and some GTW widgets. We can also export the same to PNGs , which we can use in our high level designs and low level designs.&lt;br /&gt;&lt;br /&gt;Served my purpose.&lt;br /&gt;&lt;br /&gt;You can visitit at http://www.evolus.vn/Pencil/</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/8001918244156334117/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/free-mockup-designer-pencil-firefox.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/8001918244156334117'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/8001918244156334117'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/free-mockup-designer-pencil-firefox.html' title='Free Mockup Designer - Pencil - FireFox'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-3555628982485151385</id><published>2009-07-23T13:48:00.000+05:30</published><updated>2009-07-23T13:48:00.425+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="free"/><category scheme="http://www.blogger.com/atom/ns#" term="hosting"/><category scheme="http://www.blogger.com/atom/ns#" term="project"/><title type='text'>Free Project Hosting</title><content type='html'>Disclaimer : I am speaking ahead of myself , when I talk about this. But I have read and sound a few good options.&lt;br /&gt;&lt;br /&gt;SourceForge: http://sourceforge.net/ - Open Source, Free&lt;br /&gt;Google : http://code.google.com/projecthosting/ - Open Source&lt;br /&gt;China University : https://opensvn.csie.org/ - Unlimited Storage , Free-Private&lt;br /&gt;Project Locker:  https://www.projectlocker.com - 500MB storage , free - 5 users-Private&lt;br /&gt;&lt;br /&gt;These sites also provide free bug tracking , wiki, dashboard and integration and review facilities.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/3555628982485151385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/free-project-hosting.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3555628982485151385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3555628982485151385'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/free-project-hosting.html' title='Free Project Hosting'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-7167722138820526566</id><published>2009-07-22T14:47:00.000+05:30</published><updated>2009-07-24T04:17:37.119+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="analytics"/><category scheme="http://www.blogger.com/atom/ns#" term="content"/><category scheme="http://www.blogger.com/atom/ns#" term="efficient"/><category scheme="http://www.blogger.com/atom/ns#" term="google"/><category scheme="http://www.blogger.com/atom/ns#" term="tracking"/><category scheme="http://www.blogger.com/atom/ns#" term="visitor"/><category scheme="http://www.blogger.com/atom/ns#" term="website"/><title type='text'>Google Analytics</title><content type='html'>Well once you have got a blog or a website setup , you would like to know more about the visitors so as to customise the website better for the audience.&lt;br /&gt;&lt;br /&gt;I realised it really easy to do so using Google Analytics. All you need to have it a google id and then you can login using the same to google analytics .&lt;br /&gt;&lt;br /&gt;Set up a profile for the website you want to track. Follow the instructions and copy the javascript snippet provided by them into the template for you website pages, such that each time you create a new page , the script is included in it.&lt;br /&gt;&lt;br /&gt;This helps analytics track the visitors and their information and also helps you improve the content.&lt;br /&gt;&lt;br /&gt;Its all easy when you are with google.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Traditionally , some website provide this by giving you website visitor counters which you can then display on the website , and then you can log into the tracking website to get more information about the visitors etc, However why maintain other accounts when you can manage it all with one id.&lt;br /&gt;&lt;br /&gt;Google is winning and so am I.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/7167722138820526566/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/google-analytics.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7167722138820526566'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7167722138820526566'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/google-analytics.html' title='Google Analytics'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-7014705212212986898</id><published>2009-07-03T13:25:00.002+05:30</published><updated>2009-07-03T13:33:33.655+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="concurrent"/><category scheme="http://www.blogger.com/atom/ns#" term="desktop"/><category scheme="http://www.blogger.com/atom/ns#" term="real"/><category scheme="http://www.blogger.com/atom/ns#" term="remote"/><category scheme="http://www.blogger.com/atom/ns#" term="session"/><category scheme="http://www.blogger.com/atom/ns#" term="vnc"/><category scheme="http://www.blogger.com/atom/ns#" term="windows"/><title type='text'>Real VNC</title><content type='html'>Real Virtual Network Client.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;I was looking for remote desktop clients apart from the standard windows desktop client.&lt;br /&gt;&lt;br /&gt;I found this Real VNC Server and Client. All you need is to start the Real VNC Server on the machine you want to be accessible remotely. Configure the server with the user details and password details.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Install Real VNC Client on the machine you want to start the connection from. &lt;br /&gt;&lt;br /&gt;It can be accessed via TCP IP over the internet as well.&lt;br /&gt;&lt;br /&gt;However I cannnot get concurrent sessions working. It seems windows SP@ released a terminal services DLL which supposedly fixes this problem.&lt;br /&gt;&lt;br /&gt;However its almost like hacking your system and you dont want to be playing with your system dlls.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/7014705212212986898/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/real-vnc.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7014705212212986898'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7014705212212986898'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/real-vnc.html' title='Real VNC'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-7155255294733859856</id><published>2009-07-03T13:15:00.003+05:30</published><updated>2009-07-03T13:25:25.517+05:30</updated><category scheme="http://www.blogger.com/atom/ns#" term="eclipse"/><category scheme="http://www.blogger.com/atom/ns#" term="europa"/><category scheme="http://www.blogger.com/atom/ns#" term="galileo"/><category scheme="http://www.blogger.com/atom/ns#" term="intellij"/><category scheme="http://www.blogger.com/atom/ns#" term="netbeans"/><title type='text'>Eclipse  Europa is a hit and Galileo is out</title><content type='html'>I am a fan of the Eclipse IDE. Firstly because it suits my needs as a java developer and also because its free and yet has so much support via plugins , forums and help.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Eclipse Subversion Integration is really good, so good that I prefer that to the command line client and tortoise svn as well.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Eclipse JIRA integration is also good.&lt;br /&gt;&lt;br /&gt;Some other plugins are PyDev for Python , Spring , JSF , XML, FOP, Hibernate, XSL Ant JUnit, TestNG, Wicket, Jetty.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Really good someone wanting to work with client server based applications.&lt;br /&gt;&lt;br /&gt;Some of my friends have used IntelliJ , NetBeans, VisualStudio etc.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Please try the one which suits your options and reap the benifits.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Also good If you want to debug remote applications and local applications.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/7155255294733859856/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/eclipse-europa-is-hit-and-galileo-is.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7155255294733859856'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/7155255294733859856'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/eclipse-europa-is-hit-and-galileo-is.html' title='Eclipse  Europa is a hit and Galileo is out'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6616712419102560713.post-3319592805457360135</id><published>2009-07-03T13:07:00.002+05:30</published><updated>2009-07-03T13:15:06.776+05:30</updated><title type='text'>Office 2007 Vs 2003</title><content type='html'>Tried to avoid this as much as possible, but windows has its own way of making things interdependent. Yes I have installed MS Office on my laptop after almost one and a half year it being released. The only reason being I had got used to MS Office 2003 and and also wanted to retain Internet explorer 7 on my machine.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;IE 8 is part of the package to get MS Office 2007 installed. &lt;br /&gt;&lt;br /&gt;But I did like some features like as soon as you highlight a text Word gives out all options to format the text , cool , MS Excel also has got a lot of new menu changes as well as toolbar changes . Its an interesting journey and I have just started getting used to it. As very soon it will be part of industry standard.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Yet to explore the features of IE 8 , very difficult when you have firefox 3 and chrome to compare with.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Please watch this space for more MS office updates.</content><link rel='replies' type='application/atom+xml' href='http://dumpingbrain.blogspot.com/feeds/3319592805457360135/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/office-2007-vs-2003.html#comment-form' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3319592805457360135'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6616712419102560713/posts/default/3319592805457360135'/><link rel='alternate' type='text/html' href='http://dumpingbrain.blogspot.com/2009/07/office-2007-vs-2003.html' title='Office 2007 Vs 2003'/><author><name>Unknown</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='16' height='16' src='https://img1.blogblog.com/img/b16-rounded.gif'/></author><thr:total>0</thr:total></entry></feed>