<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>HollyGhozi &#187; Java</title>
	<atom:link href="http://hollyghozi.com/index.php/category/java/feed/" rel="self" type="application/rss+xml" />
	<link>http://hollyghozi.com</link>
	<description>is another Javanese Indonesian fellow blog</description>
	<lastBuildDate>Sun, 18 Mar 2012 12:58:36 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>PowerHub JDBC Log</title>
		<link>http://hollyghozi.com/index.php/2009/09/powerhub-jdbc-log/</link>
		<comments>http://hollyghozi.com/index.php/2009/09/powerhub-jdbc-log/#comments</comments>
		<pubDate>Tue, 15 Sep 2009 07:13:09 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Landmark]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[PowerHub]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=194</guid>
		<description><![CDATA[I&#8217;m supporting CDS in Oil Company based in the Netherland. CDS is a suite of application, one of the application is PowerHub. If I face a problem, I&#8217;ve to debug the PowerHub. One of method is to use log4jdbc. What I do is: 1. Download the log4jdbc4-1.2alpha2.jar, and put into $PE_HOME/jars 2. Download from SL4J [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m supporting <a href="http://www.halliburton.com/public/landmark/contents/Data_Sheets/web/H05239.pdf">CDS</a> in Oil Company based in the Netherland. CDS is a suite of application, one of the application is PowerHub.<br />
If I face a problem, I&#8217;ve to debug the PowerHub. One of method is to use <a href="http://code.google.com/p/log4jdbc/">log4jdbc</a>.</p>
<p>What I do is:<br />
1. Download the <a href="http://log4jdbc.googlecode.com/files/log4jdbc4-1.2alpha2.jar">log4jdbc4-1.2alpha2.jar</a>, and put into $PE_HOME/jars<br />
2. Download from <a href="http://www.slf4j.org">SL4J</a>  the compress file: <a href="http://www.slf4j.org/dist/slf4j-1.5.8.tar.gz">slf4j-1.5.8.tar.gz</a>. Extract slf4j-api-1.5.8.jar and slf4j-simple-1.5.8.jar from the compress file, and put into $PE_HOME/jars<br />
3. Modify $PE_HOME/conf/pe_dic.props, remark the old value and change the line:<br />
<!--DEVFMTCODE--><pre class="devcodeblock" title="'dos'"><div class="devcodeoverflow"><ol><li>#pe_dic.Url=jdbc:oracle:thin:@myoraclemachine:1521:PHDIC</li><li>pe_dic.Url=jdbc:log4jdbc:oracle:thin:@myoraclemachine:1521:PHDIC</li><li>#pe_dic.Driver=oracle.jdbc.driver.OracleDriver</li><li>pe_dic.Driver=net.sf.log4jdbc.DriverSpy</li></ol></div></pre><!--END_DEVFMTCODE--><br />
4. Restart the PowerHub</p>
<p>You&#8217;ll need to check your $PE_HOME/logs/pe_dic-server.log, to see the additional jdbc log messages.<br />
Below is the snippet of the log file:<br />
<!--DEVFMTCODE--><pre class="devcodeblock" title="'dos'"><div class="devcodeoverflow"><ol><li>.........</li><li>11824 [main] INFO jdbc.audit - 1. Connection.isClosed() returned false</li><li>11824 [main] INFO jdbc.audit - 1. Statement.new Statement returned </li><li>11824 [main] INFO jdbc.audit - 1. Connection.createStatement() returned net.sf.log4jdbc.StatementSpy@2e67cd84</li><li>11824 [main] INFO jdbc.sqlonly - SELECT upper(d.DATASTORE_NAME),c.DATABASE_S,c.DATABASE_NAME,c.TYPE,c.DRIVER,c.URL,c.TWO_TASK,c.SEQ_NAME,c.CLASS_NAME,c.PRIVATE </li><li>FROM SLG_DATABASE c, SLG_DATASTORE d WHERE c.DATASTORE_S=d.DATASTORE_S ORDER BY d.DATASTORE_NAME,c.DATABASE_NAME </li><li></li><li>11833 [main] INFO jdbc.sqltiming - SELECT upper(d.DATASTORE_NAME),c.DATABASE_S,c.DATABASE_NAME,c.TYPE,c.DRIVER,c.URL,c.TWO_TASK,c.SEQ_NAME,c.CLASS_NAME,c.PRIVATE </li><li>FROM SLG_DATABASE c, SLG_DATASTORE d WHERE c.DATASTORE_S=d.DATASTORE_S ORDER BY d.DATASTORE_NAME,c.DATABASE_NAME </li><li> {executed in 9 msec}</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.new ResultSet returned </li><li>11833 [main] INFO jdbc.audit - 1. Statement.executeQuery(SELECT upper(d.DATASTORE_NAME),c.DATABASE_S,c.DATABASE_NAME,c.TYPE,c.DRIVER,c.URL,c.TWO_TASK,c.SEQ_NAME,c.CLASS_NAME,c.PRIVATE FROM SLG_DATABASE c, SLG_DATASTORE d WHERE c.DATASTORE_S=d.DATASTORE_S ORDER BY d.DATASTORE_NAME,c.DATABASE_NAME) returned net.sf.log4jdbc.ResultSetSpy@20e5ace9</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.next() returned true</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(1) returned AOI_SHAPEFILE</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(2) returned 1263</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(3) returned AOI_SHAPEFILE</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(4) returned shapefile</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(5) returned dummy</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(6) returned dummy</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(7) returned dummy</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(8) returned seq</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(9) returned null</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.getString(10) returned N</li><li>11833 [main] INFO jdbc.resultset - 1. ResultSet.next() returned true</li><li>.............</li></ol></div></pre><!--END_DEVFMTCODE--><br />
From the log file, you can see that the PowerHub tries to read the dictionary to get the databases information&#8230;</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/09/powerhub-jdbc-log/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Cannot find modules error when try to install</title>
		<link>http://hollyghozi.com/index.php/2009/08/cannot-find-modules-error-when-try-to-install/</link>
		<comments>http://hollyghozi.com/index.php/2009/08/cannot-find-modules-error-when-try-to-install/#comments</comments>
		<pubDate>Wed, 05 Aug 2009 13:33:47 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Landmark]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[PowerHub]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=189</guid>
		<description><![CDATA[We&#8217;re installing PowerHub using its installer in Linux machine. The installer is built using InstallAnyWhere, that use JRE inside the installer. The problem happen when we try to install as a user which its home directory is not mounted. We tried to set the HOME to other directory by setting up HOME environment variable. But, [...]]]></description>
			<content:encoded><![CDATA[<p>We&#8217;re installing PowerHub using its installer in Linux machine. The installer is built using InstallAnyWhere, that use JRE inside the installer. </p>
<p>The problem happen when we try to install as a user which its home directory is not mounted. We tried to set the HOME to other directory by setting up HOME environment variable. But, we got:<br />
<code>No module find error</code></p>
<p>Then we try to debug the installation by:<br />
<code>sh -x setup.bin</code><br />
It come back with a lot of debug messages, and at the end we will see a line with:<br />
<code>CLASSPATH=/tmp/install.829388/jar/...<br />
exec /tmp/install.829388/jre/bin/java ....</code></p>
<p>What we did is to manipulate the user home by<br />
<code>$export CLASSPATH=/tmp/install.829388/jar/...<br />
/tmp/install.829388/jre/bin/java -Duser.home=/tmp/tmpdir ... </code><br />
This way, we will force the installer to use different HOME directory</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/08/cannot-find-modules-error-when-try-to-install/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LD_ASSUME_KERNEL to set thread library that will be used by JVM</title>
		<link>http://hollyghozi.com/index.php/2009/07/ld_assume_kernel-to-set-thread-library-that-will-be-used-by-jvm/</link>
		<comments>http://hollyghozi.com/index.php/2009/07/ld_assume_kernel-to-set-thread-library-that-will-be-used-by-jvm/#comments</comments>
		<pubDate>Tue, 14 Jul 2009 16:16:48 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=181</guid>
		<description><![CDATA[My first aquintance with this environment variables when I was installing Oracle 9i. The notes that written by Werner Puschitz is my oracle installation guidance, back on my early days. Now, I&#8217;ve to deal with the same environment variable again. As a reminder to myself, the LD_ASSUME_KERNEL should be set as: # Set the LD_ASSUME_KERNEL [...]]]></description>
			<content:encoded><![CDATA[<p>My first aquintance with this environment variables when I was installing Oracle 9i. The notes that written by <a href="http://www.puschitz.com/InstallingOracle9i.shtml">Werner Puschitz</a> is my oracle installation guidance, back on my early days. Now, I&#8217;ve to deal with the same environment variable again.</p>
<p>As a reminder to myself, the LD_ASSUME_KERNEL should be set as:<br />
<code># Set the LD_ASSUME_KERNEL environment variable only for Red Hat 9,<br />
# RHEL AS 3, and RHEL AS 4 !!<br />
# Use the "Linuxthreads with floating stacks" implementation instead of NPTL:<br />
export LD_ASSUME_KERNEL=2.4.1    # for RH 9 and RHEL AS 3<br />
export LD_ASSUME_KERNEL=export LD_ASSUME_KERNEL=2.4.19   # for RHEL AS 4</code><br />
Honestly, I don&#8217;t know why we have to set differently between RH9 &#038; RHEL AS 3 vs RHEL AS 4. I&#8217;ll do it anyway.</p>
<p>As I read from the <a href="http://www.redhat.com/docs/manuals/enterprise/RHEL-3-Manual/release-notes/as-x86/">Red Hat Release Notes</a>, it says:<br />
<code>export LD_ASSUME_KERNEL=2.4.19 — Linuxthreads with floating stacks<br />
export LD_ASSUME_KERNEL=2.2.5 — Linuxthreads without floating stacks</code></p>
<p>Once we set the environment, we can check which thread library that active, we can use &#8216;getconf GNU_LIBPTHREAD_VERSION&#8217; command as follow:<br />
<code>bash-3.00$ unset LD_ASSUME_KERNEL<br />
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION<br />
NPTL 2.3.4<br />
bash-3.00$ export LD_ASSUME_KERNEL=2.4.1<br />
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION<br />
linuxthreads-0.10<br />
bash-3.00$ export LD_ASSUME_KERNEL=2.4.19<br />
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION<br />
linuxthreads-0.10<br />
bash-3.00$ export LD_ASSUME_KERNEL=2.5.2<br />
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION<br />
NPTL 2.3.4<br />
bash-3.00$ unset LD_ASSUME_KERNEL<br />
bash-3.00$ getconf GNU_LIBPTHREAD_VERSION<br />
NPTL 2.3.4</code></p>
<p>Information about NPTL can be found in <a href="http://en.wikipedia.org/wiki/LinuxThreads">wikipedia</a>.</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/07/ld_assume_kernel-to-set-thread-library-that-will-be-used-by-jvm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Java: SCJP certified me as Java-nese!</title>
		<link>http://hollyghozi.com/index.php/2009/07/java-scjp-certified-me-as-java-nese/</link>
		<comments>http://hollyghozi.com/index.php/2009/07/java-scjp-certified-me-as-java-nese/#comments</comments>
		<pubDate>Sun, 05 Jul 2009 16:05:04 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[certification]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=175</guid>
		<description><![CDATA[It&#8217;s been quite some time since I haven&#8217;t updated my blog. I need to prepare myself for my SCJP Exam Test. After months of studying, I finally passed the SJCP exam test. Now, with the Java Certification in my hand, I&#8217;m officially javanese that not only speak Java natively but also do Java programming! Yiihaa! [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been quite some time since I haven&#8217;t updated my blog. I need to prepare myself for my SCJP Exam Test. After months of studying, I finally passed the SJCP exam test. Now, with the Java Certification in my hand, I&#8217;m officially javanese that not only speak Java natively but also do Java programming! Yiihaa! <img src='http://hollyghozi.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>I&#8217;ve to confess that I don&#8217;t have enough experience in Java Programming nor enough time to study. And it&#8217;s completely different beast compare to my other certifications (<a href="https://www.redhat.com/training/certification/verify/?rhce_cert_display:certno=804006876122575&#038;rhce_cert_display:verify_cb=Verify">RHCE</a> and <a href="http://education.oracle.com/pls/web_prod-plq-dad/db_pages.getpage?page_id=151">OCP DBA</a>) that merely IT infrastructure exams. </p>
<p>What I&#8217;ve done to get the certification is:<br />
1. Learn about the <a href="http://www.sun.com/training/catalog/courses/CX-310-065.xml">SCJP </a>it self. I print the page, and nail it to my office wall. So I can read the it whenever I&#8217;m in office.<br />
2. Browse Amazon, try to find the best SCJP book available. Based on its reviews, I decided to buy <a href="http://amzn.com/0071591060">Katherine Sierra SCJP Book</a>. Because, I reside in The Netherlands, I ordered the book via <a href="http://www.bol.com/nl/index.html">bol.com</a>, and received the book within 3 days.<br />
3. Followed the book suggestion, I photo-copied the review part of each chapter. I read this when I&#8217;m on the tram on the way to and from office. I started to do this since October 2008.<br />
4. On January 2009, I read the book completely. Finally!<br />
5. But, my confident level still didn&#8217;t increase. Until, there&#8217;s information in the sun website that if we buy the voucher before June 2008, we&#8217;ll have a free retake exam. This boost my guts and also my learn.<br />
6. I bought the Voucher from <a href="https://www.suntrainingcatalogue.com/eduserv/client/loadCourse.do?coCourseCode=CX-310-065">Sun NL</a>. It cost 235 EUR + VAT.<br />
7. I go to <a href="http://2test.com">Prometric </a>website, to register the exam. I chose the nearest exam location, which is 500 meter away from my office.<br />
8. A day before the exam, I took a good night sleep. In the morning, I felt my self fresh, and went to exam location.<br />
9. It&#8217;s a long exam, 3.5 hours! I used this full long time to do the exam 9 passes, until I ran out of time. After click finish, it didn&#8217;t show my result on the computer screen. It&#8217;s different with my OCP, that show the result as soon as you click finish. I went to the admin, and she congratulated me that I passed the exam. I still couldn&#8217;t believe it! Alhamdulillah! </p>
<p>Now, since I&#8217;ve passed the exam. I feel lighter, seems that the whole burden that I&#8217;d carried over years has gone. I need to decide for my next goal. I would like to get back to academic things, but I still don&#8217;t know how to do it, any idea?</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/07/java-scjp-certified-me-as-java-nese/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PowerHub: Installation Error with &#8216;/tmp does not have enough disk space&#8217;</title>
		<link>http://hollyghozi.com/index.php/2009/05/powerhub-installation-error-with-tmp-does-not-have-enough-disk-space/</link>
		<comments>http://hollyghozi.com/index.php/2009/05/powerhub-installation-error-with-tmp-does-not-have-enough-disk-space/#comments</comments>
		<pubDate>Mon, 18 May 2009 12:20:14 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Landmark]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[PowerHub]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=173</guid>
		<description><![CDATA[When I&#8217;m installing PowerHub, I encounter the error message: WARNING: /tmp does not have enough disk space! Attempting to use /glb/home/s_peam01 for install base and tmp dir. Extracting the JRE from the installer archive... The included VM could not be extracted. Please try to download the installer again and make sure that you download using [...]]]></description>
			<content:encoded><![CDATA[<p>When I&#8217;m installing PowerHub, I encounter the error message:<br />
<code>WARNING: /tmp does not have enough disk space!<br />
         Attempting to use /glb/home/s_peam01 for install base and tmp dir.<br />
Extracting the JRE from the installer archive...<br />
The included VM could not be extracted. Please try to download<br />
the installer again and make sure that you download using 'binary'<br />
mode.  Please do not attempt to install this currently downloaded copy.</code></p>
<p>The work around is to set IATEMPDIR environment to location that has sufficient space<br />
<code>$ export IATEMPDIR=/glb/apps/3rdparty_test/tmp</code></p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/05/powerhub-installation-error-with-tmp-does-not-have-enough-disk-space/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>JAVA: Encrypt Your Password</title>
		<link>http://hollyghozi.com/index.php/2009/05/java-encrypt-your-password/</link>
		<comments>http://hollyghozi.com/index.php/2009/05/java-encrypt-your-password/#comments</comments>
		<pubDate>Mon, 18 May 2009 10:21:51 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=171</guid>
		<description><![CDATA[I&#8217;ve been dealing with some java application that connect to multiple databases. All the database information are stored in properties file. This includes the password as well. I stumbled upon the Cryptix. I&#8217;m able to encrypt and decrypt using several lines of code as follow: byte[] bytes = passwordString.getBytes(i); Security.addProvider(new Cryptix()); RawSecretKey key = null; [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been dealing with some java application that connect to multiple databases. All the database information are stored in properties file. This includes the password as well. I stumbled upon the <a href="http://www.cryptix.org/">Cryptix</a>.<br />
I&#8217;m able to encrypt and decrypt using several lines of code as follow:<br />
<code>byte[] bytes = passwordString.getBytes(i);<br />
Security.addProvider(new Cryptix());<br />
RawSecretKey key = null;<br />
key = new RawSecretKey("Blowfish","Holly's secret key to unlock".getBytes());<br />
Cipher cipher = Cipher.getInstance("Blowfish", "Cryptix");<br />
cipher = Cipher.getInstance(cipher, null , new PKCS7());<br />
cipher.initDecrypt(key);<br />
System.out.println(new String(cipher.crypt(bytes)));</code><br />
To learn more about Cryptix, you can read this <a href="http://www.ntua.gr/cryptix/old/cryptix/FAQ.html">FAQ</a>.</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/05/java-encrypt-your-password/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHJDBC: Temporary Remove the Java System Output</title>
		<link>http://hollyghozi.com/index.php/2009/05/phjdbc-temporary-remove-the-java-system-output/</link>
		<comments>http://hollyghozi.com/index.php/2009/05/phjdbc-temporary-remove-the-java-system-output/#comments</comments>
		<pubDate>Wed, 13 May 2009 07:52:19 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Landmark]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=154</guid>
		<description><![CDATA[When I execute SQL query using PowerHub JDBC driver, it always gives connection status. Connecting to //powerhubmachine/pe_dic-server Connected to ////powerhubmachine/pe_dic-server (PowerHub 20.0) To remove this output, I temporarily redirect the output to &#8216;null&#8217;, as shown in snippet below: private void connect() throws IOException { try { PrintStream oriOut = System.out; System.setOut(new PrintStream(new OutputStream(){public void write [...]]]></description>
			<content:encoded><![CDATA[<p>When I execute SQL query using PowerHub JDBC driver, it always gives connection status.<br />
<code>Connecting to //powerhubmachine/pe_dic-server<br />
Connected  to ////powerhubmachine/pe_dic-server (PowerHub 20.0)</code></p>
<p>To remove this output, I temporarily redirect the output to &#8216;null&#8217;, as shown in snippet below:<br />
<code> private void connect() throws IOException<br />
   {<br />
    	try {<br />
    		PrintStream oriOut = System.out;<br />
    		System.setOut(new PrintStream(new OutputStream(){public void write (int b){}}));<br />
			 Class.forName("com.lgc.dam.phs.client.jdbc.PhsJDBCDriver");<br />
			 if (connurl!=null) {<br />
	    		 conn = DriverManager.getConnection(connurl);<br />
			 } else {<br />
	    		 conn = DriverManager.getConnection("jdbc:scwapi://"+phserver+"/"+pedic+"-"+rmiserver+";"+username+";"+password+";SYSTEM;SYSTEM");<br />
			 }<br />
			 System.setOut(oriOut);<br />
		} catch (Exception e) {<br />
			System.out.println(e.toString());<br />
		}<br />
    }<br />
</code></p>
<p>Using the &#8216;setOut&#8217; to newly create empty OutputStream, it hides the output. After finish, &#8216;setOut&#8217; to original OuputStream.</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/05/phjdbc-temporary-remove-the-java-system-output/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Java: JConsole&#8217;s TopThreads Plugin</title>
		<link>http://hollyghozi.com/index.php/2009/04/java-jconsoles-topthreads-plugin/</link>
		<comments>http://hollyghozi.com/index.php/2009/04/java-jconsoles-topthreads-plugin/#comments</comments>
		<pubDate>Sun, 12 Apr 2009 04:40:23 +0000</pubDate>
		<dc:creator>hollyghozi</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Landmark]]></category>
		<category><![CDATA[PowerHub]]></category>

		<guid isPermaLink="false">http://hollyghozi.com/?p=135</guid>
		<description><![CDATA[While, I was googling to find a tool to monitor our Java RMI Server (PowerHub), I found this cool plugin. The TopThreads plugin. By using this plugin, it&#8217;s easier for us to monitor which plugin that have consume cpu power. We&#8217;re able to find the culprit thread. And by following the stack trace that produce [...]]]></description>
			<content:encoded><![CDATA[<p>While, I was googling to find a tool to monitor our Java RMI Server (PowerHub), I found this cool plugin. The <a title="TopThread, JConsol Plugin" href="http://blog.luminis.nl/roller/luminis/entry/top_threads_plugin_for_jconsole" target="_blank">TopThreads</a> plugin. By using this plugin, it&#8217;s easier for us to monitor which plugin that have consume cpu power.</p>
<p>We&#8217;re able to find the culprit thread. And by following the stack trace that produce by the thread, we&#8217;re able to find which user workflow that causing the thread gone wild.</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/04/java-jconsoles-topthreads-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PowerHub: Enable JConsole to monitor PowerHub</title>
		<link>http://hollyghozi.com/index.php/2009/03/powerhub-enable-jconsole-to-monitor-powerhub/</link>
		<comments>http://hollyghozi.com/index.php/2009/03/powerhub-enable-jconsole-to-monitor-powerhub/#comments</comments>
		<pubDate>Fri, 20 Mar 2009 11:28:50 +0000</pubDate>
		<dc:creator>Holly</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Landmark]]></category>
		<category><![CDATA[PowerHub]]></category>

		<guid isPermaLink="false">http://hollyghozi.wordpress.com/?p=119</guid>
		<description><![CDATA[JDK provide Java Monitoring and Management Console (JConsole) tool to provide information on performance and resource consumption of application running in Java platform using Java Management Extension (JMX) technology. To enable JMX in PowerHub add lines below to $PE_HOME/bin/runServer: -Dcom.sun.management.jmxremote \ -Dcom.sun.management.jmxremote.port=8024 \ -Dcom.sun.management.jmxremote.authenticate=true \ -Dcom.sun.management.jmxremote.ssl=false \ Notice: 1. JConsole is part of JDK default [...]]]></description>
			<content:encoded><![CDATA[<p>JDK provide Java Monitoring and Management Console (JConsole) tool to provide information on performance and resource consumption of application running in Java platform using Java Management Extension (JMX) technology.</p>
<div id="attachment_122" class="wp-caption aligncenter" style="width: 460px"><a href="http://hollyghozi.wordpress.com/2009/03/20/powerhub-enable-jconsole-to-monitor-powerhub/jconsole1/" rel="attachment wp-att-122"><img src="http://hollyghozi.files.wordpress.com/2009/03/jconsole1.jpg" alt="JConsole remotely monitors JMX-enable Java Apps" title="JConsole remotely monitors JMX-enable Java Apps" width="450" height="333" class="size-full wp-image-122" /></a>
<p class="wp-caption-text">JConsole remotely monitors JMX-enable Java Apps</p>
</div>
<p>To enable JMX in PowerHub add lines below to $PE_HOME/bin/runServer:<br />
<code>-Dcom.sun.management.jmxremote \<br />
-Dcom.sun.management.jmxremote.port=8024 \<br />
-Dcom.sun.management.jmxremote.authenticate=true \<br />
-Dcom.sun.management.jmxremote.ssl=false \</code></p>
<p>Notice:<br />
1. JConsole is part of JDK default installation<br />
2. “-Dcom.sun.management.jmxremote” is minimum parameter to enable JMX for local console. But this is not advisable.<br />
3. Remote connect of JConsole can be achieve by setting the other three parameters<br />
4. Remote connect use port. Each Java Application should be started with a separate port. e.g: 8001, 8002, 8003,…</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2009/03/powerhub-enable-jconsole-to-monitor-powerhub/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Eclipse: Security Manager for Eclipse</title>
		<link>http://hollyghozi.com/index.php/2008/06/eclipse-security-manager-for-eclipse/</link>
		<comments>http://hollyghozi.com/index.php/2008/06/eclipse-security-manager-for-eclipse/#comments</comments>
		<pubDate>Tue, 24 Jun 2008 21:16:00 +0000</pubDate>
		<dc:creator>Holly</dc:creator>
				<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://hollyghozi.wordpress.com/2008/06/24/eclipse-security-manager-for-eclipse/</guid>
		<description><![CDATA[Sometime you need to start RMI application inside your eclipse, to do this, you need to edit the eclipse.ini file -D -Djava.security.manager -Djava.security.policy="server.policy" Then create a file in eclipse directory security.conf with the following values: grant { permission java.security.AllPermission; }; And then start your eclipse This work is licensed under a Creative Commons Attribution 3.0 [...]]]></description>
			<content:encoded><![CDATA[<p>Sometime you need to start RMI application inside your eclipse, to do this, you need to edit the eclipse.ini file</p>
<p><code>-D -Djava.security.manager -Djava.security.policy="server.policy"</code></p>
<p>Then create a file in eclipse directory security.conf with the following values:<br />
<code>grant<br />
{<br />
permission java.security.AllPermission;<br />
};</code><br />
And then start your eclipse</p>
<div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div><div class='ez_cc_license_block'><a rel="license" href="http://creativecommons.org/licenses/by/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by/3.0/88x31.png"/></a><br/>This <span xmlns:dct="http://purl.org/dc/terms/" href="http://purl.org/dc/dcmitype/Text" rel="dct:type">work</span> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 Unported License</a>.</div>]]></content:encoded>
			<wfw:commentRss>http://hollyghozi.com/index.php/2008/06/eclipse-security-manager-for-eclipse/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

