|
From: <cle...@jb...> - 2006-07-10 19:05:08
|
I need some way to reproduce your issue, preferably something only using plain serialization. Things that would change default behavior on serialization (to help you identify some pattern) - readResolves - private write or readObject - non serializable classes not implementing default constructor - adding something not supposed to be in the serialization tree (like socket or connection) View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956707#3956707 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956707 |
|
From: rpa_rio <do-...@jb...> - 2006-07-10 19:13:15
|
I found this on the log: DEBUG: describeObject::Calling writeReplace for br.gov.go.tj.execpen.entidades.Cidade$$EnhancerByCGLIB$$652dbb34 I'll investigate a little more. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956711#3956711 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956711 |
|
From: <cle...@jb...> - 2006-07-10 19:20:28
|
What I meant was... you could reproduce a JbossSerialization failure by just playing with your classes, without having to play with MyFaces in a testcase at al. I will be able to fix this for you, as long as you create the testcase. Clebert PS: If you want to send me this in private it's okay. (I also speak Portuguese BTW as I'm brazilian). In case you do let me know if I can include it as part of the testcases, or if it's something confidential for you. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956716#3956716 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956716 |
|
From: rpa_rio <do-...@jb...> - 2006-07-10 19:25:49
|
Clebert, I'm almost sure that Cidade class reach this point as null reference: (ObjectDescriptorFactory.java, line 191) metaData = ClassMetamodelFactory.getClassMetaData(obj.getClass(),cache.isCheckSerializableClass()); View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956720#3956720 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956720 |
|
From: <cle...@jb...> - 2006-07-10 19:30:37
|
I need to know what caused it. A regular null reference should be treated without any problem. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956722#3956722 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956722 |
|
From: rpa_rio <do-...@jb...> - 2006-07-10 19:50:56
|
This is my Cidade.java:
package br.gov.go.tj.execpen.entidades;
import java.io.Serializable;
public class Cidade implements Serializable
{
static final long serialVersionUID = 1l;
private Integer codigo;
private String nome;
private String uf;
public Cidade() {
}
public Integer getCodigo() {
return(codigo);
}
public void setCodigo(Integer codigo) {
this.codigo = codigo;
}
public String getNome() {
return(nome);
}
public void setNome(String nome) {
this.nome = nome;
}
public String getUf() {
return uf;
}
public void setUf(String uf) {
this.uf = uf;
}
}
and when the error happens all fields are null.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956731#3956731
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956731
|
|
From: rpa_rio <do-...@jb...> - 2006-07-10 20:01:28
|
Clebert, Sorry, i checked here and this is a Hibernate related issue that was causing that error. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956737#3956737 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956737 |
|
From: <cle...@jb...> - 2006-07-10 20:03:13
|
The problem won't be on Cidades. The problem will be on the class holding Cidades. Again... can't you send me the whole thing in private? clebert.suconic at jboss.com I won't of course publish anything. Clebert View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956738#3956738 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956738 |
|
From: <cle...@jb...> - 2006-07-10 20:06:16
|
"rpa_rio" wrote : Clebert, | | Sorry, i checked here and this is a Hibernate related issue that was causing that error. | now that I spent some time on it I'm curious... :-) Can you point me what's the issue? View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956742#3956742 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956742 |
|
From: rpa_rio <do-...@jb...> - 2006-07-10 22:05:43
|
Well, i have two methods on Hibernate that loads a persistent instance from database, the first method Session.load that i was using retrieve an existing persistence instance but this isn't appropriate in case where i need check if the instance exists in database. So, when i use this method and the instance doesn't exists in database, then i get a instance with null values in all instance fields and this was causing the error on jboss serialization. Now i'm using Session.get, this method returns null if the instance doesn't exists in database and when jboss serialization executes the code everything works fine because you do some checks about null pointers. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3956799#3956799 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3956799 |