geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ashish Jain <ashja...@gmail.com>
Subject Discussion: Possible fixes for GERONIMO-5180
Date Fri, 12 Mar 2010 08:48:13 GMT
Hi ALL,

I have opened up a JIRA GERONIMO-5180 on the unlockKeystore command failure
if keystore is created with keytool.exe. I was trying to fix this issue
which requires some changes in the class declaration or interface. Following
code is being utilized to fix up the issue
KeystoreInstance[]
keystores=(KeystoreInstance[])kernel.getAttribute(abstractName,"keystores");
where  abstractName is obtained through
"org.apache.geronimo.management.geronimo.KeystoreManager". However I hit the
following exception:

java.rmi.UnmarshalException: error unmarshalling return; nested exception
is:
        java.io.WriteAbortedException: writing aborted;
java.io.NotSerializableE
xception: org.apache.geronimo.security.keystore.FileKeystoreInstance
        at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:172)
        at com.sun.jmx.remote.internal.PRef.invoke(Unknown Source)
        at
javax.management.remote.rmi.RMIConnectionImpl_Stub.invoke(RMIConnecti
onImpl_Stub.java:400)
        at
javax.management.remote.rmi.RMIConnector$RemoteMBeanServerConnection.
invoke(RMIConnector.java:984)

There are 2 ways to fix this up.

1) Make the class org.apache.geronimo.security.keystore.FileKeystoreInstance
serializable.
2) add a new variable in FileKeystoreManager and add a new method in
KeystoreManager which does not return anything and just gives a call
to getKeystores(). For example getKeystores1() as the new method in
KeystoreManager and a new variable as keystores1.

I shall prefer #2 over #1 as it should not have any effect on existing
functionalities.

Suggestions/advice/comments??

Thanks
Ashish

Mime
View raw message