<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" gd:etag="W/&quot;D0cFQ3gyfyp7ImA9WhdRE08.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089</id><updated>2011-08-03T00:43:32.697+02:00</updated><category term="apache" /><category term="lazy" /><category term="hibernate" /><category term="detach" /><category term="annotation" /><category term="testng" /><category term="surefire" /><category term="scanning" /><category term="testcase" /><category term="ci" /><category term="maven" /><category term="rtfm" /><category term="hg" /><category term="entity" /><title>Java addict</title><subtitle type="html" /><link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/posts/default" /><link rel="alternate" type="text/html" href="http://dcsepely.blogspot.com/" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><generator version="7.00" uri="http://www.blogger.com">Blogger</generator><openSearch:totalResults>8</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/JavaAddict" /><feedburner:info uri="javaaddict" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><entry gd:etag="W/&quot;CUQDRn04cSp7ImA9WxNSGU0.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-4131208135498325442</id><published>2009-09-02T16:38:00.003+02:00</published><updated>2009-09-02T16:56:17.339+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-09-02T16:56:17.339+02:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="scanning" /><category scheme="http://www.blogger.com/atom/ns#" term="annotation" /><title>Scanning java annotations - reflections</title><content type="html">&lt;p&gt;&lt;a href="http://code.google.com/p/reflections/"&gt;reflections&lt;/a&gt;&lt;/p&gt;&lt;p&gt;"Reflections scans your classpath, indexes the metadata, allows you to query it on runtime and may save and collect that information for many modules within your project."&lt;/p&gt;&lt;p&gt;Related project: &lt;a href="http://bill.burkecentral.com/2008/01/14/scanning-java-annotations-at-runtime/"&gt;scannotation&lt;/a&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-4131208135498325442?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/jrQ5Vh_tuOk" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/4131208135498325442/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=4131208135498325442" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/4131208135498325442?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/4131208135498325442?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/jrQ5Vh_tuOk/scanning-java-annotations-reflections.html" title="Scanning java annotations - reflections" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2009/09/scanning-java-annotations-reflections.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CkYAQHs9eyp7ImA9WxNSE0Q.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-6572181303098911958</id><published>2009-08-27T17:34:00.010+02:00</published><updated>2009-08-27T18:22:21.563+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-08-27T18:22:21.563+02:00</app:edited><title>Troubleshooting Deployment in Glassfish + XSD Namespaces</title><content type="html">&lt;a href="http://blogs.sun.com/swchan/entry/troubleshooting_deployment_in_glassfish"&gt;Troubleshooting Deployment in Glassfish&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Plussz amit sosem talalok amikor kell, nem birom megjegyezni es nem rakok fel 20 kilos eclipse plugint erte:&lt;br /&gt;&lt;br /&gt;application.xml&lt;br /&gt;&lt;pre name="code" class="xml"&gt;&amp;lt;application xmlns=&amp;quot;http://java.sun.com/xml/ns/javaee&amp;quot; xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot; version=&amp;quot;5&amp;quot; xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd&amp;gt;&lt;/pre&gt;&lt;br /&gt;ejb-jar.xml&lt;br /&gt;&lt;pre name="code" class="xml"&gt;&amp;lt;ejb-jar xmlns=&amp;quot;http://java.sun.com/xml/ns/javaee&amp;quot; xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot; version=&amp;quot;3.0&amp;quot; xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd&amp;quot;&amp;gt;&lt;/pre&gt;&lt;br /&gt;web.xml&lt;br /&gt;&lt;pre name="code" class="xml"&gt;&amp;lt;web-app version=&amp;quot;2.5&amp;quot; xmlns=&amp;quot;http://java.sun.com/xml/ns/javaee&amp;quot; xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot; xsi:schemaLocation=&amp;quot;http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd&amp;quot;&amp;gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-6572181303098911958?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/EiE3JZp83nU" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/6572181303098911958/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=6572181303098911958" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/6572181303098911958?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/6572181303098911958?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/EiE3JZp83nU/troubleshooting-deployment-in-glassfish.html" title="Troubleshooting Deployment in Glassfish + XSD Namespaces" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2009/08/troubleshooting-deployment-in-glassfish.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0AMQX85fip7ImA9WxNTFEg.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-1849393519619230871</id><published>2009-08-16T22:42:00.005+02:00</published><updated>2009-08-16T22:49:40.126+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-08-16T22:49:40.126+02:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="hg" /><category scheme="http://www.blogger.com/atom/ns#" term="rtfm" /><title>HG ignore RTFM</title><content type="html">Eclipse-esek .hgignore file-jaban a &lt;span style="font-style:italic;"&gt;.project&lt;/span&gt; biztosan megtalalhato. Sideeffectje a dolognak, hogy barmi amiben benne van a &lt;span style="font-style:italic;"&gt;project&lt;/span&gt; ignoralva lesz. Hg baratunk ket pattern syntax-ot is tud, celszeru explicit megadni melyiket hasznaljuk:&lt;br /&gt;&lt;br /&gt;&lt;div&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;syntax: glob&lt;/span&gt;&lt;br /&gt;.project&lt;br /&gt;...&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Tovabbi RTFM &lt;a href="http://www.selenic.com/mercurial/hgignore.5.html"&gt;itt&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-1849393519619230871?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/5vs16WIG6mM" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/1849393519619230871/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=1849393519619230871" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/1849393519619230871?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/1849393519619230871?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/5vs16WIG6mM/hg-ignore-rtfm.html" title="HG ignore RTFM" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2009/08/hg-ignore-rtfm.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0ICQ3c6fCp7ImA9WxJbEEQ.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-2882532473544715428</id><published>2009-07-20T16:16:00.004+02:00</published><updated>2009-07-20T16:19:22.914+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-07-20T16:19:22.914+02:00</app:edited><title>Building Artifactory RTFM</title><content type="html">"How do I build Artifactory from source? Maven tells me there are some missing dependencies.&lt;br /&gt;&lt;br /&gt;Simply download the source and run mvn clean install from within the Artifactory root module (parent").&lt;br /&gt;To gain access to open source dependencies not currently deployed on Maven's public repositories, you have to run mvn with the artifactory profile activate. e.g.:&lt;br /&gt;mvn clean install -Partifactory."&lt;br /&gt;&lt;br/&gt;&lt;br /&gt;&lt;p&gt;&lt;a href="http://wiki.jfrog.org/confluence/display/RTF/Usage"&gt;http://wiki.jfrog.org/confluence/display/RTF/Usage&lt;/a&gt;&lt;br /&gt;&lt;/p&gt;&lt;br/&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-2882532473544715428?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/x70h81WyvA0" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/2882532473544715428/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=2882532473544715428" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/2882532473544715428?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/2882532473544715428?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/x70h81WyvA0/building-artifactory-rtfm.html" title="Building Artifactory RTFM" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2009/07/building-artifactory-rtfm.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkYASHs9cSp7ImA9WxJUGEo.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-9198376192149121047</id><published>2009-07-18T01:38:00.002+02:00</published><updated>2009-07-18T01:42:29.569+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2009-07-18T01:42:29.569+02:00</app:edited><title>Lodon Wicket (Yeah, London BABY)</title><content type="html">&lt;p&gt;Wicket-es eloadas slidok, forrasok, webcast-ok, stb:&lt;/p&gt;&lt;p&gt;&lt;a href="http://code.google.com/p/londonwicket/"&gt;London-Wicket&lt;/a&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-9198376192149121047?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/oHlY-LZ04hE" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/9198376192149121047/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=9198376192149121047" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/9198376192149121047?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/9198376192149121047?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/oHlY-LZ04hE/lodon-wicket-yeah-london-baby.html" title="Lodon Wicket (Yeah, London BABY)" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2009/07/lodon-wicket-yeah-london-baby.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DEcERX88cCp7ImA9WxdbEkw.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-8549293177949966066</id><published>2008-08-08T19:15:00.003+02:00</published><updated>2008-08-08T19:20:04.178+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2008-08-08T19:20:04.178+02:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="ci" /><category scheme="http://www.blogger.com/atom/ns#" term="apache" /><category scheme="http://www.blogger.com/atom/ns#" term="maven" /><title>Maven vs Apache snapshot repository</title><content type="html">&lt;p style="margin: 10px 0 10px 0;"&gt;Addot a kovetkezo motto:&lt;/p&gt;&lt;blockquote&gt;&lt;p style="margin: 10px 0 10px 0;"&gt;Apache Maven Simplifies the Java Build Process — Even More Than Ant&lt;/p&gt;&lt;/blockquote&gt;&lt;p style="margin: 10px 0 10px 0;"&gt;A fenti idezet alapjan felteteleztem, hogy egy snapshot-os dependency-t behuzhatok a sajat projectembe. Csak hat a Apache Snapshot Repository-n a kivant artifact alatt a kovetkezo kep fogadott: &lt;a href="http://people.apache.org/repo/m2-snapshot-repository/org/apache/commons/commons-cli/2.0-SNAPSHOT/"&gt;m2-snapshot-repository&lt;/a&gt;.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-8549293177949966066?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/oPWg0ul6Scs" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/8549293177949966066/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=8549293177949966066" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/8549293177949966066?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/8549293177949966066?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/oPWg0ul6Scs/maven-vs-apache-snapshot-repository.html" title="Maven vs Apache snapshot repository" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2008/08/maven-vs-apache-snapshot-repository.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Ck8ARHszfyp7ImA9WxdbEEo.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-8167124722787442317</id><published>2008-08-07T11:24:00.000+02:00</published><updated>2008-08-07T03:00:45.587+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2008-08-07T03:00:45.587+02:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="hibernate" /><category scheme="http://www.blogger.com/atom/ns#" term="entity" /><category scheme="http://www.blogger.com/atom/ns#" term="lazy" /><category scheme="http://www.blogger.com/atom/ns#" term="detach" /><title>Lazy fetching a'tka</title><content type="html">&lt;p style="MARGIN: 10px 0px"&gt;Aki hasznalt/hasznal ORM framework-ot, biztos vagyok benne, hogy talalkozott mar a &lt;em&gt;LAZY&lt;/em&gt;/&lt;em&gt;EAGER&lt;/em&gt; fetching modokkal. Mind a ket loading modnak megvan az elonye/hatranya. Jelen esetben &lt;em&gt;LAZY&lt;/em&gt; mod egyik igen bosszanto es gyakran elofordulo hatranyaval fogok foglalkozni, delikvens ORM pedig a Hibernate3.&lt;/p&gt;&lt;p&gt;Tegyuk fel, hogy three tier-es kornyezetben vagyunk es presentation tier-hez szeretnenk eljuttatni egy entity-t a business tier-bol. Az entity-nk neve legyen A.&lt;br /&gt;&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;&lt;div class="java" align="left"&gt;&lt;table cellspacing="0" cellpadding="3" border="0"  style="color:#ffffff;"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;!-- start source code --&gt;&lt;td valign="top" align="left"&gt;&lt;code&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;class &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;A &lt;/span&gt;&lt;span style="color:#000000;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;private &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;int &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;id;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;private &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;List&amp;lt;B&amp;gt; b;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;class &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;B &lt;/span&gt;&lt;span style="color:#000000;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;int &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;id;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;private &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;List&amp;lt;C&amp;gt; c;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;}&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;class &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;C &lt;/span&gt;&lt;span style="color:#000000;"&gt;{&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;int &lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;id;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;}&lt;/span&gt;&lt;/code&gt; &lt;/td&gt;&lt;!-- end source code --&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;p style="MARGIN: 10px 0px"&gt;Fenti kodreszlet lenyegeben az A entitynk strukturajat mutatja. Fontos, hogy B es C is entity, tehat adatbazis szinten harom tablank van. A-ban talalhato B illetve a B-ben levo C lista &lt;em&gt;LAZY&lt;/em&gt; modos fetching-t hasznal, JOIN kapcsolat van koztuk. Tehat A.getB() illetve B.getC() egy proxy-zott listat fog visszadni, csak akkor lesz populalva, ha valaki hasznalni akarja (pl. amikor vegig akarunk iteralni rajta).&lt;/p&gt;&lt;p style="align: 10px 0 10px 0"&gt;Perfomance szempontjabol teljesen korrekt megoldas, minek betolteni azt, amit nem is biztos, hogy hasznalunk. Azonban van egy exception amivel szerintem minden Hibernate "barat" talalkozott mar: &lt;em&gt;org.hibernate.LazyInitializationException&lt;/em&gt;. Ezt az exception akkor kapjuk, amikor egy proxyzott listan akarunk vegigiteralni, viszont a Hibernate session-unk mar nem letezik, igy a lista populalasa meghiusult. &lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;Tegyuk fel, hogy presentation tier es a business tier kozott WebService-en keresztul mozognak az egyes entity-k. Marshalling soran (Object -&gt; XML) valoszinuleg kapni fogunk egy exception a lazy loading miatt. A &lt;em&gt;LazyInitializationException&lt;/em&gt;-t ugy tudjuk elkerulni, hogy az entitynket &lt;em&gt;detach&lt;/em&gt;-eljuk, tehat a lazy loados listakat betoltjuk meg mielott a Hibernate session megszunne.&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;Kinai farmeres modszerrel megtehetjuk azt, hogy vegigiteralunk az oszes lista elemen, viszont nem a legegeszsegesebb. Szerencsere Hibernate biztosit szamunkra egy built-in utility methodot, &lt;em&gt;org.hibernate.Hibernate#initialize(Object proxy)&lt;/em&gt;. A proxy-zott listakat atjuk a &lt;em&gt;initialize()&lt;/em&gt; methodusnak igy initializalva lesz a listank.&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;A fentiek alapjan, azt gondolnank, hogy a kovetkezo dologgal meg is oldottuk a marshalling problemat:&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;&lt;div class="java" align="left"&gt;&lt;table cellspacing="0" cellpadding="3" border="0"  style="color:#ffffff;"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;!-- start source code --&gt;&lt;td valign="top" align="left"&gt;&lt;code&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;A a = &lt;/span&gt;&lt;span style="color:#7f0055;"&gt;&lt;b&gt;...&lt;/b&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;;&lt;/span&gt;&lt;br /&gt;&lt;span style="color:#ffffff;"&gt;&lt;/span&gt;&lt;span style="color:#000000;"&gt;Hibernate.initialize&lt;/span&gt;&lt;span style="color:#000000;"&gt;(&lt;/span&gt;&lt;span style="color:#000000;"&gt;a.getB&lt;/span&gt;&lt;span style="color:#000000;"&gt;())&lt;/span&gt;&lt;span style="color:#000000;"&gt;;&lt;/span&gt;&lt;/code&gt; &lt;/td&gt;&lt;!-- end source code --&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;/div&gt;&lt;p&gt;&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;Ha megfigyeljuk akkor B entity szinten tartalmaz egy proxyzott listat (C). Ezen lista nem kerul initializalasra, igy B entity C listajan is meg kellene hivnunk a &lt;em&gt;initialize()&lt;/em&gt; methodust. Egy nagyon complex model eseten tobb szaz soros kodreszlet lesz, ami a detach-et vegzi, ami nem a legszebb latvany, illetve konnyu hibat veteni.&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;Tegyuk fel, hogy a detach-et vegzo kodot megirtuk, viszont RMI-re valtunk WebService helyett. Az RMI legjobb tulajdonsaga az, hogy egy az egyben kiszerializalja az objecteket, nem kell DDL, WebService esetben viszont igen. Ezen jo tulajdonsaga lesz esetunkben a hatranya, ugyanis List objectek konkret tipusa Hibernate fuggo, sajat tipusok. Ha a presentation tier dependency listaja nem tartalmazza a Hibernate libeket, akkor &lt;em&gt;NoClassFoundException &lt;/em&gt;fogunk kapni. &lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;Most erkeztunk el a lenyeghez amiert ezt a post-ot megirtam. Letezik egy megoldas, ami a teljes detach-es kodiras terhet leveszi a vallunkrol, illetve a RMI-s problemat is eliminalja. A utility class neve, ami nem resze a Hibernate CORE-nak (egyenlore), &lt;a href="http://lists.jboss.org/pipermail/jboss-user/2008-July/126064.html"&gt;HibernateCleaner&lt;/a&gt;. Ahoz, hogy detach-eljuk illetve a megszabaduljunk a hibernate dependent class tipusoktol, meg kell hivnunk a &lt;em&gt;clean()&lt;/em&gt; metodust.&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-8167124722787442317?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/QCWzwr-iOPk" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/8167124722787442317/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=8167124722787442317" title="3 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/8167124722787442317?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/8167124722787442317?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/QCWzwr-iOPk/lazy-fetching-atka.html" title="Lazy fetching a'tka" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>3</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2008/08/lazy-fetching-atka.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkYMR3s5fyp7ImA9WxdUGEU.&quot;"><id>tag:blogger.com,1999:blog-608056730343816089.post-5144080500904171339</id><published>2008-08-04T20:02:00.000+02:00</published><updated>2008-08-04T23:09:46.527+02:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2008-08-04T23:09:46.527+02:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="testng" /><category scheme="http://www.blogger.com/atom/ns#" term="testcase" /><category scheme="http://www.blogger.com/atom/ns#" term="maven" /><category scheme="http://www.blogger.com/atom/ns#" term="surefire" /><title>TestCase debugolas ala SureFire</title><content type="html">&lt;p&gt;Kovetkezo problemaval szembesultunk a minap: Adott N darab TestNG-s TestCase + Maven. TestNG-s Eclipse plugin-al az osszes TestCase szepen lefut, viszont &lt;span style="font-family:lucida grande;font-size:12px;"&gt;&lt;em&gt;mvn clean install&lt;/em&gt;&lt;/span&gt; hatasara failel 2-3 db. &lt;/p&gt;&lt;p&gt;Roviden tomoren, a reakcio: &lt;strong&gt;W*F???&lt;/strong&gt;&lt;/p&gt;&lt;p style="MARGIN: 10px 0px"&gt;Mivel az intuicios kepesseg csodot modott, ezert debugos modszereket vetettunk be. Eloszor minden jozan eszu ember, aki m2eclipse-et hasznal, megporbalja maven-os runnerrel debug-olni. Problema az, hogy breakpoint-on atszaladt az egesz, kvazi surefire va... (oreg es faradt vagyok, hogy megnezzem a plugin forrasat, akinek konkluzio kell varjon egy kicsit :P)&lt;/p&gt;&lt;p style="MARGIN: 10px 0"&gt;&lt;strong&gt;RTFM:&lt;/strong&gt;&lt;/p&gt;&lt;div style="width: 100%; background-color: silver;border:1px solid black; display: block;"&gt;&lt;p style="margin: 10px 10px 10px 10px"&gt;&lt;span style="font-family:lucida grande;font-size:12px;"&gt;&lt;em&gt;mvn clean install -Dmaven.surefire.debug="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000 -Xnoagent"&lt;/em&gt;&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;p style="MARGIN: 10px 0px 10px 0px"&gt;A fenti "magic" parameterrel ellatott maven, lehetove teszi, hogy remote debug-oljuk a TestCase-ek futtatasat/futasat.&lt;/p&gt;&lt;p style="margin: 10px 0 10px 0"&gt;Ref.: &lt;a href="http://maven.apache.org/plugins/maven-surefire-plugin/examples/debugging.html"&gt;Surfire - Debugging Tests&lt;/a&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/608056730343816089-5144080500904171339?l=dcsepely.blogspot.com' alt='' /&gt;&lt;/div&gt;&lt;img src="http://feeds.feedburner.com/~r/JavaAddict/~4/1epUJRgzu5U" height="1" width="1"/&gt;</content><link rel="replies" type="application/atom+xml" href="http://dcsepely.blogspot.com/feeds/5144080500904171339/comments/default" title="Megjegyzések küldése" /><link rel="replies" type="text/html" href="http://www.blogger.com/comment.g?blogID=608056730343816089&amp;postID=5144080500904171339" title="0 megjegyzés" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/5144080500904171339?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/608056730343816089/posts/default/5144080500904171339?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/JavaAddict/~3/1epUJRgzu5U/testcase-debugolas-ala-surefire.html" title="TestCase debugolas ala SureFire" /><author><name>kack</name><uri>http://www.blogger.com/profile/07631438113608814496</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="32" src="http://bp2.blogger.com/_LChmsBOE-vc/SINDG4jG-_I/AAAAAAAAACI/NcauouwMRzc/S220/screen116.png" /></author><thr:total>0</thr:total><feedburner:origLink>http://dcsepely.blogspot.com/2008/08/testcase-debugolas-ala-surefire.html</feedburner:origLink></entry></feed>

