Archive of original



  • From Taiwan, living and working at Tokyo, Japan.

Recent Posts


Site Info

Locations of visitors to this page

Logos & Chicklets


Rex's Certifications
Rex's Certifications

Creative Commons授權條款
本 著作 係採用
Creative Commons 授權條款

May 2005 - Posts

NHibernate: <set> v.s. <bag>


if you read the whole Hibernate in Action book, you'll find that in Java world, people use "set" collection often. most of the NHibernate articles and examples followed Hibernate's Java trend, using <set> to map one-to-many and many-to-many relationships.

if you thought NHibernate is an easy-to-use O/R Mapper, it is, before you really start using it in some real-world applications. I am not saying that NHibernate not able to face the real-world challenges, I am saying that if you want to use NHibernate in your production solutions, you better know it deeper!

Paul Wilson released his WilsonORMapper 4.0 couple days ago. after that soon he announced a "Real NHibernate Example App", a WinForm C# example that covered most of the things to let you start using NHibernate. it's a good one! also by checking this post's comments,  James mentioned an opensourced "Real NHibernate Application, Cuyahoga CMS" , using NHibernate for persistanting Content Management data to data store.

Read more on NHibernate reference.chm file about Collection Mapping, you'll understand NHibernate used another open-source implementation of Set collection to port Hibernate's code. there is no Set collection in .NET framework. (and the book Hibernate in Action won't mention it since the book didn't cover NHibernate). so if using <set> to map collection, the return type won't be standard .NET collection type (it's Iesi.Collections.Set). most of NHibernate examples using <set> mapping along with IList in code, but don't know why I just not able to make it work.

both Wilson's example as well as Cuyahoga CMS used <bag> mapping with IList type ArrayList for collection mappings. I did switch to it and found it work. for your reference UncleG's blog post got a table about each mapping to collection type.

<bag /> IList
<list /> IList
<set /> Iesi.Collections.Iset (from the Iesi.Collections.dll assembly in the \bin folder of the NH distribution)
<map /> IDictionary

Hibernate in Action book got lot's of examples talking about component mapping. together those various mapping ways should fit into most of the data-related applications people are facing. but none of the information I found got complete reference about the nodes and attributes explaination.

Getting into more advanced scenario, you should face about constructing a good session management pattern for NHibernate sessions, and to let your persistant objects be more flexible from switching between those ORM tools.

tools are just building blocks, just a start. you'll need to have your own style frameworks. and that's why architectures fun.



ActiveSync 3.8 sucks...


I wasted my whole day today just to find out why my iPaq couldn't sync my laptop anymore! I got some project milestones to due tomorrow and I even bought a new cord to test the connection! and later found out that after I re-install back to activesync 3.7, everything is normal again!

search for Google and found nothing about it, only posts about that activesync 3.8 enhanced features and there maybe firewall problems when installing this software. when I got 3.8 installed, neither USB cord nor BlueTooth work anymore, it just show connected, syncing, and after seconds, disconnected without anything synced!

it's really frustracting when I just simplely found the thing goes normal after re-install back to 3.7, and I have to stay up the whole night to prepare the due tomorrow. I don't have time to testing about the firewall things, and right now I only want to say:

ActiveSync 3.8 sucks!


Posted: 2005/5/31 0:16 by rextangtw
Filed under:
My GeoURL Map...


