<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
  <channel>
    <title>Code Wins</title>
    <description></description>
    <link>http://codewins.javaeye.com</link>
    <language>UTF-8</language>
    <copyright>Copyright 2003-2008, JavaEye.com</copyright>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <generator>JavaEye - 做最棒的软件开发交流社区</generator>
      <item>
        <title>I'm back</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/183800" style="color:red;">http://codewins.javaeye.com/blog/183800</a>&nbsp;
          发表时间: 2008年04月17日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          It has been a long time that not update my blog because the organization changes of IONA Technologies which I served for in the last 5 years.<br /><br />IONA has closed its APAC R&D Center on Jan. 31th 2008. It was 5 happy years for me in IONA and I'm very sad on the bad news.<br /><br />Anyway, I had to go on my life, I've gotten a job offer from one company and I will continue put my thoughts and ideas here.<br /><br />The best lucky to all of my friends in IONA.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/183800#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Thu, 17 Apr 2008 16:14:36 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/183800</link>
        <guid>http://codewins.javaeye.com/blog/183800</guid>
      </item>
      <item>
        <title>Books : I want to read</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/166233" style="color:red;">http://codewins.javaeye.com/blog/166233</a>&nbsp;
          发表时间: 2008年02月29日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          <a href="http://www.xiaozihang.com/?action=show&id=14" target="_blank">http://www.xiaozihang.com/?action=show&id=14</a>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/166233#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Fri, 29 Feb 2008 18:05:37 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/166233</link>
        <guid>http://codewins.javaeye.com/blog/166233</guid>
      </item>
      <item>
        <title>buzzword of computer today</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/150049" style="color:red;">http://codewins.javaeye.com/blog/150049</a>&nbsp;
          发表时间: 2007年12月21日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          CoC<br />RoR<br />DSL
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/150049#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Fri, 21 Dec 2007 18:18:40 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/150049</link>
        <guid>http://codewins.javaeye.com/blog/150049</guid>
      </item>
      <item>
        <title>Why Maven: Convention over Configuration</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/150044" style="color:red;">http://codewins.javaeye.com/blog/150044</a>&nbsp;
          发表时间: 2007年12月21日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Convention is at the heart of Maven. Convention over configuration is a popular aphorism these days, and Maven fully embraces this concept. Convention over configuration is at the central philosophy of frameworks such as Ruby on Rails, and more recently, the EJB3 specification. In its most basic sense it means that, while configuration is certainly necessary, the majority of users will never utilize such edge-cases those complex configurations provide. Although a powerful framework certainly needs to have the power to configure when necessary, it is certainly reasonable to create defaults to allow the 95% of similar use-cases to work without defining anything at all... the system can assume these defaults. In other words, the system has its own convention. Because of this, the monstrous configurations required of build tools like Ant (where a majority of Ant scripts are cut-and-pasted from existing projects) are non-existent for those projects that follow Maven's conventions.<br /><br />Another driving force behind the popularity of convention over configuration is the speed at which new users may pick up a new technology, or the speed by which a seasoned user may begin using the tool without concerning him/herself with details that need not come up until later in the development process. The computer world is finally beginning to embrace the idea that ease of use and reduced configurations do not have to interfere with the power of advanced configurability. Convention and configuration reside together within the Maven world, each providing their own unique perspective of a power tool.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/150044#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Fri, 21 Dec 2007 17:54:11 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/150044</link>
        <guid>http://codewins.javaeye.com/blog/150044</guid>
      </item>
      <item>
        <title>The way of Buckminster (1)</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/148152" style="color:red;">http://codewins.javaeye.com/blog/148152</a>&nbsp;
          发表时间: 2007年12月13日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          <a href="http://www.eclipse.org/buckminster/index.php" target="_blank">http://www.eclipse.org/buckminster/index.php</a><br /><br />Buckminster is a pretty new project of Eclipse, its target is make software assembly and deployment very easily than before. It's not another build system like Maven or Ant, but an useful complementary for them. It's not limit to only use in Eclipse, instead you can use it for any kind of project, even C++, if you have time to extend it.<br /><br />Basically, it's a software build on top of OSGi Framework, you can get more proofs if you try its headless package.<br /><br />A good start from here:<br />http://wiki.eclipse.org/Hello_XML_World_Example_%28Buckminster%29
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/148152#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Thu, 13 Dec 2007 17:39:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/148152</link>
        <guid>http://codewins.javaeye.com/blog/148152</guid>
      </item>
      <item>
        <title>create java Thread dump</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/147778" style="color:red;">http://codewins.javaeye.com/blog/147778</a>&nbsp;
          发表时间: 2007年12月12日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          生成Thread Dump在不同的操作系统中做起来也不同。在Windows中，是在JVM运行的控制台窗口中按下Ctrl-Break。对基于Linux和Unix的系统，则用kill命令将SIGQUIT发送到JVM。这可以通过命令kill – 3 完成，这里的pid是JVM的进程ID
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/147778#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 12 Dec 2007 13:17:51 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/147778</link>
        <guid>http://codewins.javaeye.com/blog/147778</guid>
      </item>
      <item>
        <title>TDD quick reference guide</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/147495" style="color:red;">http://codewins.javaeye.com/blog/147495</a>&nbsp;
          发表时间: 2007年12月11日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          A useful guide for TDD.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/147495#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Tue, 11 Dec 2007 11:16:05 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/147495</link>
        <guid>http://codewins.javaeye.com/blog/147495</guid>
      </item>
      <item>
        <title>FW: How to Shave Ten Hours Off Your Work Week</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/145882" style="color:red;">http://codewins.javaeye.com/blog/145882</a>&nbsp;
          发表时间: 2007年12月04日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          <a href="http://www.michaelhyatt.com/fromwhereisit/2007/11/how-to-shave-te.html" target="_blank">http://www.michaelhyatt.com/fromwhereisit/2007/11/how-to-shave-te.html</a><br /><br />Almost everyone I know is working more time than they would like. That’s why a book like The 4-Hour Work Week by Timothy Ferriss has been such a big bestseller. This is a great book, but the promise is a little over the top. I don’t know of anyone, including Tim Ferriss, who really only works four hours.<br /><br />But what if you could shave ten hours off your work week? In my opinion, that is much more do-able. Virtually anyone, with a little thought and effort can do it. Here’s how:<br /><br /><strong>1. Limit the time you spend online.</strong> In my experience, the Web is most people’s #1 time suck. Yes, I know it is a wonderful tool for research, blah, blah, blah. But I often catch myself and my family members mindlessly surfing from one page to another with no clear objective in mind. Before you know it, you can eat up several hours a day. The key is to put a fence around this activity and limit your time online. Set a timer for yourself if you have to.<br /><br />This is true for Web surfing and it is also true for email. Unless you are in a customer service position where you have to be “always-on,” you should check email no more than two or three times a day.<br /><br /><strong>2. Touch email messages once and only once. </strong>Okay, let’s be honest. How many times do you read the same email message over and over again? Guess what? The information hasn’t changed. That’s right. You are procrastinating.<br /><br />I have a personal rule: I will only read each message once then take the appropriate action: do, delegate, defer, file or delete it. I describe these in more detail in a post I made last week.<br /><br /><strong>3. Follow the two-minute rule.</strong> My to-do list is very short. It never gets longer than about thirty items. This is because I do everything I can immediately. If I need to make a phone call, rather than entering it on my to-do list, I just make the call.<br /><br />If I can complete the action in less than two minutes, I just go ahead and do it. Why wait? You will be amazed at how much this “bias toward action” will reduce your workload.<br /><br />Conversely, when you don’t do it promptly, you end up generating even more work for yourself and others. The longer a project sits, the longer it takes to overcome inertia and get it moving again. The key is to define the very next action and do it. You don’t have to complete the whole project, just the next action.<br /><br /><strong>4. Stop attending low-impact meetings. </strong>If there’s one thing we can probably all agree on, it’s that we go to too many meetings. Either the meeting organizer isn’t prepared, the meeting objective isn’t defined, or you can’t really affect the outcome one way or the other.<br /><br />Every meeting should have a written objective and a written agenda. If you don’t have these two minimal items, how do you know when the meeting is over? Could this also explain why meetings seem to drag on and on until everyone is worn out?<br /><br />If the content of the meeting is irrelevant to you and your job or if you don’t feel that you really add that much to the discussion, ask to be excused. <br /><br /><strong>5. Schedule time to get your work done.</strong> This is crucial. As the saying goes, “nature abhors a vacuum.” If you don’t take control of your calendar, someone else will. You can’t spend all your time in meetings and still get your work done.<br /><br />Instead, you need to make appointments with yourself. Yes, go ahead and actually put them on your calendar. Then, when someone asks for a meeting, you can legitimately say, “No, I’m sorry, that won’t work. I already have a commitment.” And you do—to yourself! <br /><br /><strong>6. Cultivate the habit of non-finishing. </strong>Not every project you start is worth finishing. Sometimes we get into it and realize, “This is a waste of time.” Fine, then give yourself permission to quit.<br /><br />I do this all the time with reading. It’s why I am able to read so many articles and books. Here’s publishing’s dirty little secret: most books are not worth finishing. Most books could be cut in half and you wouldn’t miss a thing. The key is to read as long as you are interested and then stop. There are too many great books to read without getting bogged down in the merely good ones. <br /><br /><strong>7. Engage in a weekly review and preview.</strong> Part of the reason our lives get out of control is because we don’t plan. Once a week, you have to come up for air. Or—to change the metaphor—you have to take the plane up to 30,000 feet, so you can see the big picture.<br /><br />I generally do this on Sunday evening. I review my notes from the previous week and look ahead to my calendar. I have written elsewhere on this topic, so I won’t repeat myself here.<br /><br />You may not be able to reduce your workweek to four hours—and honestly, who would want to?—but you can certainly scale it down to a manageable level by cutting out the wasted motion and developing a few good habits.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/145882#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Tue, 04 Dec 2007 15:05:17 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/145882</link>
        <guid>http://codewins.javaeye.com/blog/145882</guid>
      </item>
      <item>
        <title>学习 &quot;老友记&quot; 所得</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/144502" style="color:red;">http://codewins.javaeye.com/blog/144502</a>&nbsp;
          发表时间: 2007年11月28日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          chick : 小妞<br />potato potato : 发音 pertayto pertato : 挑三捡四<br />hot girl : 辣妹
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/144502#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 28 Nov 2007 14:21:32 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/144502</link>
        <guid>http://codewins.javaeye.com/blog/144502</guid>
      </item>
      <item>
        <title>DB2 JDBC driver's bug?, Connection is closed</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/144490" style="color:red;">http://codewins.javaeye.com/blog/144490</a>&nbsp;
          发表时间: 2007年11月28日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          I use code(DB2 JDBC 4 type driver):<br /><pre name="code" class="java">
