<?xml version='1.0' encoding='UTF-8'?><rss xmlns:atom="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" version="2.0"><channel><atom:id>tag:blogger.com,1999:blog-15101094</atom:id><lastBuildDate>Sun, 01 Sep 2024 21:50:46 +0000</lastBuildDate><category>Tips and Tricks</category><category>Java</category><category>misc</category><category>MySQL</category><category>review</category><category>Tomcat</category><category>dirty trick</category><category>Firefox</category><category>Web 2.0</category><category>reading list</category><category>guide</category><category>web</category><category>Eclipse IDE</category><category>Javascript</category><category>game</category><category>idea</category><category>tool</category><category>ActiveMQ</category><category>Gant</category><category>Groovy</category><category>JQuery</category><category>JSP</category><category>Spring</category><category>philosophy</category><category>MariaDB</category><category>SVN</category><category>linux</category><category>sharing</category><title>Developer&#39;s Note</title><description>// shall I write some keywords here to boost search engine ranking?</description><link>http://thiamteck.blogspot.com/</link><managingEditor>noreply@blogger.com (Thiam Teck (1983 - ?))</managingEditor><generator>Blogger</generator><openSearch:totalResults>138</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-7487043844531470752</guid><pubDate>Sat, 15 Jan 2022 15:51:00 +0000</pubDate><atom:updated>2022-01-15T23:55:22.545+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">linux</category><category domain="http://www.blogger.com/atom/ns#">tool</category><title>Command to Compare Data Files: comm</title><description>&lt;p&gt;`diff` is great command to compare the changes among 2 versions of a file, but for comparing data file and extract data from it, `comm` command is more suitable for the job.&lt;/p&gt;&lt;p&gt;For demo purpose, we will prepare 2 sorted data file as below:&lt;/p&gt;

&lt;p&gt;left.txt:&lt;/p&gt;
&lt;pre&gt;

123
456
789
&lt;/pre&gt;

&lt;p&gt;right.txt:&lt;/p&gt;
&lt;pre&gt;

789
888
999
&lt;/pre&gt;

&lt;p&gt;`comm` command work by suppressing lines that exist in one of the file, or both file, where -1 suppress lines unique to the left file, -2 suppress lines unique to the right file, and -3 suppress lines appear in both files.&lt;/p&gt;&lt;p&gt;if no options being specify, it will display data in 3 columns:&lt;/p&gt;

&lt;pre&gt;&amp;gt; comm left.txt right.txt
123
456
                789
        888
        999
&lt;/pre&gt;

&lt;p&gt;To show only lines that unique to left file, we shall suppress the line unique to right file, and line that appear in both files:&lt;/p&gt;

&lt;pre&gt;&amp;gt; comm -23 left.txt right.txt
123
456
&lt;/pre&gt;

&lt;p&gt;For showing lines that only appear on the right, we will surpress line unique to the left file, and those appear in both files:&lt;/p&gt;
&lt;pre&gt;&amp;gt; comm -13 left.txt right.txt
888
999
&lt;/pre&gt;

&lt;p&gt;To extract lines that appear in both files, just suppress line that unique to left and right file:
&lt;/p&gt;&lt;pre&gt;&amp;gt; comm -12 left.txt right.txt
789
&lt;/pre&gt;

&lt;p&gt;And to exlcude only line that appear on the left, command below will show data in 2 column, one of it is the line commons for both files:&lt;/p&gt;
&lt;pre&gt;&amp;gt; comm -1 left.txt right.txt
        789
888
999
&lt;/pre&gt;

&lt;p&gt;We believe by now you shall be able to use `comm` command for comparing data file effectively. Thanks for reading.&lt;/p&gt; &lt;p&gt;&lt;/p&gt;</description><link>http://thiamteck.blogspot.com/2022/01/command-to-compare-data-files-comm.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-2387757220723306248</guid><pubDate>Mon, 09 Aug 2021 13:53:00 +0000</pubDate><atom:updated>2021-08-09T21:54:27.747+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">MariaDB</category><category domain="http://www.blogger.com/atom/ns#">MySQL</category><title>Linux Scripts to Create Table Partition for Next Month Automatically</title><description>&lt;p&gt;&amp;nbsp;In this article we are going to show you a method of create new monthly partition for MySQL table without stored procedure, with the REORGANIZE PARTITION from MySQL/MariaDB.&lt;/p&gt;&lt;p&gt;(Click &lt;a href=&quot;https://gist.github.com/thiamteck/5b0ab48fe25b019e7520de8c06f80b15&quot; target=&quot;_blank&quot;&gt;here&lt;/a&gt; to skip the article and straight to the scripts.)&lt;/p&gt;&lt;p&gt;For demo purpose, below are the DML of the table to be partitioned, and the ALTER statement to start with 2 partitions: &quot;p_old&quot; and &quot;p_future&quot;. Please change the p_old partition date to the first of next month.&lt;/p&gt;

&lt;script src=&quot;https://gist.github.com/thiamteck/5b0ab48fe25b019e7520de8c06f80b15.js?file=DML_partition.sql&quot;&gt;&lt;/script&gt;

