Non-serializable attribute with name javax.zkoss.zk.ui.Session

The error:

java.lang.IllegalArgumentException: setAttribute: Non-serializable attribute with name javax.zkoss.zk.ui.Session

The solution:
**edit zk.xml, add


Glassfish 4.0 – SEVERE:   SEC5054: Certificate has expired

When I start Glassfish 4.0 from inside NetBeans IDE 7.4, I got this output

SEVERE:   SEC5054: Certificate has expired: [
  Version: V3
  Subject: CN=GTE CyberTrust Root 5, OU="GTE CyberTrust Solutions, Inc.", O=GTE Corporation, C=US
  Signature Algorithm: SHA1withRSA, OID = 1.2.840.113549.1.1.5
  Key:  Sun RSA public key, 2048 bits
  modulus: 237418898293472616608124373663877543854434319738611148654904141538840503317458119
  public exponent: 65537
  Validity: [From: Fri Aug 14 21:50:00 ICT 1998,
               To: Thu Aug 15 06:59:00 ICT 2013]
  Issuer: CN=GTE CyberTrust Root 5, OU="GTE CyberTrust Solutions, Inc.", O=GTE Corporation, C=US
  SerialNumber: [    01b6]
Certificate Extensions: 4
[1]: ObjectId: Criticality=true
[2]: ObjectId: Criticality=false
CertificatePolicies [
  [CertificatePolicyId: [1.2.840.113763.]
[]  ]
[3]: ObjectId: Criticality=true
KeyUsage [
[4]: ObjectId: Criticality=false
SubjectKeyIdentifier [
KeyIdentifier [
0000: 76 0A 49 21 38 4C 9F DE   F8 C4 49 C7 71 71 91 9D  v.I!8L....I.qq..
  Algorithm: [SHA1withRSA]
0000: 41 3A D4 18 5B DA B8 DE   21 1C E1 8E 09 E5 F1 68  A:..[...!......h
0010: 34 FF DE 96 F4 07 F5 A7   3C F3 AC 4A B1 9B FA 92  4.......<..J....
0020: FA 9B ED E6 32 21 AA 4A   76 C5 DC 4F 38 E5 DF D5  ....2!.Jv..O8...
0030: 86 E4 D5 C8 76 7D 98 D7   B1 CD 8F 4D B5 91 23 6C  ....v......M..#l
0040: 8B 8A EB EA 7C EF 14 94   C4 C6 F0 1F 4A 2D 32 71  ............J-2q
0050: 63 2B 63 91 26 02 09 B6   80 1D ED E2 CC B8 7F DB  c+c.&...........
0060: 87 63 C8 E1 D0 6C 26 B1   35 1D 40 66 10 1B CD 95  .c...l&.5.@f....
0070: 54 18 33 61 EC 13 4F DA   13 F7 99 AF 3E D0 CF 8E  T.3a..O.....>...
0080: A6 72 A2 B3 C3 05 9A C9   27 7D 92 CC 7E 52 8D B3  .r......'....R..
0090: AB 70 6D 9E 89 9F 4D EB   1A 75 C2 98 AA D5 02 16  .pm...M..u......
00A0: D7 0C 8A BF 25 E4 EB 2D   BC 98 E9 58 38 19 7C B9  ....%..-...X8...
00B0: 37 FE DB E2 99 08 73 06   C7 97 83 6A 7D 10 01 2F  7.....s....j.../
00C0: 32 B9 17 05 4A 65 E6 2F   CE BE 5E 53 A6 82 E9 9A  2...Je./..^S....
00D0: 53 0A 84 74 2D 83 CA C8   94 16 76 5F 94 61 28 F0  S..t-.....v_.a(.
00E0: 85 A7 39 BB D7 8B D9 A8   B2 13 1D 54 09 34 24 7D  ..9........T.4$.
00F0: 20 81 7D 66 7E A2 90 74   5C 10 C6 BD EC AB 1B C2   ..f...t\.......

The solution that work on me, go to folder “glassfish4/glassfish/domains/domain1/config” and then execute “keytool -delete -alias gtecybertrust5ca -keystore cacerts.jks -storepass [yourwish]”

NetBeans 7.0 Get CORBA and OMG

I use NetBeans IDE 7.0 running the default GlassFish Server 3.1 from the NetBeans installation file. I got this error :

WARNING: IOP00010002: Unknown user exception thrown by the server – exception: java.lang.NullPointerException; message: null
org.omg.CORBA.UNKNOWN: WARNING: IOP00010002: Unknown user exception thrown by the server – exception: java.lang.NullPointerException; message: null vmcid: OMG minor code: 2 completed: Maybe
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(

I have tried to find various solutions on the internet but no solution that could solve this issue.
OMG is Oh, My God?

When I try to trace, the code stop at

generic.persist (m);

. Not a single clue.

So, I tried to install another version of Glassfish, the version 3.0.1, my problem solved. Now I want to try downloading the GlassFish Server 3.1 which is separate from the NetBeans installation file.

Continue reading

Netbeans 7 – “Cannot locate java installation in specified jdkhome:”

I’ve installed previous versions of jdk1.6.0_17, and then after installing netbeans 7, I upgrade jdk to version jdk1.6.0_25.

Now, everytime I start Netbeans, it always show me this message :

Cannot locate java installation in specified jdkhome:
C:\Program Files\Java\jdk1.6.0_17
Do you want to try to use default version?

If I click “Yes”, the next time Netbeans started, the same message appear.


So to remove this, I change “netbeans.conf” in “C:\Program Files\NetBeans 7.0\etc”.

Change “netbeans_jdkhome” like this :

netbeans_jdkhome=”C:\Program Files\Java\jdk1.6.0_25″

then your Netbeans run as normal. ^_^

Elemen taglib in web.xml

When I validate web.xml, I got this error message :
XML validation started.
Checking file:/C:/temp/konoho/web/WEB-INF/web.xml…
cvc-complex-type.2.4.a: Invalid content was found starting with element ‘taglib’. One of ‘{“;:description, “;:display-name, “…..’ is expected. [685]
XML validation finished.

My previous web.xml





To fix this, add tag <jsp-config> , because <taglib>is not a direct sub-element of the tag <web-app>.





Different between download Binary and Source Code

I wonder what different between download Binary and Source, so after searching, here some diffs:

  • Source code is the set of instructions the programmer writes; it’s not in executable form until it’s compiled/linked into a binary or until it’s parsed by an interpreter. (There’s another possibility called “bytecode” which is a preparsed form that speeds up interpretation.)
  • Source code
    When you compile your source packages they are tailored much more to the system, and thus will give better performance, as it is more optimized for your system. It is also generaly smaller and doesn’t take up as much room on the hrd drive or your bandwidth.
    They can take a long time to compile all of the program. Also the dependancy issues can be slightly mor difficult to desipher.
  • Binary
    They are usually quick and easy to install, and some can resolve dependacy issues for you.
    They are big files, and take up more space. They are usually enabled with all the options on the install, and thus the file isn’t as well tailored for your system, andit will run slower (this is one of the reasons why source based distro’s like gentoo are so fast).

Open Netbeans with Two Instances / Windows Simultaneously

I need to open two projects, so I can learn from demo project and to develop my new project. But when I click Netbeans shortcut for the second times, Netbeans not display as another instance/window. To overcome this,
1. Click Netbeans menu, “Help” | “About”, look for “Userdir” parameter to see user directory.
2. Create another user directory.
3. Copy the first Netbeans shorcut and paste it as second Netbeans shortcut.
4. Right click the second Netbeans shortcut, choose “Properties”.
5. See the field “Target”, the value of mine like this “C:\Program Files\NetBeans 6.7.1\bin\netbeans.exe”
6. Add Netbeans command line switch “–userdir “, so the value of “Target” field become like this "C:\Program Files\NetBeans 6.7.1\bin\netbeans.exe" --userdir C:\Users\wi\.netbeans\second