Connection conn = ...;
Statement stat = conn.prepareCall(query);
state.execute();
...
resultSet.getMetaData();
</pre><br /><br />and I get exception like:<br /><pre name="code" class="java">
com.ibm.db2.jcc.b.SqlException: [ibm][db2][jcc][10335][10366] Invalid
operation: Connection is closed.
at com.ibm.db2.jcc.b.bb.Nb(bb.java:3356)
at com.ibm.db2.jcc.b.bb.a(bb.java:1589)
at com.ibm.db2.jcc.b.bb.prepareStatement(bb.java:490) 
</pre><br /><br />It's very strange that the same code works fine on MySql, Oracle, Sybase etc, at last it works, but I must create Statement like:<br /><pre name="code" class="java">
 statement = conn.prepareCall(query,
ResultSet.TYPE_SCROLL_INSENSITIVE,
ResultSet.CONCUR_READ_ONLY);
</pre><br /><br />So it's a DB2 JDBC driver implementation bug?
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/144490#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 28 Nov 2007 14:05:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/144490</link>
        <guid>http://codewins.javaeye.com/blog/144490</guid>
      </item>
      <item>
        <title>Did you meet this?</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/144481" style="color:red;">http://codewins.javaeye.com/blog/144481</a>&nbsp;
          发表时间: 2007年11月28日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          <a href="http://www.infoq.com/cn/articles/stop-aberrant-train" target="_blank">http://www.infoq.com/cn/articles/stop-aberrant-train</a>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/144481#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 28 Nov 2007 13:16:39 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/144481</link>
        <guid>http://codewins.javaeye.com/blog/144481</guid>
      </item>
      <item>
        <title>Enable https for Subversion client</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/143748" style="color:red;">http://codewins.javaeye.com/blog/143748</a>&nbsp;
          发表时间: 2007年11月26日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Subversion support protocol like:<br />- For anonymous: http, svn<br />- For committer: https, svn+ssh<br /><br />But as default, if you compile subversion client from source code, it only enable http, svn and svn+ssh but https, which often used by open source project such all projects of <a href="www.apache.org" target="_blank">www.apache.org</a>, actually enable https for subversion client is straightforward:<br /><br />- download source tar from <a href="www.tigris.org" target="_blank">www.tigris.org</a><br /><pre name="code" class="java">