&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Below is the template of ALTER statement to REORGANIZE PARTITION &quot;p_future&quot; into a partition of next month (&#39;p_202109&#39; for example, as of writing), and &#39;p_future&#39; for records after next month.&lt;/p&gt;

&lt;script src=&quot;https://gist.github.com/thiamteck/5b0ab48fe25b019e7520de8c06f80b15.js?file=partition_template.txt&quot;&gt;&lt;/script&gt;

&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;And here is the shell script that did some simple string substitute based on the template, and execute it on your MySQL/MariaDB server. Please do not forget to change the username, password and database name to match you database server.&lt;/p&gt;

&lt;script src=&quot;https://gist.github.com/thiamteck/5b0ab48fe25b019e7520de8c06f80b15.js?file=create_partition.sh&quot;&gt;&lt;/script&gt;

&lt;p&gt;&lt;br /&gt;&lt;/p&gt;&lt;p&gt;Finally, you may run this each month to create a new partition for next month with command:&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;blockquote&gt;./create_partition.sh&lt;/blockquote&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;If you are to schedule it via crontab, ensure you modify the script to use full path for the template file.&lt;/p&gt;&lt;p&gt;Thank you.&lt;/p&gt;</description><link>http://thiamteck.blogspot.com/2021/08/linux-scripts-to-create-partition-for.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-3495849579567625772</guid><pubDate>Sun, 25 Aug 2019 16:41:00 +0000</pubDate><atom:updated>2019-08-26T00:41:00.686+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">sharing</category><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Offload your SSD (on Windows) and SD Card (on Linux)</title><description>As many of us aware, both SSD and SD Card wearing out upon write operation. So to extend life span of the storage, we may look into reduce the write operation.&lt;br /&gt;
&lt;br /&gt;
(With wear leveling, most modern SSD have lifespan that is long enough where you might want to skip this post. But no harm to know something new, right ?)&lt;br /&gt;
&lt;br /&gt;For SSD, you may consider putting the Windows&#39;s TEMP folder into a RAM disk. RAM disk, as the name implies, it is a virtual drive that reserve and utilise the space on your RAM. There are many RAM disk software out there, and I&#39;m using &lt;a href=&quot;https://sourceforge.net/projects/imdisk-toolkit/&quot; target=&quot;_blank&quot;&gt;ImDisk&#39;s&lt;/a&gt; RamDisk Configuration.&lt;br /&gt;
&lt;br /&gt;
You can define the space of the RAM disk, and set the TEMP folders to the RAM Disk with this tool:&lt;br /&gt;
&lt;br /&gt;
&lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLrYHfICM8lSCDanqDWcCkMqSUlwDpO4NQAfaDrsSTVeddZQvcVd7bfzO8euw5ILbg2aLY_hNmSbS4jH-bqWeX0FCCyVdYYiJakcGqJz_q1Ex1R8nMSl9FD2ECooqU48EE5AjBAQ/s1600/ImDisk.PNG&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;490&quot; data-original-width=&quot;804&quot; height=&quot;195&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLrYHfICM8lSCDanqDWcCkMqSUlwDpO4NQAfaDrsSTVeddZQvcVd7bfzO8euw5ILbg2aLY_hNmSbS4jH-bqWeX0FCCyVdYYiJakcGqJz_q1Ex1R8nMSl9FD2ECooqU48EE5AjBAQ/s320/ImDisk.PNG&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;(ImDisk RamDisk Configuration)&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;br /&gt;
&lt;br /&gt;
For SD Card that store your OS (i.e. Raspberry Pi), we will put the `/var/log` on RAM with &lt;a href=&quot;https://github.com/azlux/log2ram&quot; target=&quot;_blank&quot;&gt;log2ram&lt;/a&gt;. This will make the logs stay in RAM and only flush to storage once a day by default (configurable).&lt;br /&gt;
&lt;br /&gt;
After done installation and reboot your Raspberry Pi, you shall see the screen below:&lt;br /&gt;
&lt;br /&gt;
&lt;table align=&quot;center&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot; class=&quot;tr-caption-container&quot; style=&quot;margin-left: auto; margin-right: auto; text-align: center;&quot;&gt;&lt;tbody&gt;
&lt;tr&gt;&lt;td style=&quot;text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjX5kzjDKoY_NMYmIw-ZKnOIc9Pk0t_MqgC6bOWPkCHw-dCLVxEzMyffAjLkrqBEOmu92oNTIvcCPmyAxe4RL3Bl81iXT9uXgsdfYTPZ2-GHX0-WQHNm8ttcAtiqF7XDTV13unNmA/s1600/log2ram.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: auto; margin-right: auto;&quot;&gt;&lt;img border=&quot;0&quot; data-original-height=&quot;179&quot; data-original-width=&quot;449&quot; height=&quot;127&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjX5kzjDKoY_NMYmIw-ZKnOIc9Pk0t_MqgC6bOWPkCHw-dCLVxEzMyffAjLkrqBEOmu92oNTIvcCPmyAxe4RL3Bl81iXT9uXgsdfYTPZ2-GHX0-WQHNm8ttcAtiqF7XDTV13unNmA/s320/log2ram.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;tr-caption&quot; style=&quot;text-align: center;&quot;&gt;(log2ram: new mounting point after installation and restart)&lt;/td&gt;&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
This shall extend the lifespan of your SD Card.&lt;br /&gt;
&lt;br /&gt;
Thanks for reading.</description><link>http://thiamteck.blogspot.com/2019/08/offload-your-ssd-on-windows-and-sd-card.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEiLrYHfICM8lSCDanqDWcCkMqSUlwDpO4NQAfaDrsSTVeddZQvcVd7bfzO8euw5ILbg2aLY_hNmSbS4jH-bqWeX0FCCyVdYYiJakcGqJz_q1Ex1R8nMSl9FD2ECooqU48EE5AjBAQ/s72-c/ImDisk.PNG" height="72" width="72"/><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-1658673515230457841</guid><pubDate>Fri, 16 Aug 2019 15:32:00 +0000</pubDate><atom:updated>2019-08-16T23:32:37.054+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">guide</category><title>Get 30GB of Samba Storage on Cloud</title><description>OK, it is less than 30GB to be exact, as the OS took some space too.&lt;br /&gt;
&lt;br /&gt;
The whole idea started from the offer from Google Cloud with an &quot;&lt;a href=&quot;https://cloud.google.com/free/docs/gcp-free-tier&quot; target=&quot;_blank&quot;&gt;always free&lt;/a&gt;&quot; plan which include 1 f1-micro instance with 30GB standard persistent storage. (Anyway, you might still get charge for egress too)&lt;br /&gt;
&lt;br /&gt;
So if you already have some running VPS or cloud instance, you may just use that too.&lt;br /&gt;
&lt;br /&gt;
However, as you might experienced, most cloud provider have strong focus on network security. And the steps to define firewall rules, etc are different among providers. &lt;br /&gt;
&lt;br /&gt;
Fortunately,&amp;nbsp;&lt;a href=&quot;https://www.zerotier.com/&quot; target=&quot;_blank&quot;&gt;ZeroTier &lt;/a&gt;come into rescue. We can use ZeroTier to link our home PC with the cloud instance just like there are in the same LAN (or Global Area Network, as advertise by ZeroTier).&lt;br /&gt;
&lt;br /&gt;
So here go the list of guide that I had followed, hope you enjoy it:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;https://medium.com/@hbmy289/how-to-set-up-a-free-micro-vps-on-google-cloud-platform-bddee893ac09&quot; target=&quot;_blank&quot;&gt;How to set up a free micro VPS on Google Cloud Platform&lt;/a&gt;&amp;nbsp;(I had choose Centos 7 as the OS, just personal preference)&lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;https://www.digitalocean.com/community/tutorials/getting-started-software-defined-networking-creating-vpn-zerotier-one&quot; target=&quot;_blank&quot;&gt;Getting Started with Software-Defined Networking and Creating a VPN with ZeroTier One&lt;/a&gt;&amp;nbsp;(I skip the VPN related steps)&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;Install the ZeroTier client on you home PC and join the same ZeroTier network (I did not read any guide for this, ZeroTier client for Windows is simple enough to install)&lt;/li&gt;
&lt;/ul&gt;
&lt;li&gt;&lt;a href=&quot;https://www.tecmint.com/install-samba4-on-centos-7-for-file-sharing-on-windows/&quot; target=&quot;_blank&quot;&gt;How to Install Samba4 on CentOS 7 for File Sharing on Windows&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;br /&gt;
Additional Ideas:&lt;br /&gt;
&lt;br /&gt;
&lt;ul&gt;
&lt;li&gt;If you are have Windows 10 Pro at home, you may also consider to use NFS too.&lt;/li&gt;
&lt;li&gt;You may experiment on mount object storage to the VM via FUSE for additional storage. (Do share with me the result and experience)&lt;/li&gt;
&lt;/ul&gt;
</description><link>http://thiamteck.blogspot.com/2019/08/get-30gb-of-samba-storage-on-cloud.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-8641637080946299096</guid><pubDate>Wed, 29 Apr 2015 14:53:00 +0000</pubDate><atom:updated>2015-04-29T22:53:24.008+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Chrome unable to load Google sites</title><description>Recently I had been facing problem loading Google sites such as its search engine, Gmail, Youtube, etc.&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
It is either take extra ordinary long time to load, or just failed with `ERR_QUIC_PROTOCOL_ERROR`.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
I did a search and found I am not alone, and below are the solution [1]:&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;ol&gt;
&lt;li&gt;Open a new tab in Chrome, and type `chrome://flags/` into address bar, then press Enter.&lt;/li&gt;
&lt;li&gt;Search for `Experimental&amp;nbsp;QUIC protocol`&lt;/li&gt;
&lt;li&gt;Disable it.&lt;/li&gt;
&lt;li&gt;Restart Chrome. Done.&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
&lt;div&gt;
It had been about a week, and the error never happen again.&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
[1]:&amp;nbsp;https://productforums.google.com/forum/#!topic/chrome/xKFfhDvhjU8&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
&lt;div&gt;
&lt;br /&gt;&lt;/div&gt;
</description><link>http://thiamteck.blogspot.com/2015/04/chrome-unable-to-load-google-sites.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-3491661361031578533</guid><pubDate>Sat, 05 Oct 2013 05:51:00 +0000</pubDate><atom:updated>2013-10-05T13:51:18.881+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Set Transfer Encoding of Attachment for Axis2 </title><description>When sending SOAP request with attachment, Axis2 handle the attachment via Axiom, and the default transfer encoding for binary file are binary.&lt;br /&gt;
&lt;br /&gt;
In order to change the transfer encoding to something else, we will utilize the&amp;nbsp;&lt;a href=&quot;http://org.apache.axiom.attachments.configurabledatahandler/&quot;&gt;org.apache.axiom.attachments.ConfigurableDataHandler&lt;/a&gt; instead of the usual javax.activation.DataHandler.&lt;br /&gt;
&lt;br /&gt;
Below is the sample code:
&lt;br /&gt;
&lt;script src=&quot;https://gist.github.com/thiamteck/6837132.js&quot;&gt;&lt;/script&gt;
</description><link>http://thiamteck.blogspot.com/2013/10/set-transfer-encoding-of-attachment-for.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-1020070879511355436</guid><pubDate>Tue, 12 Jun 2012 16:36:00 +0000</pubDate><atom:updated>2012-06-14T11:53:53.827+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Axis2 + Rampart: Generate Nonce and Created when Plain Text Password was Used</title><description>Axis2 support WS-Security via Apache Rampart module. I had develop the SOAP client based on tutorial : &lt;a href=&quot;http://wso2.org/library/240&quot;&gt;UsernameToken Authentication with Rampart&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
However, the default implementation of Apache Rampart will not generate Nonce when plain text password was used.&lt;br /&gt;
&lt;br /&gt;
After some google, I found &lt;a href=&quot;http://mail-archives.apache.org/mod_mbox/ws-rampart-dev/200709.mbox/%3C46EFB0E6.8070907@apache.org%3E&quot;&gt;this page&lt;/a&gt; talk about a configuration called &quot;&lt;span style=&quot;background-color: white; white-space: pre-wrap;&quot;&gt;addUTElements&lt;/span&gt;&quot;.&lt;br /&gt;
&lt;br /&gt;
So below are the modified configuration fragment:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&quot;https://gist.github.com/2918567.js?file=gistfile1.xml&quot;&gt;
&lt;/script&gt;</description><link>http://thiamteck.blogspot.com/2012/06/axis2-rampart-generate-nonce-and.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-1233577900967143536</guid><pubDate>Sat, 07 Apr 2012 03:18:00 +0000</pubDate><atom:updated>2012-04-07T11:18:50.326+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">MySQL</category><title>MySQL Random Words Based on Lorem Ipsum Text</title><description>Below is a MySQL function that create random text based on 100 words from Lorem Ipsum text.&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&quot;https://gist.github.com/2324779.js?file=gistfile1.sql&quot;&gt;&lt;/script&gt;</description><link>http://thiamteck.blogspot.com/2012/04/mysql-random-words-based-on-lorem-ipsum.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-2587853689066736754</guid><pubDate>Fri, 04 Nov 2011 18:09:00 +0000</pubDate><atom:updated>2011-11-05T02:21:39.747+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Revert to the old Google Reader? Let&#39;s enhance the new one</title><description>IMHO, The redesign of Google Reader to integrate with Google+ do not impress me.&lt;br /&gt;
&lt;br /&gt;
I am agree with &lt;a href=&quot;http://techcrunch.com/2011/11/02/ex-google-reader-product-manager-posts-scathing-review-of-reader-redesign/&quot;&gt;the review of ex-Product Manager of Google Reader&lt;/a&gt;. The space allocated for reading is just too small, and I personally like the light blue theme than the current grey scale page.&lt;br /&gt;
&lt;br /&gt;
I failed to google any workable way to restore the old Google look and feel. However, I found the ways to enhance the Google Reader (for Firefox).&lt;br /&gt;
&lt;br /&gt;
Below is the original new Google Reader look and feel:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjpqnq4WI7lhXvWBV93prsLkPv66GE15t2PTN2AQjcGQcAdmztrr0v8tO_UYtz9-sWnwUaXY5DfwMWFdxNSlxTkSzaPskPxJx_amhbyCx08IAmAahbKSriwgfCd0LxYMs_rE7biA/s1600/original.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;122&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjpqnq4WI7lhXvWBV93prsLkPv66GE15t2PTN2AQjcGQcAdmztrr0v8tO_UYtz9-sWnwUaXY5DfwMWFdxNSlxTkSzaPskPxJx_amhbyCx08IAmAahbKSriwgfCd0LxYMs_rE7biA/s320/original.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
Below is the modified look and feel:&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj48Hpp-Lj2l7Qm2ZR2iV2jRWaIJrVO20EVPvzDdVZ1YxSQ5ii2DnsfhzF5p7R0SSAVWnvXv1NXQW9m-u15z_gP9GSsM0la_N-tV_KCFV4KrSfiMN-X4SBrdYL2mAIiTpNLpGC3YA/s1600/modified.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;122&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj48Hpp-Lj2l7Qm2ZR2iV2jRWaIJrVO20EVPvzDdVZ1YxSQ5ii2DnsfhzF5p7R0SSAVWnvXv1NXQW9m-u15z_gP9GSsM0la_N-tV_KCFV4KrSfiMN-X4SBrdYL2mAIiTpNLpGC3YA/s320/modified.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;&lt;br /&gt;
Below are the steps:&lt;br /&gt;
1. Install &lt;a href=&quot;https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/&quot;&gt;Greasemonkey&lt;/a&gt; plugin&lt;br /&gt;
2. Install script &lt;a href=&quot;http://userscripts.org/scripts/show/116888&quot;&gt;&quot;Google Reader - Compact Design&quot;&lt;/a&gt; (this script make interface more compact thus give you more space to read)&lt;br /&gt;
3. Install &lt;a href=&quot;https://addons.mozilla.org/en-US/firefox/addon/stylish/&quot;&gt;Stylish&lt;/a&gt; plugin&lt;br /&gt;
4. Install user style &lt;a href=&quot;http://userstyles.org/styles/12640/google-reader-revert&quot;&gt;&quot;Google Reader Revert&quot;&lt;/a&gt; (to get back the light blue theme)&lt;br /&gt;
&lt;br /&gt;
So far this 2 scripts do not conflict with each other. Feel free to try.</description><link>http://thiamteck.blogspot.com/2011/11/revert-to-old-google-reader-lets.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhjpqnq4WI7lhXvWBV93prsLkPv66GE15t2PTN2AQjcGQcAdmztrr0v8tO_UYtz9-sWnwUaXY5DfwMWFdxNSlxTkSzaPskPxJx_amhbyCx08IAmAahbKSriwgfCd0LxYMs_rE7biA/s72-c/original.png" height="72" width="72"/><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-2120338346045801344</guid><pubDate>Sat, 19 Mar 2011 06:27:00 +0000</pubDate><atom:updated>2011-03-19T14:27:09.117+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">JQuery</category><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>JQuery UI: Datepicker with Month and Year only</title><description>This can be done by hiding the calendar via some CSS trick:&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&quot;https://gist.github.com/877276.js&quot;&gt; &lt;/script&gt;</description><link>http://thiamteck.blogspot.com/2011/03/jquery-ui-datepicker-with-month-and.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>4</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-4625228805405653282</guid><pubDate>Sat, 19 Feb 2011 06:20:00 +0000</pubDate><atom:updated>2011-02-19T14:20:55.024+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Javascript</category><category domain="http://www.blogger.com/atom/ns#">JQuery</category><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>JQuery UI: eliminate &quot;stop running this script?&quot; warning in IE</title><description>In IE, when the Javascript on the page take too long duration to execute, the browser will popup a warning of &quot;Stop running this scripts?&quot;&lt;br /&gt;
&lt;br /&gt;
In order to eliminate the warning, we need to hint the browser that the script is not infinitely running, by having some pause via Javascript setTimeout method.&lt;br /&gt;
&lt;br /&gt;
However, for Javascript framework such as JQuery that use selector and method chaining extensively, Just setTimeout alone will not help much.&lt;br /&gt;
&lt;br /&gt;
We will need to slice the elements list from selector into few smaller batches, before chain it to the next method.&lt;br /&gt;
&lt;br /&gt;
Below is the sample code snippet:&lt;br /&gt;
&lt;br /&gt;
&lt;script src=&quot;https://gist.github.com/834867.js?file=gistfile1.js&quot;&gt;&lt;/script&gt;&lt;br /&gt;
&lt;br /&gt;
Feel free to share if you have a more elegant approach to this problem. :)</description><link>http://thiamteck.blogspot.com/2011/02/jquery-ui-eliminate-stop-running-this.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-5905014300099518012</guid><pubDate>Sat, 27 Nov 2010 14:18:00 +0000</pubDate><atom:updated>2010-11-27T22:18:08.926+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">tool</category><title>Introducing feed2PDF</title><description>As the name implied, &lt;a href=&quot;http://feed2pdf.appspot.com/&quot;&gt;feed2PDF&lt;/a&gt; is an application that convert ATOM/RSS feed into PDF files. It is built on top of &lt;a href=&quot;http://joliprint.com/&quot;&gt;Joliprint&lt;/a&gt;, with enhancement of merging PDF generated from each feed item into 1 PDF file.&lt;br /&gt;
&lt;br /&gt;
Hope you found this useful.</description><link>http://thiamteck.blogspot.com/2010/11/introducing-feed2pdf.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-8425650382516176279</guid><pubDate>Sun, 08 Aug 2010 04:57:00 +0000</pubDate><atom:updated>2010-08-08T12:57:35.833+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Split String with Empty Trailling Tokens in Java</title><description>The &quot;-1&quot; do the tricks:&lt;br /&gt;
&lt;br /&gt;
&lt;blockquote&gt;String[] stringTokens= dataString.split(&quot;,&quot;, -1);&lt;/blockquote&gt;</description><link>http://thiamteck.blogspot.com/2010/08/split-string-with-empty-trailling.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-1570318018677950917</guid><pubDate>Sun, 25 Apr 2010 06:47:00 +0000</pubDate><atom:updated>2010-04-25T14:47:32.423+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Groovy</category><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Print Directory Tree with Groovy (with closure recursion)</title><description>While looking for a script that display directory tree, I came across this &lt;a href=&quot;http://groovy-almanac.org/directory-contents-as-ascii-tree/&quot;&gt;Groovy script&lt;/a&gt;.&lt;br /&gt;
&lt;br /&gt;
The code look just fine but it don&#39;t work (I test it with Groovy 1.7). After some google, I found that this is due to the closure as a first class object in Groovy, it can&#39;t be call within the closure itself.&lt;br /&gt;
&lt;br /&gt;
And below is the solution:&lt;br /&gt;
&lt;br /&gt;
&lt;pre name=&quot;code&quot; class=&quot;java:nogutter&quot;&gt;def listRecursivly

