呢幾日諗緊一個難題,話說有個朋友,中學識嘅。我無同佢同過班,剩係同佢一齊讀過一個星期先有兩堂嘅 Computer Studies, 但係就偏偏係依家最老死嘅朋友。
我今日都問過佢,但係佢都解唔到究竟我哋點樣熟絡。我諗唯一解釋到嘅,就係緣。緣呢樣嘢好奇妙,只要時辰一到,擋都擋唔住。無嘅話,真係住响隔籬,甚至做埋同房,都唔會識到。
我呢,人緣就幾好喇,但姻緣就嘛嘛。
Search This Blog
Monday, January 31, 2005
Self-disposing Resource Pattern
A few mon, I have encountered a quite disturbing problem (see below). Until recently, I found that this problem can be solved by a interesting class, SoftReference, in Java. So, I formulated the following pattern. It's still a rough draft, but I would like to publish it first.
Name: Self-disposing Resource Pattern (Java)
Context: A is some expensive resource that may or may not be pooled. A is used to create another kind of resource, B. If A is disposed, it cannot create B anymore. However, if A is not disposed, the system may run out of memory.
Problem: Determine when to dispose A.
Solution: Java comes with SoftReference class for memory management. “An object is softly reachable if it is not strongly reachable but can be reached by traversing a soft reference.” An A instance can be registered to a resource manager to be a soft reference when it is no longer reachable by any thread. On the other hand, the resource manager can start off a thread to dequeue the SoftReference instances from a reference queue and clean up the resource properly.
Name: Self-disposing Resource Pattern (Java)
Context: A is some expensive resource that may or may not be pooled. A is used to create another kind of resource, B. If A is disposed, it cannot create B anymore. However, if A is not disposed, the system may run out of memory.
Problem: Determine when to dispose A.
Solution: Java comes with SoftReference class for memory management. “An object is softly reachable if it is not strongly reachable but can be reached by traversing a soft reference.” An A instance can be registered to a resource manager to be a soft reference when it is no longer reachable by any thread. On the other hand, the resource manager can start off a thread to dequeue the SoftReference instances from a reference queue and clean up the resource properly.
Friday, January 28, 2005
First Week of the Semester
The school has been started this Tuesday. I attended to the classes for three consecutive nights. It's so tired. Tomorrow, I need to take another one in the afternoon. I'll need to decide whether I should drop the Tuesday class. That class was very boring.
Monday, January 24, 2005
Days of Part-time Working
I haven't blogged for a long time. I am currently working as a part time. In theory, I should have more time than before and I should have more time to blog. Obviously, it's not.
I found that there are many personal stuff have to take care in the first. Like have the MP3 player fixed, applying for CEF, etc.
The second week, I got cold again. I had to take rest at home and didn't go to work out. My body get a bit slimmer. It's not good though. After I got better, I go hiking with friends and upgrading the CPU. Actually, these few weeks I was trying to get an AMD's Althon XP CPU which was out of stock. I gave up in this week and got a Sampron. Another thing I wanted to get was a Palm T3 which was again out of stock. I am considering if I should by T5 instead.
This week, I finally started trying to swim. Rocky now is my "couch" preventing me from drowning. Even just one day, I thought I had the key to swim.
Today, we went to Leo's home to play video games and having dinner together. It's a tired but enjoyable day. Rocky and I almost missed a bus when going there. However, we still miss the stop to get off the bus. Luckily, Michael and Sammi were still enjoying their lunch.
Interesting enough, we missed the bus of the back trip. We then take the MTR to get back home. When getting the last trip of the train, we missed the train again.
I found that there are many personal stuff have to take care in the first. Like have the MP3 player fixed, applying for CEF, etc.
The second week, I got cold again. I had to take rest at home and didn't go to work out. My body get a bit slimmer. It's not good though. After I got better, I go hiking with friends and upgrading the CPU. Actually, these few weeks I was trying to get an AMD's Althon XP CPU which was out of stock. I gave up in this week and got a Sampron. Another thing I wanted to get was a Palm T3 which was again out of stock. I am considering if I should by T5 instead.
This week, I finally started trying to swim. Rocky now is my "couch" preventing me from drowning. Even just one day, I thought I had the key to swim.
Today, we went to Leo's home to play video games and having dinner together. It's a tired but enjoyable day. Rocky and I almost missed a bus when going there. However, we still miss the stop to get off the bus. Luckily, Michael and Sammi were still enjoying their lunch.
Interesting enough, we missed the bus of the back trip. We then take the MTR to get back home. When getting the last trip of the train, we missed the train again.
Sunday, January 2, 2005
Summary of These Two Weeks
Xmas eve - Had a party with colleague, then friends.
Day after boxing day - BBQ with other friends, dinner with yet some other friends. It's a great day.
New year eve - tried to buy T3. However, it seems that it was totally out of stock.
Plan on 2005 - Study. Start profiling my financial status, again.
Day after boxing day - BBQ with other friends, dinner with yet some other friends. It's a great day.
New year eve - tried to buy T3. However, it seems that it was totally out of stock.
Plan on 2005 - Study. Start profiling my financial status, again.
Monday, December 20, 2004
Social Gathering
Last Saturday, I went to a colleague house club for a gathering. I played badminton, someone played squash. Then we had dinner and chatting together. It is quite enjoyable.
Vacation
It has been a long time I didn't take any leave. After two days of rest, I am really energized.
Exam
I took a two-day leave to study for the exam last week. The overall performance is good. However, I missed a 20-point question. Hope I can still get an A in this class.
Friday, December 10, 2004
Sick
I don't feel quite well since yesterday. However, I need to hold an important meeting this morning. So, I take off as soon as the meeting is done.
Another Colleague Leaving
One of my colleague is leaving the company as he does not want to keep implementing the always on-going project, which I am currently the project manager. I will not be the manager next month. However, he is a smart guy and very helpful. So, after next month, all old team member is gone. New manager, new developers, and new policy will take care the project soon.
Sunday, December 5, 2004
Final Decision
Everything seems going smoothly. I can work as a valuable part-time in the company about half of the day each day. So, starting from next month, I will have plenty of time to execute my plan.
I'll start learning swimming. Maybe going to take some Japanese course. Pressure will be much relieved.
I'll start learning swimming. Maybe going to take some Japanese course. Pressure will be much relieved.
Friday, December 3, 2004
Tension Relieved
I've told my intention on Tuesday. It turns out that my reasoning is based on some false assumption. Even though my time is still a constraint, I can choose to perform another role in the company. A role that can take less time. I can even choose to be a part-time, too.
As there are too many possibilities, it will take some time to think about it.
As there are too many possibilities, it will take some time to think about it.
Tuesday, November 30, 2004
The Intention of Leaving
I think it's about time to leave the company. I found that my job duty is going to be worthless. Even my manager has no priority to meet me for more than a week. I think it is good though. I can focus more on my study and speed up my progress.
Sunday, November 28, 2004
The Last Day of Class
Today is the last day of class. Even though I've dropped the class, I loved to attend it. I just don't want to do the homework anyway.
Friday, November 26, 2004
Money Matters: The First Month Loses
I have been trying the invest on the stock market for about 5 months. The last two trading days of this month will not go up to much. So, I think this month, the fifth month, is the first month I losing the money.
The Future
I've work for this company for about 2 years. However, I found that the work load given by this company is torturing. Now, I need to be a project manager of an ERP project which has been also existing for about 2 years. I've have been already working on this project for 1.5 years, from implementation to current status.
Even though I am the project manager and there are another four team members, all of them have another projects on hand. No one can guarantee what can be done and what can't be done given a deadline. The schedule, which has been fixed, is simply means nothing.
I don't want to bear the risk of the project anymore. In fact, I don't want to be a project manager. Studying the degree already takes me so much time. Being a good project manager takes time. My life will be very hard in order to studying hard and work hard. As a matter of fact, I already need to withdraw a course in order to take care of the human resources changes of the project. I don't want this happening again. It's wasting my time and money.
Monday, I'll propose to my manager that either I'll not do any project management or I'll quit the job. Study now is my first priority. Almost nothing can change it.
Even though I am the project manager and there are another four team members, all of them have another projects on hand. No one can guarantee what can be done and what can't be done given a deadline. The schedule, which has been fixed, is simply means nothing.
I don't want to bear the risk of the project anymore. In fact, I don't want to be a project manager. Studying the degree already takes me so much time. Being a good project manager takes time. My life will be very hard in order to studying hard and work hard. As a matter of fact, I already need to withdraw a course in order to take care of the human resources changes of the project. I don't want this happening again. It's wasting my time and money.
Monday, I'll propose to my manager that either I'll not do any project management or I'll quit the job. Study now is my first priority. Almost nothing can change it.
Accomplishment
Today, I've finished the user interface implementation of table dependency finder, my new product. I used to develop software development tools. This is one of them. However, the company seems not quite need them.
Here's the pattern:
Here's the pattern:
- My colleagues always encounter some problems over and over again.
- There are tools available on the market.
- The tools are expensive.
- My colleagues solve them manually.
New Diary
I have stop writing diary for a long time. First, I am busy. Second, it's hard to maintain a site of diary 2-3 years ago. So, now here I am.
Subscribe to:
Posts (Atom)
Popular Posts
-
睇完下面三個例子,你就知點解人家有普選。 埃及: 全國有多達一千四百萬人上街示威,比例佔全國人口近一成七 ( 埃及千四萬人上街要求總統下台) 香港: 香港泛民主派在雨中舉行年度七一爭普選遊行,主辦單位稱有43萬人參加。( 視頻:香港43萬人參加七一遊行 ) 約為人口 6%....
-
Somehow 瞓唔得太著,八點幾就晒咗,上網 check 吓 email 睇吓 website 咁。九點鐘左右就換衫,準備出發去格林威治子午線。搭地鐵,轉輕鐵,唔駛一個鐘就到咗格林威治,再行多十五分鐘左右就到子午線。子午線响皇家天文台入面,响一座出丘度,响山丘頂,視野遼闊,加上...
-
作品原來唔止得 Video, 種類比想像中多,為咗要集中所有作品,就用咗 Yahoo! Pipes 去完成成件事,有埋 Landing Page . 再用 Microsoft Popfly 做咗個 iGoogle Gadget . 玩得最癲都係今次。 另一個問題係原來 Faceb...
-
話說 Audition 完結,一位小朋友走入嚟話要自我檢討的說,低估咗問題所在,只係好 Casual 咁注入少少正能量。直到之後見到一句 Status, 我似乎無意識咁置身於風眼嘅中心。之前一日,我講過,作為老師,佢嘅學生要有老師一樣嘅功力,先叫合格。但係,我無講到時間,所以令到...
-
其實我係用電腦睇電視,所以唔存在熄唔熄電視嘅問題。我可以 YouTube, 日劇、動畫同電視一齊開,差在邊個 Pause 同邊個滅聲。唔係話熄電視日無意義,但係如果响現實當中,大部份睇嘅係師奶,我諗,佢哋追劇,緊要過新嘅電視台...
-
今日睇到一段 YouTube 片係講23種特別嘅動物,當中有一隻嘅名係叫 Pica (讀 Pie-ka), 個串法正正就係比卡超嘅頭兩個音,似乎就係比卡超嘅原型嚟。 以前就話開卷有益,今時今日,似乎就係開 YouTube 睇有益了。 話說噚晚同徒弟仔傾到「Google大神...
-
I've work for this company for about 2 years. However, I found that the work load given by this company is torturing. Now, I need to be ...
-
Wednesday is the first day of Chinese New Year. I enjoyed the day with my family. We first went to restaurant to "drink tea". T...
-
星期一開始,無線嘅晚間新聞多咗 D 少少評論/分析/互動嘅部份,主播依然照稿讀,但表達得生硬,唔 Pro 得好緊要。可憐嘅係體育主播,企咗响無雷公咁遠,雖然有部大電視响側跟,但感覺好孤獨,希望佢係有位坐,唔駛企足半粒鐘。 新聞報導一向都係中立,多咗主觀成份,感覺好怪。 P.S.:...