$ tar zxvf subversion-1.4.5.tar.gz
$ tar zxvf subversion-deps-1.4.5.tar.gz
$ cd  subversion-1.4.5
$ ./configure --prefix=/local/subversion-1.4.5-ssl --with-ssl
$ make
$ make install
</pre><br /><br />I did see many articles on this, but those articles are so complex to understand, IMO, enable https is very easy.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/143748#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Mon, 26 Nov 2007 16:58:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/143748</link>
        <guid>http://codewins.javaeye.com/blog/143748</guid>
      </item>
      <item>
        <title>Lesson: use *.tar.gz but *.zip under Unix</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/143125" style="color:red;">http://codewins.javaeye.com/blog/143125</a>&nbsp;
          发表时间: 2007年11月23日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Today I want to reinstall my subversion client in my Linux box to enable SSL support, so I go to www.tigris.org and download subversion again, but unfortunately I download a zip file, then I fall into a well, the configure script complain can't create makefile correctly for me, after spending 2 hours on debugging, I find the reason is ^M in some important files :(<br /><br />After downloading a tar.gz file, all works fine for me now ;)<br /><br />So even Unix support *.zip and *.tar.gz, but it'd be better to use *.tar.gz but *.zip, otherwise you may meet strange error like me.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/143125#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Fri, 23 Nov 2007 18:01:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/143125</link>
        <guid>http://codewins.javaeye.com/blog/143125</guid>
      </item>
      <item>
        <title>a simple program reveal thread synchronization</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/142011" style="color:red;">http://codewins.javaeye.com/blog/142011</a>&nbsp;
          发表时间: 2007年11月20日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Here's a simple program but reveal thread synchronization mechanism:<br />- only one thread can enter critical region at a fix time<br />- two thread enter critical region one by one, and loop<br />- the time won't affect thread synchronization<br />- two thread work together like pass ball<br /><br /><pre name="code" class="java">
