凡's profileMATRIX WorldPhotosBlogListsMore Tools Help

Blog


    May 18

    Change

    The popular word- Change.
     
    Zhu ask me to wait and he think I am not ready. I told him I am ready now.
    Things are changing and new world is coming.
    December 14

    帮助别人的感悟(转发)

    看到李连杰的一段采访,觉得很有感悟:

    对人生的认识,有三个层次。第一,生命,是不由自己控制的。我们控制不了生,也控制不了死。第二,光着身子来,也是光着身子走的。所有的东西,生带不来,死带不走。第三,出生的时候,需要有人帮你剪断脐带,有人打你的PP让你发生第一声啼哭,一直到你成人,都是需要很多人帮助你平安长大的,而死的时候,也需要有人帮火化,安葬~~这些都是需要人帮助的。因为这三点,使得我们也需要去帮助别人,成为了像呼吸那么自然的事情了。

    November 18

    Discussion about "Could not deserialize session data"

    Chief description:

     

    BEA-100028
    Error: Could not deserialize session data.

    Description
    Could not deserialize session data.
    Cause
    Failed to deserialize session data.
    Action
    Make sure the object you are putting into the session is serializable and also the non-transient object it aggregates are also serializable. If any of the non-transient objects in the entire object graph are not serializable, you will receive this error message.

     

     

    Further research :

     

    From: Martin Gainty
    Subject: Re: "could not deserialize the context attribute .. " (configuration: struts 1.1 + web logic 8.1), is it a known bug ?
    Date: Sun, 19 Oct 2003 07:23:41 -0700

    --------------------------------------------------------------------------------

    This is a WL specific issue
    "servlet 2.3 spec disallow non serialized objects in the PageContext so
    built this into the current
    release of Weblogic."

    Later on Matt Heaton remarks:
    "Struts source and it's trying to use objects which aren't serializable as
    JSP page context attributes"

    Craig McClanahan replies:
    "Yep.  Looking more closely at the error message, it is complaining about a
    non-Serializable *context* attribute, not a *session* attribute.  I, like
    others, jumped to the wrong conclusion there. The spec provides no
    prohibitions on this -- only a warning that you cannot
    use a context attribute to share information globally in your application
    (the
    way that the example app does with its pseudo-database) in a distributed
    nvironment.
    Is there by chance some WebLogic specific configuration property you have
    set that makes it think this (or maybe all) applications should be treated
    as distributable?"

    A Later comment by Craig:
    "I'm afraid that I see no such requirement in the servlet 2.3 spec (and I'm
    on
    the expert group that came up with it .  The only restrictions on
    Serializable attributes in the spec itself relate to *session* attributes,
    not
    *context* attributes.  And that restriction only applies when you mark your
    app
    as <distributable/>;.

    Note also that the WebLogic response quoted in the message from Ruslan gave
    an
    entirely different reasoning (their application server requires all
    attributes
    to be Serializable if you use the "reload on modify" feature).  That's an
    entirely reasonable restriction for WebLogic to place, based on their
    container's internal architecture.  It's not, however, a spec compliance
    issue.

    That all being said, I'm looking at ways to make MessageResources a
    Serializable
    object.  Unfortunately, java.util.ResourceBundle (which it relies on) is
    *not*
    Serializable, so a different solution to that is going to be required.

    The pseudo-database in the Struts example application (which has nothing to
    do
    with the framework itself) is not Serializable, and will *not* operate
    correctly
    in a distributed environment.  I'm NOT planning on changing that in the
    short
    term, because it's only there to give you a quick "proof of concept" that
    Struts
    is working, plus some examples of some Struts-related development
    techniques."

    http://www.mail-archive.com/[EMAIL PROTECTED]/msg01017.html

    Weblogic Solution:
    "WLS comes with reload-on-modify turned on out of the box. You can turn it
    off by setting reload periods to -1 (never check). There are two separate
    params for JSP and servlets.
    The one for JSPs is set in weblogic.xml descriptor,
    the one for servlets is set in the console."

    i.e. Turn off reload-on-modify

    Sorry for the long-winded response!

    -Martin
    ----- Original Message -----
    From: "Marc Dugger" <[EMAIL PROTECTED]>;
    To: "Struts Users Mailing List" <[EMAIL PROTECTED]>;
    Sent: Sunday, October 19, 2003 8:36 AM
    Subject: RE: "could not deserialize the context attribute .. "
    (configuration: struts 1.1 + web logic 8.1), is it a known bug ?


    >; I had a somewhat similar issue with Tomcat when it came to serializing a
    >; FormFile.  I got around this by extending the MultipartRequestHandler and
    >; implementing Serializable.  It appears that you could do the same with the
    >; RequestProcessor.  Be sure to add this to your struts-config.xml:
    >;
    >; <controller contentType="text/html;charset=UTF-8" locale="true"
    >; nocache="true" processorClass="your.package.CustomRequestProcessor"
    >; debug="9" />;
    >;
    >;
    >; >; -----Original Message-----
    >; >; From: Shay Cohen [mailto:[EMAIL PROTECTED]
    >; >; Sent: Sunday, October 19, 2003 3:17 AM
    >; >; To: '[EMAIL PROTECTED]'
    >; >; Subject: "could not deserialize the context attribute .. "
    >; >; (configuration: struts 1.1 + web logic 8.1), is it a known bug ?
    >; >;
    >; >;
    >; >; Hi,
    >; >;
    >; >; I've encountered lately the following exception "Could not deserialize
    >; >; context attribute....". Reported on the following attribute:
    >; >;
    >; >;
    >; >;             Attribute: org.apache.struts.action.REQUEST_PROCESSOR
    (object:
    >; >; org.apache.struts.tiles.TilesRequestProcessor)
    >; >;
    >; >; After reading old emails concerning the subject, I've learned that this
    is
    >; >; due to weblogic restrictions that require context attributes to be
    >; >; serializable.
    >; >;
    >; >;
    >; >; Is there any workaround to this problem? will it be solved  ?
    >; >;
    >; >; ---------------------------------------------------------------------
    >; >; To unsubscribe, e-mail: [EMAIL PROTECTED]
    >; >; For additional commands, e-mail: [EMAIL PROTECTED]
    >;
    >;
    >; ---------------------------------------------------------------------
    >; To unsubscribe, e-mail: [EMAIL PROTECTED]
    >; For additional commands, e-mail: [EMAIL PROTECTED]
    >;
    >;

    ---------------------------------------------------------------------
    To unsubscribe, e-mail: [EMAIL PROTECTED]
    For additional commands, e-mail: [EMAIL PROTECTED]

     

    November 16

    Conclusion

        最近几个月试用了好几个新的软件,IBM RSA,MyEclipse 5.5 or above,Loadrunner,Weblogic9 and 10 和一些Code generator 。经历了好几次J2EE app server版本和JVM的切换。
        整体的感觉确定今后的发展,别说太虚的,在工业级的项目不同于学术研究,要不断寻找并利用好的code generator来减少团队的代码量(我已经找到一些成果,可以将7 or above 人天的代码量在一定前提下缩短到 5min 人),
    1.团队中经验缺乏的成员可以通过这些代码去学习,
    2.稍有经验的成员应将精力放在app server的tuning和deploy上,
    3.有专门的测试人员去利用loadrunner这个很重要的工具,如果说代码只是为了implement functions,那么LR就是让我们的成果更完美,最终要实现LR和weblogic, OS之间的监控关系。
    4.更有经验的成员应该使用RSA建立整个系统从Use Case到数据库ER的关系,统领全局,
    5.而最后说到的是PM,调配资源和团队建设,为团队利益争取最大化(这世界还是很现实的,没有物资基础何来说精神)。
    希望自己能在有限的时间实现这个架构,on the way now。

    FW:Loadrunner monitor weblogic

    Installation Overview

    LoadRunner provides two different ways to monitor a WebLogic server depending upon the WebLogic version, i.e. SNMP-based monitor, or JMX monitor.

    WebLogic Monitor (SNMP-based monitor)

    WebLogic monitor (SNMP- based) gathers measurement based on information returned by the WebLogic SNMP agent. 

    ·        Availability: LoadRunner 6.0

    ·        Supported Server Version: WebLogic 5.x

    ·        Supported Server Platform: Windows NT, Windows 2000

     

    WebLogic Monitor (JMX monitor)

    WebLogic monitor (JMX) gathers measurement based on Java API. It uses the JMX interface, (which is a Sun extension to Java.

    ·        Availability: LoadRunner7.02 or above

    ·        Supported Server Version: WebLogic 6.x –7.x. For WebLogic8.x, please refer to the additional setup information below .

    ·        Supported Server Platform: Windows NT, Windows 2000, Solaris 2.6, AIX 5.1, HP-UX 11

    WebLogic Monitor (SNMP-based monitor)

    Installation guide

    The WebLogic (SNMP) monitor uses SNMP to retrieve server statistics. To use this monitor, you must make sure that a version prior to WebLogic 6.0 is installed on your server, and that the SNMP agent is installed and activated on the server.

    How to start the Bea Web Server

    1.      Go to the WebLogic directory.

    2.      Save the startWebLogic.cmd file as startWebLogic.bat.

    3.      Open startWebLogic.bat and set the JDK_HOME parameter to <JDK installation>.

    4.        Run startWebLogic.bat from the Command Prompt and wait a couple of minutes – if it starts OK, you will receive a “WebLogic started” notification.

    How to start the SNMP agent on the server

    1.      Make sure that the standard SNMP agent is not running – to verify this, go to Control Panel ® Services and check the status of SNMP and SNMP Trap or consult the UNIX admin for the SNMP daemon on the Unix machine.

    2.      For the Windows platform, Open startSnmpAgent.cmd or startSnmpAgent.bat and set the JDK_HOME parameter to <JDK_installation_directory>.

     For the UNIX platform, the batch file is startSnmpAgent.sh.

    3.     In the same file (startSnmpAgent.bat or startSnmpAgent.sh), search for the following line (usually the last line in file):

    “%JDK_HOME%\bin\java -classpath %JAVACLASSPATH% weblogic.SNMPAgent -password ServerSystemPassword -serverURLs t3://localhost:7001 -trapDestinations localhost:162”

    ·        This is the command use to startup the WebLogic SNMP agent.

    ·        It requires a Java Virtual Machine for execution.

    ·        The classpath must contain weblogicaaux.jar and \weblogic\classes. For Weblogic 5.1 with SP, you would need to add the sp jar file (usually named weblogic510spxxx.jar)to the CLASSPATH of the agent startup scrīpt.

    4.      Replace ServerSystemPassword with the password defined during server installation.

    5.      If you do not know your password, it is in the “weblogic.properties” file under the property “weblogic.password.system=???.”

    6.      You will probably need to change “localhost” to the name of your machine.

    7.      Run startSnmpAgent.bat from the Command Prompt.  If it starts OK, you will receive a “Agent Initialization Complete” message.

     

    NOTE:

    1.      For detailed instructions on installing the WebLogic SNMP agent and the utilities to test the agent, see http://www.weblogic.com/docs51/admindocs/snmpagent.html.

    2.      If you intend to run the WebLogic Server SNMP agent as the only agent on the system, you may not be able to start it if any other agent is already running and is bound to the SNMP port (161).

    How to configure the SNMP-based monitor in LoadRunner

     

    1.      Click the WebLogic (SNMP) graph in the graph tree, and drag it into the right pane of the Run view.

    2.      Right-click the graph and choose Add Measurement(s), or choose Monitors à Add Online Measurement.

    3.      In the Monitored Server Machines section of the WebLogic (SNMP) ( or WebLogic) dialog box, click Add to enter the server name or IP address of the machine you want to monitor. Select the platform on which the machine runs, and click OK.

    4.      In the Resource Measurements section of the WebLogic (SNMP) dialog box, click Add to select the measurements that you want to monitor. The WebLogic SNMP Resources dialog box displays the available measurements.

    5.      Browse the WebLogic SNMP Objects tree.

    6.        To measure an object, select it, and click Add. The following tables describe the measurements and server properties that can be monitored

     

     

     

    Known Issues and limitations

     

    1.      The SNMP-based monitor can only monitor up to 25 measurements.

     

    2.      Some network devices between the LoadRunner Controller machine and the SNMP agent machine might be configured to block or reroute the SNMP traffic. 

    Tips and Tricks

    Q.   LoadRunner 6.51 Controller crashes if the SNMP agent is unavailable

    R.     This is a known issue in LoadRunner 65 SP1.  To resolve the issue, please download and apply Patch LR651P34 from Support’s Download à Patches à LoadRunner à 6.5 SP1 à LR651P34 - LoadRunner 6.51 Fixed Controller crashes caused by unavailability of the SNMP or WebLogic server

     

    Q.   How to monitor a non- Community String

    R.     To do so, please modify the snmp.cfg located in <LoadRunnner >\dat\monitors:

    1.      Look for the appropriate monitor.

    2.      Uncomment the "SNMP_community_name=" line by removing the semi-colon (";").

    3.      Add the community string setup by the SNMP agent, to the end of “SNMP_community_name=;”. Please note that this is case-sensitive.

    4.      Save the snmp.cfg file and restart the LoadRunner Controller.

     

    Q.   How to change the port number

    R.     To do so, you need to modify the snmp.cfg file in <LoadRunner>\dat\monitors.

    1.         Look for the appropriate monitor.

    2.         Uncomment the  "port=" line by removing the semi-colon (";").

    3.           Add the port number to the end of “port=”. For example, port=1234

     

    Q.   What to do if there is a firewall between Controller and Host

    For monitoring over firewall, please refer to Knowledge Base Article 3678

     

     

    Q.   Error: “Not a scalar MIB object”

    R.     You receive this error because you are trying to access a private/ proprietary MIB file.  LoadRunner does not recognize this file, as it is not in LoadRunner’s MIB definition file.

     

     WebLogic Monitor (JMX monitor)

    Installation Requirement

    1.      WebLogic 6.0 or above on the server

    2.      JDK 1.3.x or above installed on the Controller machine. For WebLogic8.x, you need JDK1.4.

    3.      Copy WebLogic.jar from <server installation>\lib folder to <LoadRunner>\classes

    4.      LoadRunner 7.02 or above:

    a.       No patches is required for LoadRunner 7.5 or above

    b.      For LoadRunner 7.02:

    ·  Contact Mercury Customer Support for patch LR702P34 - LoadRunner 7.02 WebLogic JMX monitor for versions 6.0 & 6.1

    ·  To install:

     

    i.         Exit LoadRunner Controller.

    ii.       Unzip weblogic60_702.zip in the LoadRunner installation directory.

    iii.      Terminate the Java Web server by entering the URL 

    http://localhost:1112/?id=exit&type=0 in a browser.

    iv.     Run patch_monitors_v702.bat in <LoadRunner>\bin

    v.       Install Java Runtime by executing j2re-1_3_1-win.exe.

     

    How to configure the WebLogic (JMX) Monitor in LoadRunner

    1.      Click the WebLogic (JMX) graph in the graph tree, and drag it into the right pane of the Run view.

    2.      Right-click the graph and choose Add Measurement(s), or choose Monitors à Add Online Measurement.

    3.      In the Monitored Server Machines section of the WebLogic (JMX) dialog box, click Add to enter the server name or IP address of the machine you want to monitor. Enter the server name or IP address according to the following format:

    <server name>:<port number>  

    For example: mercury:8111. Select the platform on which the machine runs, and click OK.

    4.      Click Add in the Resource Measurements section of the WebLogic (JMX) dialog box. In the Enter Login Information dialog box, enter the username and password of a user with administrative privileges to the WebLogic server. The BEA WebLogic Monitor Configuration dialog box opens. For details on creating user permissions, see

    5.      Browse the Measured Components tree.

    6.      Check the required performance counters in the BEA WebLogic Monitor Configuration window's right pane.

    7.        Click OK in the BEA WebLogic Monitor Configuration dialog box, and in the WebLogic (JMX) dialog box, to activate the WebLogic (JMX) monitor.

    June 01

    Memory in HKU

    Today, I browsed the friend list in msn. suddenly, some strange feeling comes when I saw the group named "HKU". Open it and found many old friends. Gai, Fenado and Jolin, my dear friends who lived with me, miss the days with you. nights we struggle with homework ,went to have meals together, and discuss many topics. all of you are irreplaceable cauz' you are so sincere to me. Autumn Sea and Sheng , you two guys are rather interested. I own you one meal and drink together. Autumn Sea, I am so sorry to waste those beers you bought last time. whenever you like, come here and find me to make it true. Mei, remember your attitude as the tutor and classmates, you are a consciencious ppl. Thank you for your guide and effort.Well, last one is Charles, I am glad to know you before graduate, I just feel sorry that moment is so late that I even don't have many times to learnt from you.
     
     
    May 31

    life after return to a job

    In the past two months, I went back the this old office and worked with those guys, feels so far so good. Lots of work, including projects and new function modules. I prefer to cheat them as the chances to implement my new skill and idea , show off my power rather than the burden. Well, that makes me feel more comfortable and happy. The damn disaster in Si Chuan let numerous childen lost their parents, house , even life. If possible, I want to be their teacher in one day , that is all I can do except for the donation. What is more, I finished the evaluation and am qualified.It is my turn to make the decision whether to apply for it.Em...., that is difficult. Maybe I should cheat it easy, things are changing.
    Finally, Lakers won the western champion and return to the final. God bless Kobe.
    March 29

    开始

    时隔差不多2年,又回到了之前的终点。对于这个决定,肯定引起了很多好友的惊奇和非议,可我知道自己的原因和打算,也
    放弃去一些地方从事Leader的机会。
     
    希望以后的时间能证明一切。不过又能和一群好友共同战斗,这是比较开心的。
    March 19

    脑子开窍了

    自己感觉突然想东西更加成熟了。
    March 05

    回忆

    最近发生了比较多的事,让自己对一些东西产生了怀疑。下午突然想起做FYP时自己很confused的那晚Charles给我的一个电话。恩,我得像给Rocky的那封信一样,很多事不是绝对的。
    February 28

    被点名了

    规则:这是圈内流行很久的击鼓传花的游戏,传给谁谁就得接着,否则就得挨罚。请认真对待,不要怕暴露隐私。下面是我的回答,去掉答案就是留给你们的作业答完后要发表在自己的页面上,且要在标题上注明是谁点了你,你答完后加三道问题,再传给另外7 个朋友答,而且要去他们的页面告诉他(她),不可以回点。
     
    1.如果看到自己最爱的人熟睡在你面前你会做什么?  让她睡,别吵她
    2.写首自己最最喜爱的歌?  I believe I can Fly
    3.当你最不知道穿什么颜色的时候,你会选择什么颜色? 黑色
    4.2007年你最后悔的一件事是什么? 太过于依赖人
    5.曾经有过最被感动的事是什么? 父母和我说:你喜欢怎样我们都支持你
    6.比较喜欢爸爸还是妈妈?  妈妈
    7.你最想要的5样东西:  一家人身体健康,大家开心,开心又挑战的工作,一间房子,爱我的人
    8.最后一次发自内心的笑是什么时候:  忘了
    9.如果给你一个机会去世界上任何一个地方旅行:  不知道说什么
    10.如果时间能倒流你希望回到哪一天:  回到每次犯错的前一天
    11.你心目中理想的爱人是什么样子呢? 关心体贴
    12.最想实现的三个愿望是什么?  事业有成,家庭开心 (没了,我是不是不贪心)
    13.我在你眼里什么样?有时候傻乎乎的小妹妹
    14.如果让你拥有一种超能力,你愿意拥有什么呢?为什么?像超级赛亚人一样变身,觉得很cool
    15.最喜欢哪部电影?《Matrix》
    16.与喜欢的人见面,想要穿成什么样? 不知道,穿什么都那么OK。哈哈
    17.暗恋别人的感受是什么?  无奈
    18.精神出轨严不严重?  Sure
    19.对于初恋的那个人 ,如果再次见面,现在会有什么样的感觉呢?  时间过得真快
    20.你很努力守护的那个人无视你的存在,怎么办呢?离开还是继续 离开
    21.没有爱情的人生可怕吗 可能可怕吧。
    22.最近的生活中心是什么 ? 找寻职业生涯
    23.你不喜欢一个人,可是他让你给他一个机会,你会怎么办?不喜欢还给他机会,那简直是慢性谋杀
    24.你认为爱情和事业哪个更重要?  都重要。
    25.有孩子了么? 没有
    26.现在有喜欢的人吗?怎么认识的? 有,就是这样认识的
    27.失恋了么?没有,因为自己没把握的事不会去做(其实比较后悔)。 
    28.觉得哪个国家的语言最好听?中国话
    29.中国将来的政治体制会向什么方向发展? 共产主义万岁!
    30.看到上一题有没有想抽人的冲动? 没有。
    31.最擅长? 吃东西
    32.希望在哪里结婚? 随便
    33.咖喱味大便和大便味咖喱你选哪样?(必选题)  大便味咖喱。
    34.假如你可以收回一句话,会是哪句? 不知道,因为太多了。
    35.最喜欢爆的粗口 : XXXX
    36.你可以佩戴一样首饰,戴在哪儿?脖子 
    37.你是宁愿赤身裸体地面对我,还是愿意把自己的心声告诉我? 心声
    38.某一天你和自己的爱人吵架了,后来发现自己无理取闹了,你会怎么做?(女士做答)  
    39.某一天晚上和朋友们去酒吧喝酒,饮多了,晕晕中,遇到一位心仪的对象,相聊甚欢,你是选择留下联系方式继续发展,还是选择one night stand?
        如果单身就前者,否则就都不是,回家睡觉。
    40.2008年股市是熊是牛?  我能知道这个,我还用在这里回答你的问题?我秒秒钟几十万上下!
    41.你接受办公室恋情么? 最好不要,那很惨,人生失自由。
    42.是否排斥奉子成婚? 排斥
    43.今天最开心的是什么事情?听到所有的事情都有了新的转机
    44.如果你不想去做一件事情,但是又不得不去做,怎么办? 郁闷地去做
    45.如果发生了误会,你会怎么做呢? 解释 
    46. 最近最喜欢读什么书? 面试的书
    47.最近想去哪里旅行? 最近走不开
    48.最近有什么小愿望? 所有预计的东西都实现
    49.如果生宝宝,你是喜欢男孩还是女孩?男孩
    50.现在和你一起的人,是你最爱的吗? 肯定。
    51.如何看待婆媳关系?一门艺术。
    52.如果可以选择,你会在25岁前结婚还是在30岁后结婚? 30以后
    53.最低沉的时候,你会怎么鼓励自己? 事情会好得,去找自己开心的事去做
    54.你觉得人生是应该忘记还是应该铭记? 忘记不开心的,铭记别人的好

    为了让其他人不那么烦,这条龙就断在我这里吧!

    转机

    Everything maybe change.
    February 26

    等待

    别急,别急。是你的终归会来的。
    BTW: FW Charles的blog中Einstein一句话:
    If A is a success in life, then A equals x plus y plus z. Work is x; y is play; and z is keeping your mouth shut.
    February 19

    美好时光

    Graduate到Working again这段时间,比较空闲,学会了做很多吃的,以后自己在外生活的时候能自足自养,心里也纳闷,难道老天以后我要过两地生活。管他呢,
    多一项能力多一点竞争力吧,哈哈。看看书,挺好的。
    February 06

    Plan in 2008

    Finally,I graduated from HKU in Jan. Firstly, I should get a good job to develop my career. And then decide to buy a department or car, in my opinion , the former is the first choice. Further, I should take good care of my stocks to get a better benefit than 2007. Remember, just believe in yourself.
    December 12

    FYP Report finish

    做个记号以示纪念

    December 08

    不服气

    就是不服气,我就跟你耗上了,这辈子不做到不罢休。

    December 05

    心情曲线

    人的心情随着人生就如同一条曲线,有波峰也有谷底。何不在心理上用波峰填补谷地,达到相对的平稳。

    upset

    凡事多途径准备,别对任何一件事投入所有的期望。