listRecursivly = { file, arg -&amp;gt;
    println &quot;${&#39;|  &#39; * arg}`- ${file.getName()}\\&quot;
    file.eachFile() {f -&amp;gt;
        if(f.directory) {
            listRecursivly(f,(arg + 1))
        } else {
            println &quot;${&#39;|  &#39; * (arg + 1)}`- ${f.getName()}&quot;
        }
    }
}

listRecursivly (new File(&quot;.&quot;),0)
&lt;/pre&gt;&lt;br /&gt;
The little trick here is to define and initialize the closure in 2 separate lines.&lt;br /&gt;
&lt;br /&gt;
&lt;div style=&quot;margin-top: 10px; height: 15px;&quot; class=&quot;zemanta-pixie&quot;&gt;&lt;a class=&quot;zemanta-pixie-a&quot; href=&quot;http://reblog.zemanta.com/zemified/63106ce6-8a28-4ad0-9616-fcfb3e859071/&quot; title=&quot;Reblog this post [with Zemanta]&quot;&gt;&lt;img style=&quot;border: medium none; float: right;&quot; class=&quot;zemanta-pixie-img&quot; src=&quot;http://img.zemanta.com/reblog_e.png?x-id=63106ce6-8a28-4ad0-9616-fcfb3e859071&quot; alt=&quot;Reblog this post [with Zemanta]&quot;&gt;&lt;/a&gt;&lt;span class=&quot;zem-script more-related pretty-attribution&quot;&gt;&lt;script type=&quot;text/javascript&quot; src=&quot;http://static.zemanta.com/readside/loader.js&quot; defer=&quot;defer&quot;&gt;&lt;/script&gt;&lt;/span&gt;&lt;/div&gt;</description><link>http://thiamteck.blogspot.com/2010/04/print-directory-tree-with-groovy-with.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-5632434062224116389</guid><pubDate>Fri, 15 Jan 2010 13:53:00 +0000</pubDate><atom:updated>2010-01-15T21:53:00.404+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Scan File with AVG 8.5 in Windows Live Messenger</title><description>It is a bit tricky:&lt;br /&gt;&lt;br /&gt;1. Create a batch file (said ScanAVG.bat) in your AVG installation directory:&lt;br /&gt;2. Edit the batch file:&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;js:nogutter&quot;&gt;&lt;br /&gt;@echo off&lt;br /&gt;&quot;C:\Program Files\AVG\AVG8\avgscanx.exe&quot; /SCAN=%1 /HEUR /ARC /PUP /CLEAN&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;3. In Live Messenger, Tools &gt; Options &gt; File Transfer&lt;br /&gt;4. Check &quot;Scan files for viruses using:&quot;&lt;br /&gt;5. Fill in the path to your batch file. (i.e. &quot;C:\Program Files\AVG\AVG8\ScanAVG.bat&quot;)&lt;br /&gt;&lt;br /&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhsaIOGvOtJNp1EyPzMOSuv8NFpbaoMIkW4_a-EyoT1yRkVpfFDzJ8fGg4nVIYCB6KTI7IA3gRqnc-Px2R10bd7HXoAfXh90cxow_kXnA6eEb2ppNNMUxrj2sQw316dElyj45wJmg/s1600-h/msn_avg.JPG&quot;&gt;&lt;img style=&quot;display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 277px; height: 320px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhsaIOGvOtJNp1EyPzMOSuv8NFpbaoMIkW4_a-EyoT1yRkVpfFDzJ8fGg4nVIYCB6KTI7IA3gRqnc-Px2R10bd7HXoAfXh90cxow_kXnA6eEb2ppNNMUxrj2sQw316dElyj45wJmg/s320/msn_avg.JPG&quot; border=&quot;0&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5425485234807416978&quot; /&gt;&lt;/a&gt;&lt;br /&gt;Reference: http://forums.techguy.org/general-security/707127-solved-avg-8-free-windows-2.html</description><link>http://thiamteck.blogspot.com/2010/01/scan-file-with-avg-85-in-windows-live.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhsaIOGvOtJNp1EyPzMOSuv8NFpbaoMIkW4_a-EyoT1yRkVpfFDzJ8fGg4nVIYCB6KTI7IA3gRqnc-Px2R10bd7HXoAfXh90cxow_kXnA6eEb2ppNNMUxrj2sQw316dElyj45wJmg/s72-c/msn_avg.JPG" height="72" width="72"/><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-4656314699322707617</guid><pubDate>Sat, 09 Jan 2010 01:26:00 +0000</pubDate><atom:updated>2010-02-25T22:03:43.490+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">ActiveMQ</category><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Send Message to ActiveMQ via WGET</title><description>In &lt;a class=&quot;zem_slink&quot; href=&quot;http://activemq.apache.org&quot; title=&quot;Apache ActiveMQ&quot; rel=&quot;homepage&quot;&gt;ActiveMQ&lt;/a&gt; website, it does show &lt;a href=&quot;http://activemq.apache.org/rest.html&quot;&gt;the steps of consuming message from ActiveMQ via WGET&lt;/a&gt;.&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;In order to produce message and send into ActiveMQ queue, here is the command:&lt;/div&gt;&lt;div&gt;&lt;blockquote&gt;wget --post-file=message.txt http://localhost:8161/demo/message/MyQueue?type=queue&lt;/blockquote&gt;&lt;/div&gt;&lt;div&gt;&lt;br /&gt;&lt;/div&gt;&lt;div&gt;Where the message.txt is something like this:&lt;/div&gt;&lt;div&gt;&lt;blockquote&gt;body=the test message you would like to submit.&lt;/blockquote&gt;&lt;/div&gt;  &lt;div style=&quot;margin-top: 10px; height: 15px;&quot; class=&quot;zemanta-pixie&quot;&gt;&lt;a class=&quot;zemanta-pixie-a&quot; href=&quot;http://reblog.zemanta.com/zemified/4aaf83cd-c8be-4b3e-a8dd-d5811026e7ec/&quot; title=&quot;Reblog this post [with Zemanta]&quot;&gt;&lt;img style=&quot;border: medium none; float: right;&quot; class=&quot;zemanta-pixie-img&quot; src=&quot;http://img.zemanta.com/reblog_e.png?x-id=4aaf83cd-c8be-4b3e-a8dd-d5811026e7ec&quot; alt=&quot;Reblog this post [with Zemanta]&quot; /&gt;&lt;/a&gt;&lt;span class=&quot;zem-script more-related pretty-attribution&quot;&gt;&lt;script type=&quot;text/javascript&quot; src=&quot;http://static.zemanta.com/readside/loader.js&quot; defer=&quot;defer&quot;&gt;&lt;/script&gt;&lt;/span&gt;&lt;/div&gt;</description><link>http://thiamteck.blogspot.com/2010/01/send-message-to-activemq-via-wget.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-2523506969703459664</guid><pubDate>Mon, 23 Nov 2009 14:28:00 +0000</pubDate><atom:updated>2009-11-23T22:50:57.356+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Gant</category><title>Gant: OutOfMemoryError</title><description>Today just hit an OutOfMemoryError when using &lt;a href=&quot;http://gant.codehaus.org/&quot;&gt;Gant&lt;/a&gt; build script to compile my code.&lt;br /&gt;&lt;br /&gt;Google for way to set heap size for Gant, but in the end found the solution by set it in JAVA_OPTS.&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;sql:nogutter&quot;&gt;set JAVA_OPTS=&quot;-Xmx512M&quot;&lt;/pre&gt;</description><link>http://thiamteck.blogspot.com/2009/11/gant-outofmemoryerror.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-2032684276535071741</guid><pubDate>Mon, 07 Sep 2009 01:47:00 +0000</pubDate><atom:updated>2009-09-07T09:55:39.595+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><category domain="http://www.blogger.com/atom/ns#">Tomcat</category><title>Redirect Tomcat console output to log file</title><description>We know using proper logging library instead of System.out is important. But when there are a legacy application that still using the System.out and System.err, it will be good to be able to pipe it into file for troubleshooting.&lt;br /&gt;&lt;br /&gt;The solution is set the swallowOutput=&quot;true&quot; in Tomcat context of your webapp. Then this will pipe the stdout and stderr into the logger configured in the same context.</description><link>http://thiamteck.blogspot.com/2009/09/redirect-tomcat-console-output-to-log.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-4468626766006951858</guid><pubDate>Mon, 15 Jun 2009 14:48:00 +0000</pubDate><atom:updated>2009-06-15T23:20:51.512+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">MySQL</category><title>ERROR 1 (HY000) at line 1: Can&#39;t create/write to file</title><description>MySQL SELECT statement allowed us to pipe the query result in to a file via SELECT ... INTO OUTFILE. It work just fine for me most of the time, until recently I hit this error:&lt;br /&gt;&lt;blockquote&gt;ERROR 1 (HY000) at line 1: Can&#39;t create/write to file &#39;\home\myuser\my_output_file.txt&#39; (Errcode: 2) mv: cannot stat `/home/myuser/my_output_file.txt&#39;: No such file or directory &lt;/blockquote&gt;The first thing come to my mind is the problem of file permission, so I grant 777 permission to my output directory. But the problem still exist.&lt;br /&gt;&lt;br /&gt;Then I check the Mysql username I use, and found that it was granted with FILE permission correctly.&lt;br /&gt;&lt;br /&gt;Then I start to google on this error code, and most of the search result point to similars causes.&lt;br /&gt;&lt;br /&gt;So I read again the &lt;a href=&quot;http://dev.mysql.com/doc/refman/5.0/en/select.html&quot;&gt;documentation of MySQL&lt;/a&gt;, and I found this:&lt;br /&gt;&lt;blockquote&gt;The SELECT ... INTO OUTFILE &#39;file_name&#39; form of SELECT writes the selected rows to a file. The file is created on the server host, so you must have the FILE privilege to use this syntax.&lt;/blockquote&gt;And the keyword is &quot;&lt;span style=&quot;font-weight: bold;&quot;&gt;server host&lt;/span&gt;&quot;. I made wrong assumption that it will write file to the server that execute the SELECT ... INTO OUTFILE.&lt;br /&gt;&lt;br /&gt;And the workaround is simple, just change my SELECT statement by remove the OUTFILE portion. And pipe the query to file from the MySQL command line&lt;br /&gt;&lt;blockquote&gt;mysql -u myuser -ppassword -h remotehost mydb &amp;lt; myquery.sql &amp;gt; my_output_file.txt&lt;/blockquote&gt;Reading documentation is bored but important :P</description><link>http://thiamteck.blogspot.com/2009/06/error-1-hy000-at-line-1-cant.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>4</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-8716594023175376300</guid><pubDate>Sun, 19 Apr 2009 11:17:00 +0000</pubDate><atom:updated>2009-04-19T19:19:09.338+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">guide</category><title>Passwordless SSH login via Public Key Authentication</title><description>SSH login with password authentication is often a problem for shell script that run without human interaction. One of the option by simulating user input via some &lt;a href=&quot;http://expect.nist.gov/&quot;&gt;Expect&lt;/a&gt; script. While another option is to setup certification based authentication.&lt;br /&gt;&lt;br /&gt;Below is the steps:&lt;br /&gt;&lt;br /&gt;1. SSH to client host (said with username &#39;myuser&#39;)&lt;br /&gt;2. Generate keys at client host, press &#39;Enter&#39; while it prompt for key location and passphrase.:&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;sql:nogutter&quot;&gt;&lt;br /&gt;$ ssh-keygen -t rsa&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;3. Upload the public key generated (~/.ssh/id_rsa.pub) to remote host home directory (said username &#39;remoteuser&#39;)&lt;br /&gt;3. SSH to the remote host with same username (&#39;remoteuser&#39;), create the .ssh folder if not exist&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;sql:nogutter&quot;&gt;&lt;br /&gt;$ cd ~&lt;br /&gt;$ mkdir .ssh&lt;br /&gt;$ chmod 700 .ssh&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;4. Import public key into authorized_keys&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;sql:nogutter&quot;&gt;&lt;br /&gt;$ cat id_rsa.pub &gt;&gt; ~/.ssh/authorized_keys&lt;br /&gt;$ chmod 600 ~/.ssh/*&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Now when the &#39;myuser&#39; at client host SSH to remote host with username &#39;remoteuser&#39;, it will not prompt for password anymore.</description><link>http://thiamteck.blogspot.com/2009/04/passwordless-ssh-login-via-public-key.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-6437705341431349181</guid><pubDate>Thu, 05 Mar 2009 14:54:00 +0000</pubDate><atom:updated>2009-03-05T23:06:08.628+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Duplicate log in log4j</title><description>If you have log4j configured as below, you will notice that log entry from &quot;yourLogger&quot; will duplicate in appender&lt;br /&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;css:nogutter&quot;&gt;&lt;br /&gt;log4j.rootLogger=info, stdout&lt;br /&gt;log4j.logger.yourLogger=info, stdout&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;To solve this, just change your configuration to:&lt;br /&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;css:nogutter&quot;&gt;&lt;br /&gt;log4j.rootLogger=info, stdout&lt;br /&gt;log4j.logger.yourLogger=info, stdout&lt;br /&gt;log4j.additivity.yourLogger=false&lt;br /&gt;&lt;/pre&gt;</description><link>http://thiamteck.blogspot.com/2009/03/duplicate-log-in-log4j.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>9</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-6482947492904206980</guid><pubDate>Thu, 01 Jan 2009 08:09:00 +0000</pubDate><atom:updated>2009-01-01T16:19:57.418+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">reading list</category><title>Reading List: Dec 2008 Wrapup</title><description>&lt;a href=&quot;http://chaoticjava.com/posts/io-performance-tar-file-bytes/&quot; rel=&quot;bookmark&quot; title=&quot;Permanent Link to IO performance - Tar vs. File vs. Byte streams&quot;&gt;IO performance - Tar vs. File vs. Byte streams&lt;/a&gt;&lt;br /&gt;Benchmark that show TAR file processing as a good alternative for better performance.&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.infoq.com/news/2008/12/Google-Mock&quot;&gt;Google Has Open-Sourced Their C++ Mocking Framework&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://java.sun.com/developer/technicalArticles/Interviews/studentdevs/index.html&quot;&gt;Top Java Developers Offer Advice to Students&lt;/a&gt;&lt;br /&gt;11 Top Java developers sharing their experience.</description><link>http://thiamteck.blogspot.com/2009/01/reading-list-dec-2008-wrapup.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-6852681708495569264</guid><pubDate>Sat, 27 Dec 2008 09:30:00 +0000</pubDate><atom:updated>2008-12-27T17:40:44.057+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Axis2 WSDL2Java error for SOAP Encoding</title><description>Recently had hit the SchemaCompilationException when using Axis2 wsdl2java to generate client stub from a WSDL file.&lt;br /&gt;&lt;br /&gt;After some google, had found &lt;a href=&quot;http://www.nabble.com/WSDL2Java-error-td20594340.html&quot;&gt;this page&lt;/a&gt; is describe same problem as what I face. And the reason for the exception is due to Axis2 do not support SOAP Encoding.&lt;br /&gt;&lt;br /&gt;Fortunately after a while, my colleague had found the solution. Instead of using ADB for data binding, use XMLBeans. Below is example of the command:&lt;br /&gt;&lt;br /&gt;wsdl2java -uri myService.wsdl -d xmlbeans</description><link>http://thiamteck.blogspot.com/2008/12/axis2-wsdl2java-error-for-soap-encoding.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>6</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-2563182081749223514</guid><pubDate>Sun, 30 Nov 2008 01:00:00 +0000</pubDate><atom:updated>2008-11-30T09:00:01.159+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">reading list</category><title>Reading List: Nov 2008 Wrapup</title><description>&lt;a href=&quot;http://www.infoq.com/news/2008/11/microsoft-joins-amqp&quot;&gt;Microsoft joins AMQP Working Group&lt;/a&gt;&lt;br /&gt;Microsoft already joins AMQP, so when will Sun?&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://blog.springsource.com/2008/11/11/more-weapons-for-the-war-on-complexity-springsource-acquires-groovygrails-leader/&quot;&gt;More Weapons for the War on Complexity: SpringSource Acquires Groovy/Grails Leader&lt;/a&gt;&lt;br /&gt;After acquire Covalent, SpringSource acquires G2One.&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://broadcast.oreilly.com/2008/11/interview-with-jason-hunter-of.html&quot;&gt;Interview with Jason Hunter of MarkMail.org&lt;/a&gt;&lt;br /&gt;Interview with Jason Hunter about the MarkMail.org and its architecture to scale to its terabytes data.&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.infoq.com/news/2008/11/Database-Martin-Fowler&quot;&gt;Martin Fowler see a Thaw in Frozen Thinking about Data Storage&lt;/a&gt;&lt;br /&gt;Besides the dominant RDBMS, Martin Fowler point out that RISC RDBMS and document-oriented distributed database can be an alternative for certain scenario.</description><link>http://thiamteck.blogspot.com/2008/11/reading-list-nov-2008-wrapup.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>0</thr:total></item><item><guid isPermaLink="false">tag:blogger.com,1999:blog-15101094.post-7503529384844407300</guid><pubDate>Fri, 14 Nov 2008 13:16:00 +0000</pubDate><atom:updated>2008-11-14T21:31:23.432+08:00</atom:updated><category domain="http://www.blogger.com/atom/ns#">Java</category><category domain="http://www.blogger.com/atom/ns#">Tips and Tricks</category><title>Java: convert UCS2 to UTF-8</title><description>While convert UCS2 into UTF-8, I hit UnsupportedEncodingException. So I use UTF-16 instead and it work well (at least till the time I write this post):&lt;br /&gt;&lt;br /&gt;&lt;pre name=&quot;code&quot; class=&quot;java:nogutter&quot;&gt;&lt;br /&gt;public String ucs2ToUTF8(byte[] ucs2Bytes) throws UnsupportedEncodingException{&lt;br /&gt;&lt;br /&gt;    String unicode = new String(ucs2Bytes, &quot;UTF-16&quot;);&lt;br /&gt;   &lt;br /&gt;    String utf8 = new String(unicode.getBytes(&quot;UTF-8&quot;), &quot;Cp1252&quot;);&lt;br /&gt;   &lt;br /&gt;    return utf8;&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;</description><link>http://thiamteck.blogspot.com/2008/11/java-convert-ucs2-to-utf-8.html</link><author>noreply@blogger.com (Thiam Teck (1983 - ?))</author><thr:total>1</thr:total></item></channel></rss>