package com.demo.thread;

public class DemoThread {	
	public static void main(String[] args) {
		Object obj = new Object();
		
		Working worker1 = new Working("worker-1", obj, 2000);
		Working worker2 = new Working("worker-2", obj, 20);
		
		worker1.start();
		worker2.start();
	}
	
}

class Working extends Thread {
	private String mName;
	private Object mObj;
	private long mTime;
	
	public Working(String name, Object obj, long time) {
		mName = name;
		mObj = obj;
		mTime = time;
	}
	
	public void run() {
		while(true) {
			try {
				System.out.println(mName + " is waiting");
				Thread.sleep(mTime);
				System.out.println(mName + " is trying to enter critical region");
				synchronized(mObj) {
					System.out.println(mName + " has entered into critical region");
					System.out.println(mName + " will notify other thread");
					mObj.notify();
					System.out.println(mName + " will hang");
					mObj.wait();
					System.out.println(mName + " will quit critical region");
				}				
			} catch (InterruptedException e) {
				e.printStackTrace();
			}					
		}		
	}
	
}

</pre><br /><br />the output will like:<br /><pre name="code" class="java">
worker-1 is waiting
worker-2 is waiting
worker-2 is trying to enter critical region
worker-2 has entered into critical region
worker-2 will notify other thread
worker-2 will hang
worker-1 is trying to enter critical region
worker-1 has entered into critical region
worker-1 will notify other thread
worker-1 will hang
worker-2 will quit critical region
worker-2 is waiting
worker-2 is trying to enter critical region
worker-2 has entered into critical region
worker-2 will notify other thread
worker-2 will hang
worker-1 will quit critical region
worker-1 is waiting
worker-1 is trying to enter critical region
worker-1 has entered into critical region
worker-1 will notify other thread
worker-1 will hang
worker-2 will quit critical region
worker-2 is waiting
worker-2 is trying to enter critical region
worker-2 has entered into critical region
worker-2 will notify other thread
worker-2 will hang
worker-1 will quit critical region
worker-1 is waiting
worker-1 is trying to enter critical region
worker-1 has entered into critical region
worker-1 will notify other thread
worker-1 will hang
worker-2 will quit critical region
worker-2 is waiting
worker-2 is trying to enter critical region
worker-2 has entered into critical region
worker-2 will notify other thread
worker-2 will hang
worker-1 will quit critical region
worker-1 is waiting
worker-1 is trying to enter critical region
worker-1 has entered into critical region
worker-1 will notify other thread
worker-1 will hang
worker-2 will quit critical region
worker-2 is waiting
worker-2 is trying to enter critical region
worker-2 has entered into critical region
worker-2 will notify other thread
worker-2 will hang
worker-1 will quit critical region
worker-1 is waiting
worker-1 is trying to enter critical region
worker-1 has entered into critical region
worker-1 will notify other thread
.....