I noticed a trackback from my TrackFeed (it's always a pleasure to check my trackback everyday to see who was seeing my site!) it's from, and soon I found this interesting.

it's a GeoURL Map application, if you got GeoURL in your blog, you can use this Map right the way!

see the flash movie above. the red dot is my place with my blog url if you stay your cursor there. the blue dots are blogs near me. zoom-in and left click and hold mouse button can let you move the map around. click the room-in / room-out buttons can let you room in/out as you want. finally, click any blue dot (or red one) can take you to the blog right the way!

GIS (Geographic Information System) is getting more and more popular, and it makes the world more convenient!


.Text : about comment spam...


finally, I got my first comment spam, even though I TURNED the comment feature off! (now you know why I turned my comment feature off, not because .Text didn't provide the feature!)

you never know how many spammers and hackers around the internet are scanning your site, therefore if your server lives LIVE on the internet, you'll definately need a firewall, servers without firewall and living on the internet are just like suicide!

if you are using .Text 0.95 source, there was no spam control in the code, you'll have to get some other things to protect your PostComment.ascx file from the spammers.

I found my site been spammed just after I switched my .Text skin to OneNote skin. The original skin watercolor from Joey Beninghove got it's spam controller from CAPTCHA CONTROL thus prevent my site from those spammers, when I switched to new OneNote skin from RoudyBob.Net, it didn't have it on PostComment.ascx, and I guess my blog is popular enough to be spammed, therefore right after I changed my skin, I got 96 spam comments right after!

the fact is, .Text is popular enough to be an opensource blog app that it's comment function got pattern to let spammers put the spam around each post. EVEN you turn off the comment feature on the Control Pannel of Admin page. if you didn't do anything to protect your PostComment.ascx, then you'll still be spammed!

so , if you still want your comment feature in .Text, you need to put some spam control on your PostComment.ascx, and remember to apply it when you change your .Text Skin! if you decide to turn the comment feature off, remember to leave the spam control inside the PostComment.ascx or just RENAME your PostComment.ascx to some other filename, doing so will result Custom Error page when the spammer trying to do comment spam, but since you've already turn comments off, it doesn't matter!

Sometimes I really HATE those people who using technology in such annoying ways!

Be careful running your sites, my friends...




出國比賽進入倒數檢查行李相關證件階段(其實是去參加研討會兼年休假自助旅行), 因為要過境日本東京停留兩天走走看看, 所以特別再一次確認日本簽證相關事項.


2005年 3月 4日創建

3月4日,內閣會議決定「為增進2005年日本國際博覽會來訪之外國觀光客相關 之法律」施行之必要政令。




4‧ 出發地、入境地點

因為愛知博覽會的關係, 所以到九月都免簽證, 所以應該不用跑一趟交流協會了...

年底前還得去一次東京, 那就挑九月中以前去好了... 嘿嘿...


Google Maps rocks!


it's only 5 days before I heading to TechEd 2005. since I'll have to stay at Florida travelling around to Miami , also will stay at San Francisco, I'll need to get more information on retail car and accommodation to get my detail travel plan all done (as for my plan of Tokyo in the end of this trip, this won't help much.)

and that's what I've discovered the power of Google Maps... see the pic below and I think you'll know it!

it's nice to live at states.

Microsoft Certified Architect Program...


Today's hot Microsoft news, I read from DevHawk's blog, that Microsoft re-launched the MSDN Solution Architecture Center site, as well as a new site "Architechture Recource Center". full of architect's blogs as well as various resources about architechture solutions as well as infrastructures for businesses via Information Technologies .

What interested me is the Microsoft Certified Architect Program , I've noticed Ask TheServerSide feedbacks about what architects should equip with, and after reading the program, I feel that it's just like a Academical Master / Ph.D program that's different from regular exam-based certifications Microsoft or other parties had.

It requires at least 10 years verifiable experience as a practicing architect! ok, guess I am too young for this industry (10 years computer science playaround experience, graduated from related area dept. of university, and only countable 5 years working time in IT industry with few "verifiable" experience. better start to organize it from now!)

Architecture is an interesting thing, especially when facing business problems, there are many factors affecting your final decisions about a workable and in-budget architecture, and one as a distinguished architect must has knowledge as well as experience to work out a successful solution.

I found those competencies that will be tested during electing a MS Certified Architect useful to assess one who wants to have a job like this. actually I did find those necessary in successing an excellent business solution from my working experience. I'd like to put it in this post to remind myself to be a better one in this area.

The certification process has documented criteria that the Microsoft Certified Architect Review Board uses to judge candidates:

  • Leadership: Candidates demonstrate that they develop partnerships with stakeholders across the organization on their projects; that they can mentor others; that they develop and form strong teams; and that they achieve successful results.
  • Technology Depth: Candidates demonstrate that they have a deep understanding of the concepts and application of at least two core technologies (for example, messaging, storage, Windows, networks, etc.) plus the ability to quickly assimilate information about new technologies.
  • Technology Breadth: Candidates understand architectural best practices and are able to apply them across a breadth of technologies to orchestrate a solution. They also have views on the future development of a technology and how it might influence current solutions. Finally, they understand the interaction between infrastructure, solution, and enterprise architecture and practices.
  • Strategy: Candidates demonstrate understanding of enterprise architectural frameworks such as TOGAF and operational frameworks such as ITIL and be able to use these frameworks in their projects. They also understand project management principals and how architects interact with project managers to deliver projects. In addition, they understand the economic dimension of projects and how costs influence the available choices for technology.
  • Organization Dynamics: Candidates show that they are able to recognize the key stakeholders in a project and that they can work with those stakeholders to drive a project to a successful conclusion. They present the ability to pick the right battles at the right time and then recognize the political landscape that influences a project within an organization and then influence organizational politics for the success of their projects.
  • Tactical/Process: Candidates demonstrate that they can gather and refine project requirements from both a technical and business perspective. They understand how to effectively prototype and test a solution and also showcase the talent to create effective project artifacts. Lastly, they exhibit the ability to refine project goals and the tactics necessary to achieve those goals as the project develops.
  • Communication: Candidates show that they maintain well-written and accurate project documentation; they are able to present information on a technical subject in a concise and measured manner; they have the ability to influence others; they have the ability to manage conflicts effectively; and to tailor their communication to the needs of the target audience.


Yahoo! PhotoMail beta...


Yahoo! 新出了一個整合相片及電子郵件的服務, 叫做 Yahoo! PhotoMail (beta). 他是透過在自己的電腦中安裝一個小的相片上載程式, 跟 Yahoo! Mail 協同運作, 很方便的將想要分享的相片做縮圖及整理的動作. 在寄出信件時程式會自動上載圖片到你的 Yahoo! Photos 相簿去, 所以收信的人不會收到很大的信件, 但是還是可以用很方便的方式瀏覽上載到網路的相片. 今天的 CNet 新聞有相關報導. 也可以看看這項服務的線上導覽.

這是 Yahoo! 在買下 Flickr 後第一個相關的整合動作. PhotoMail 的 uploading tool 看起來也很像 Flickr Uploader, 只是要用的話只能跟網頁版的 Yahoo! Mail 搭配使用, 並不能使用自己常用的信件軟體 (Outlook 等等). 將相片放在網路上有系統的整理讓使用者瀏覽本來就是 Flickr 在做的事情, 所以這樣的整合也並不意外, 而且我覺得這樣的企畫還滿有創意的.

我覺得未來 Flickr 應該會跟 Yahoo! Photos 整合在一起, 不過現在就會有一個問題. 就是如果已經是 Yahoo! 服務的付費會員 (如電子郵件等), 在這樣的整合後, 能否使用 Flickr 的所有功能呢? 如果是這樣, 那現在還需要付費成為 Flickr 的會員以享受更大上載頻寬及不限制網路儲存空間的服務嗎? 這是目前 Yahoo! 應該解決的市場定位問題.



MSN Messenger v7.0.0813 update...


晚上回到家開電腦準備徹夜趕程式的時候, MSN 告訴我要跟新版本, 因為有 PNG 的一些漏洞要修正. 所以我就乖乖的更新了, 更新後的版本是 7.0.0813.

更新後廣告視窗跟一些拉裡拉雜的東西又都回來了, 所以就用以前的那個修補程式修補, 但是他有限制只能用在 7.0.0777 的版本, 所以必須再到修補程式的網站去下載最新版的修補程式. 下載的時候發現這個更新 5/8 就有了, 也就是我接到的更新版本通知太晚了!!

這個修正程式還不錯, 除了有很多選項讓你選, 選完就幫你修正, 除了最主要的移除廣告橫幅, 還有很多可以設定...







Konfabulator: 2


I updated to Konfabulator: 2 last weekend. too busy to have time blog about it until I saw RoudyBob.Net's post yesterday.

I've used this small and useful app since last month when my friend told me about it. this version update should mainly for the Apple's Tiger release. it added two new features which interact with your PIM software and monitor your memory usage. also many other updates on previously installed widgets. view the Version History for more details...

the only problem for now is that I might go buying a registered copy to avoid it's purchase info message...

it's a nice app to let you got what Apple's Dashboard has, you should try it...





去年夏天本來一群朋友計畫再到澎湖玩一次, 所以我一時興起就很認真的問 Google 並且作了一個自由行旅遊的企畫. 雖然去年後來時間沒橋好沒去成, 但是我想這份留下來的文件應該滿有用的.

澎湖... 今年夏天一定要去!


Book: Hibernate in Action...


I've been busying mapping my business tier objects to data-tier using NHibernate, an excellent port from Hibernate in Java world.

2 things to say.

first, the xml schema for the mapping file is sort of clear and excellent, but you should take some time reading some articles as well as the documentations both in NHibernate site and Hibernate site to get a more detailed understanding on mapping your objects to database. The quick start guide on NHibernate site and both Justin Gehtland's articles on TheServerSide.Net (here and here) all providing very understanding examples, are always my good companions while constructing the mapping files.

after constructions of the mappings, the next step should be finding your data using this ORM framework. on this part, those articles didn't help much.

I have to admit that the documentation on NHibernate site is far more less than necessary, but it's really a good porting of this framework.

second, as far as reaching to actually using the framework in my project, I need a more comprehensive information on how to use it efficiently without just blinding try-and-error process (don't have the time!) and Google told me this book!

Hibernate in Action, published by Manning Publications at Auguest 2004 (Amazon), authored by Christian Bauer and Gavin King. This should count as a comperhensive book for ORM concepts and Hibernate (thus also suitable for NHibernate!) the TheServerSide.Com (Java version of TheServerSide) had an article introducing this book.

I appreciated the chapters (chap.4 and chap.7) detailing HQL, the Hibernate Query Language! that's all I need for now. full of examples and explainations of various kinds of usages and tricks on HQL to complete common and uncommon tasks that will always happen on your data work process. you'll ultimately find the power of Hibernate / NHibernate throughout those chapters!

There are many other ORM tools available now, but if you are sticking on Hibernate / NHibernate, this book should be a must read and reference beside your notebook computer!


MSN Virtual Earth v.s. Google Earth...


微軟首席軟體建築師比爾蓋茲D3高峰論壇中說今年夏天要讓虛擬地球登場 (外電報導, Blog, Slashdot) ! 並且保證虛擬地球可以做到以下的事情:

  • 四十五度角瀏覽的衛星照片讓你看的清楚建築物及周邊.
  • 衛星照片附加地圖圖層在上面, 讓你看的到真實的景物, 也有地圖道路資訊的說明.
  • 可以繼續增加地區相關資訊說明圖層, 例如加油站, 銀行, 餐廳資訊等等.

這項服務可以讓使用者用各種不同的角度檢視地理資訊, 並且也可以自行添加實用資訊到系統中與其他人分享.

上個星期咕狗才剛剛宣布他新買的鑰匙洞軟體公司可以讓使用者看到清晰衛星圖片的這項服務將正式命名為咕狗地球, 並且也將更迅速的更新咕狗地圖中的衛星圖片讓使用者瀏覽.

虛擬地球以及咕狗地球可見, 微軟咕狗的戰爭正日漸的白熱化中...

(戰地記者 雷克斯湯 網路中報導...)





Update your MSN Alerts Link...


MSN bought MessageCast at 5/12 this year. right after this news my MessageCast alerts stopped function for a while until now (other Alerts I subscribed also didn't function anymore until tonight I saw the alerts coming again!)

Microsoft changed the domain name for MessageCast Alerts (now named MSN Alerts). so for those who put your Alert link on blog, remember to update your link to let it work again.

actually I just found that my registered info in old MessageCast database not working anymore, so I have to register a new one. the old link keep getting server error!

so, for those who like to read my posts as soon as possible, click this MSN Alerts !






剩十天出國, 但是因為很忙, 忙到沒時間把細部行程排好, 這讓我很緊張!

這個週末前一定要把行程搞定! 不然租車 book 旅館的時間一定不夠!

順便徵求東京友人導遊一下, 我只待兩天. 什麼? 恩! 是的, 我鄉巴佬, 美國去透透了, 長這麼大第一次去東京... 而且我年底前還得再去一次!

出國前專案 beta 版要上線! 而且我不想把工作帶到佛羅里達, 因為每天要拍照寫遊記 blog 已經會很累了!

但是沒關係, 飯可以隨便吃, 吃的飽就好, 覺可以隨便睡, 不要賴床就好, 但是音樂絕對無法隨便亂聽, 音樂很重要!

HitFM 91.7 夜貓 DJ Dennis, 每晚12點到3點, 有你陪我真好~

我很忙, 但是有音樂陪我就好! それだけでいいんです!



Posted: 2005/5/24 1:37 by rextangtw
Filed under:
More Posts Next page »