</pre>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/142011#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Tue, 20 Nov 2007 13:12:25 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/142011</link>
        <guid>http://codewins.javaeye.com/blog/142011</guid>
      </item>
      <item>
        <title>A good article on Eclipse Job</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/141941" style="color:red;">http://codewins.javaeye.com/blog/141941</a>&nbsp;
          发表时间: 2007年11月20日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          <a href="http://www.ibm.com/developerworks/cn/opensource/os-cn-eclipse-multithrd/index.html" target="_blank">http://www.ibm.com/developerworks/cn/opensource/os-cn-eclipse-multithrd/index.html</a>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/141941#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Tue, 20 Nov 2007 10:02:19 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/141941</link>
        <guid>http://codewins.javaeye.com/blog/141941</guid>
      </item>
      <item>
        <title>XP or not : no utter software development methodology</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/140125" style="color:red;">http://codewins.javaeye.com/blog/140125</a>&nbsp;
          发表时间: 2007年11月13日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          I've practiced XP for about four years, and I believe it's a excellent methodology for developing robust software, but recently I doubt what I got from XP, it become even worse when I read "Code Complete 2nd Edtion"(CC2E) those days<br /><br />- XP said unit testing is very very very important, so we should testing first, CC2E said test is important but not so much<br /><br />- XP said write code immediately, and improve software during iteration, but CC2E said if you don't get a clear/detail requirements before starting, you will be a loser, and improve software during iteration isn't a good way to follow, if we can do it well at starting, then it's the best way<br /><br />- From my practice, I met delay delivery several times even we use XP, and also a bad stable status of our software, I know it's not all fault of XP, but from CC2E I do know XP isn't a silver bullet too, XP isn't suitable for every type of software development, it has its own suitable area
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/140125#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Tue, 13 Nov 2007 11:04:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/140125</link>
        <guid>http://codewins.javaeye.com/blog/140125</guid>
      </item>
      <item>
        <title>Four years in IONA</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/135027" style="color:red;">http://codewins.javaeye.com/blog/135027</a>&nbsp;
          发表时间: 2007年10月24日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          On Saturday this week, I will have joined IONA for <strong><span style="color: red">four years</span></strong>.<br /><br />Even somebody will think it's a long time to stay in one software company, but it's so short compare with my foreign comrades'<br /><br />I'm very happy to have chance that I can work with some of the brilliant engineers in the world, I must admit I've learn lots of from them.<br /><br />For remembrance.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/135027#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 24 Oct 2007 10:29:34 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/135027</link>
        <guid>http://codewins.javaeye.com/blog/135027</guid>
      </item>
      <item>
        <title>Model is king: EMF will play a main role in Eclipse</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/134441" style="color:red;">http://codewins.javaeye.com/blog/134441</a>&nbsp;
          发表时间: 2007年10月22日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          If you have several years development experience in Eclipse plugin, then you will know that a good model is the key for a successful UI, even UI stuff is important, but the king is model behind it.<br /><br />As a important model driven development implementation, EMF become more important than before, you can see that from:<br />- EMF project itself has many subproject now<br />- A whole model toolkit has been setup which include many projects<br />- Some important Eclipse Top projects has embraced EMF such as WTP, DTP, TPTP, BIRT, VE and GMF etc.<br /><br />Even EMF growed up from Eclipse, it will become useful for projects outside of Eclipse environment.<br /><br />Any projects from GUI to runtime can use EMF as a tool for them model generate, I believe EMF will play a important role not only in Eclipse but also in runtime development.
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/134441#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Mon, 22 Oct 2007 14:01:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/134441</link>
        <guid>http://codewins.javaeye.com/blog/134441</guid>
      </item>
      <item>
        <title>We lost Beijing team kudos</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/132837" style="color:red;">http://codewins.javaeye.com/blog/132837</a>&nbsp;
          发表时间: 2007年10月17日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Our Ireland GUI team has taken over Beijing's task, it's the first time since I joined, I felt so embarass!<br /><br />In a word, we lost Beijing team kudos.<br /><br />It's not to say that we can't do it well, but whatever, it's a pity!
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/132837#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 17 Oct 2007 13:01:10 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/132837</link>
        <guid>http://codewins.javaeye.com/blog/132837</guid>
      </item>
      <item>
        <title>See out &quot;Friends&quot;, so long...</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/132832" style="color:red;">http://codewins.javaeye.com/blog/132832</a>&nbsp;
          发表时间: 2007年10月17日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Finally, I've seen out "Friends" now, it's a long TV play, but if you want to improve your English, see it, it's worth you to see, also, I must agree it's the best resource to practise English I've seen, ever!
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/132832#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 17 Oct 2007 12:52:36 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/132832</link>
        <guid>http://codewins.javaeye.com/blog/132832</guid>
      </item>
      <item>
        <title>An excellent article on UDDI tModel</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/125207" style="color:red;">http://codewins.javaeye.com/blog/125207</a>&nbsp;
          发表时间: 2007年09月19日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          IMO, that's the only article which explain tModel in a simple but clear way. All of UDDI spces are bag of bull S.H.I.T.<br /><br /><a href="http://www.codeproject.com/soap/understandingTModels.asp" target="_blank">http://www.codeproject.com/soap/understandingTModels.asp</a>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/125207#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Wed, 19 Sep 2007 10:10:23 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/125207</link>
        <guid>http://codewins.javaeye.com/blog/125207</guid>
      </item>
      <item>
        <title>How to design your own extension-point for Eclipse</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/123481" style="color:red;">http://codewins.javaeye.com/blog/123481</a>&nbsp;
          发表时间: 2007年09月13日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          Eclipse allow you to extend its functionalities by implementing its extension-point. We often write a Eclipse plugin which implement some of Eclipse's existing extension-points, e.g. if we want to contribute a popup menu for Eclipse, we need implement org.eclipse.ui.popupMenus extension-point, and follow the org.eclipse.ui.popupMenus's API contract which defined by org.eclipse.ui.popupMenus extension-point schema, then Eclipse will do things as we wish.<br /><br />So what happened here? Why Eclipse know how to process your popup menu contribution? How to add a pretty new functionality to Eclipse, which can't find or defined by Eclipse's existing extension-point? <span style="color: red">The answer is: contribute a extension-point for Eclipse by yourself.</span><br /><br />Here I will use a example to explain how to define a extension-point by yourself, suppose I want to write a view that will show services status which deploy in a container like tomcat, spring, websphere etc., and customer can add any unknown containers support by implement my new extension-point for this view.<br /><br /><strong>1. The requirements</strong><br /><br />I want to get service from container, also I need support unknown container type, so a client will be needed, i.e. I can user that client to get what I want to show in my view. So here I will define a client extension-point and this client will follow the interface contract below:<br /><br /><pre name="code" class="java">
public interface IClient {
    public void setHost(String host);
    public void setPort(int port);
    public void createClient();
    
    public List&lt;IService> listServices();    
}
</pre><br /><br />The three methods at beginning will set connection information for client and create a client instance, then listServices() will get service back<br /><br /><strong>2. Define client extension-point</strong><br />You can use PDE extension-point schema editor do this, here's my client schema:<br /><br /><pre name="code" class="java">
&lt;?xml version='1.0' encoding='UTF-8'?>
&lt;!-- Schema file written by PDE -->
&lt;schema targetNamespace="com.example.services">
&lt;annotation>
      &lt;appInfo>
         &lt;meta.schema plugin="com.example.services" id="clients" name="Clients"/>
      &lt;/appInfo>
      &lt;documentation>
         this extension-point will be used to connect different container
      &lt;/documentation>
   &lt;/annotation>

   &lt;element name="extension">
      &lt;complexType>
         &lt;sequence minOccurs="1" maxOccurs="unbounded">
            &lt;element ref="client"/>
         &lt;/sequence>
         &lt;attribute name="point" type="string" use="required">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
            &lt;/annotation>
         &lt;/attribute>
         &lt;attribute name="id" type="string">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
            &lt;/annotation>
         &lt;/attribute>
         &lt;attribute name="name" type="string">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
               &lt;appInfo>
                  &lt;meta.attribute translatable="true"/>
               &lt;/appInfo>
            &lt;/annotation>
         &lt;/attribute>
      &lt;/complexType>
   &lt;/element>

   &lt;element name="client">
      &lt;complexType>
         &lt;attribute name="id" type="string" use="required">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
            &lt;/annotation>
         &lt;/attribute>
         &lt;attribute name="name" type="string" use="required">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
            &lt;/annotation>
         &lt;/attribute>
         &lt;attribute name="clientType" type="string" use="required">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
            &lt;/annotation>
         &lt;/attribute>
         &lt;attribute name="class" type="string" use="required">
            &lt;annotation>
               &lt;documentation>
                  
               &lt;/documentation>
               &lt;appInfo>
                  &lt;meta.attribute kind="java" basedOn="com.example.services.client.IClient"/>
               &lt;/appInfo>
            &lt;/annotation>
         &lt;/attribute>
      &lt;/complexType>
   &lt;/element>

   &lt;annotation>
      &lt;appInfo>
         &lt;meta.section type="since"/>
      &lt;/appInfo>
      &lt;documentation>
         2007/09
      &lt;/documentation>
   &lt;/annotation>

   &lt;annotation>
      &lt;appInfo>
         &lt;meta.section type="examples"/>
      &lt;/appInfo>
      &lt;documentation>
         &lt;pre>
&lt;extension
         point="com.example.services.clients">
      &lt;client
            class="com.example.services.TomcatClient"
            clientType="tomcat"
            id="com.example.services.TomcatClient"
            name="Tomcat Client"/>
&lt;/extension>
&lt;/pre>
      &lt;/documentation>
   &lt;/annotation>

   &lt;annotation>
      &lt;appInfo>
         &lt;meta.section type="apiInfo"/>
      &lt;/appInfo>
      &lt;documentation>
         extension of this extension-point must implement &lt;samp>com.example.services.client.IClient&lt;/samp>
      &lt;/documentation>
   &lt;/annotation>

   &lt;annotation>
      &lt;appInfo>
         &lt;meta.section type="implementation"/>
      &lt;/appInfo>
      &lt;documentation>
         see com.example.services plugin for a implementation example
      &lt;/documentation>
   &lt;/annotation>

   &lt;annotation>
      &lt;appInfo>
         &lt;meta.section type="copyright"/>
      &lt;/appInfo>
      &lt;documentation>
         alexgreenbar
      &lt;/documentation>
   &lt;/annotation>

&lt;/schema>
</pre><br /><br /><strong>3. Extension-point handle classes</strong><br /><br />When my view need get services status back, I need load all contributed extension, and instance client which know how to get service status back, here's code:<br /><br /><pre name="code" class="java">
//describe every client contribution
public class ClientsEntry {
    private final static String ATTR_TYPE = "clientType";
    private final static String ATTR_CLAZZ = "class";

    private IConfigurationElement element;
    
    private String type;

    public ClientsEntry(IConfigurationElement aElement) {
        element = aElement;
        
        type = element.getAttribute(ATTR_TYPE);
    }
 
    public String getType() {
        return type;
    }
    
    public IClient createClient() throws CoreException {
        return (IClient)element.createExecutableExtension(ATTR_CLAZZ);
    }

}
</pre><br /><br /><br /><br /><pre name="code" class="java">
//ClientsRegistry manage all client contribution, use singleton pattern
public class ClientsRegistry {
    private final static Logger LOG = Logger.getLogger(ClientsRegistry.class.getName());
    
    private final static String EXTENSION_POINT_ID = "com.example.services.clients";
        
    private final static ClientsRegistry INSTANCE = new ClientsRegistry();
    
    private List&lt;ClientsEntry> entries = new ArrayList&lt;ClientsEntry>();
    
    private ClientsRegistry() {
        //
    }
    
    public static ClientsRegistry getInstance() {
        return INSTANCE;
    }
    
    private void load(){
        entries.clear();
        
        IExtensionRegistry registry = Platform.getExtensionRegistry();
        IExtensionPoint point = registry.getExtensionPoint(EXTENSION_POINT_ID);
        for (IExtension extension : point.getExtensions()){
            for (IConfigurationElement element : extension.getConfigurationElements()){
                entries.add(new ClientsEntry(element));
            }
        }
    }
    
    public List&lt;ClientsEntry> getEntries() {
        load();
        return entries;
    }
    
    public IClient getClient(String type) {
        IClient client = null;
        
        load();
        for (ClientsEntry entry : entries) {
            if (entry.getType().equalsIgnoreCase(type)) {
                try {
                    client = entry.createClient();
                } catch (CoreException e) {
                    LOG.log(Level.FINE, "can't instance client extension: ", e);
                    client = null;
                    continue;
                }                
                break;                
            }            
        }

        return client;
    }

}
</pre><br /><br /><strong>4. A example client extension</strong><br /><br /><pre name="code" class="java">
&lt;extension
         point="com.example.services.clients">
      &lt;client
            class="com.example.services.TomcatClient"
            clientType="tomcat"
            id="com.example.services.TomcatClient"
            name="Tomcat Client"/>
&lt;/extension>
</pre><br /><br /><strong>5. Use client extension</strong><br /><br />In the view code:<br /><pre name="code" class="java">
String newClientType = "tomcat"
IClient client = ClientRegistry.getInstance().getClient(newClientType);
client.setHost("localhost");
client.setPort(8080);
client.createClient();
List&lt;IService> allServices = client.listServices();
</pre><br /><br /><strong>6. Summary</strong><br /><br />So write a extension-point is not so hard? It's pretty easy actually! Could you imagine all the powerful functionalities of Eclipse are based on this extension mechanism?<br /><br />- ClientsEntry, ClientsRegistry can be reused, they are similar with code in Eclipse itself that process extension-point<br />- the most important thing is design your extension-point API contract and select a suitable opportunity to load your extension, apply lazy loading when possible
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/123481#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Thu, 13 Sep 2007 11:34:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/123481</link>
        <guid>http://codewins.javaeye.com/blog/123481</guid>
      </item>
      <item>
        <title>Is this a good/right way to use generic interface?</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/121353" style="color:red;">http://codewins.javaeye.com/blog/121353</a>&nbsp;
          发表时间: 2007年09月06日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          I have a generic interface like:<br /><pre name="code" class="java">
public interface Ia&lt;E> {
    public void add(E element);
    public E get();
}
</pre><br /><br />I can implement it like:<br /><br />1.<br /><pre name="code" class="java">
public class A implements Ia {

    public void add(Object element) {
    }

    public Object get() {
        return null;
    }

}
</pre><br /><br />2.<br /><pre name="code" class="java">
public class A implements Ia&lt;Object> {

    public void add(Object element) {
    }

    public Object get() {
        return null;
    }

}
</pre><br /><br />3.<br /><pre name="code" class="java">
public class A&lt;F> implements Ia&lt;F> {

    public void add(Object element) {
    }

    public F get() {
        return null;
    }

}
</pre><br /><br />4.<br /><pre name="code" class="java">
public class A&lt;F> implements Ia&lt;F> {

    public void add(F element) {
    }

    public F get() {
        return null;
    }

}
</pre><br /><br />IMO, all implementations above are valid, but:<br />* implementation 1 treat generic as old code before generic imported into Java, compiler will give a warning on it, but at least it's clear to most of all<br />* implementation 2 is weird in fact, it's same with implementation 1, but it will give a shock to user<br />* implementation 3 use generic interface in a not bad way, but it use Object on one of methods prototype, and I don't think it's better for user either<br />* implementation 4 use generic interface in a right way<br /><br />What's your insight?
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/121353#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Thu, 06 Sep 2007 17:38:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/121353</link>
        <guid>http://codewins.javaeye.com/blog/121353</guid>
      </item>
      <item>
        <title>A simple sample show generic interface usage</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/121351" style="color:red;">http://codewins.javaeye.com/blog/121351</a>&nbsp;
          发表时间: 2007年09月06日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          generic class is common so far, but generic interface is a little bit confused, the program below make concept clearly:<br /><br /><pre name="code" class="java">
public interface Ia&lt;E> {
    public void add(E element);
    public E get();
}

public interface Ib&lt;T> extends Ia&lt;T> {
    public void myString();
}

public class B&lt;F> implements Ib&lt;F>{

    public void myString() {

    }

    public void add(F element) {

    }

    public F get() {
        return null;
    }

    public static void main(String[] args) {
        B&lt;String> myB = new B&lt;String>();
        myB.toString();
    }

}

</pre>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/121351#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Thu, 06 Sep 2007 17:12:53 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/121351</link>
        <guid>http://codewins.javaeye.com/blog/121351</guid>
      </item>
      <item>
        <title>So bad on book translation recently</title>
        <author>alexgreenbar</author>
        <description>
          <![CDATA[
          <br/>
          作者: <a href="http://codewins.javaeye.com">alexgreenbar</a>&nbsp;
          链接：<a href="http://codewins.javaeye.com/blog/119887" style="color:red;">http://codewins.javaeye.com/blog/119887</a>&nbsp;
          发表时间: 2007年09月03日
          <br/><br/>
          声明：本文系JavaEye网站发布的原创博客文章，未经作者书面许可，严禁任何网站转载本文，否则必将追究法律责任！
          <br/><br/>
          I saw <a href="http://www.china-pub.com/computers/common/info.asp?id=32561" target="_blank">Refactoring to Patterns</a> in Haidian book store last Sunday, it's awful that its name has been translated as "重构与模式", <img src="/images/smiles/icon_eek.gif"/>
          <br/>
          <span style="color:red;">
            <a href="http://codewins.javaeye.com/blog/119887#comments" style="color:red;">本文的讨论也很精彩，浏览讨论>></a>
          </span>
          <br/><br/><br/>
          <span style="color:#E28822;">JavaEye推荐</span>
          <br/>
          <ul class='adverts'><li><a href='/adverts/41' target='_blank'><span style="color:red;font-weight:bold;">北京: 千橡集团暨校内网诚聘软件研发工程师</span></a></li><li><a href='/adverts/42' target='_blank'><span style="color:red;font-weight:bold;">搜狐网站诚聘Java、PHP和C++工程师</span></a></li></ul>
          <br/><br/><br/>
          ]]>
        </description>
        <pubDate>Mon, 03 Sep 2007 16:36:00 +0800</pubDate>
        <link>http://codewins.javaeye.com/blog/119887</link>
        <guid>http://codewins.javaeye.com/blog/119887</guid>
      </item>
  </channel>
</rss>