J'ai un problème d'IPC avec JBoss Portal.
J'essaye de transmettre par event un objet serializable qui me sert aussi pour la persistance via hibernate.
Et quand je transmets l'event, j'ai l'erreur suivante :
Cause: java.lang.IllegalArgumentException: The provided event value type fr.natoine.annotations_persistence.selection.SelectionHTML does not have a valid jaxb annotation
Message: The provided event value type fr.natoine.annotations_persistence.selection.SelectionHTML does not have a valid jaxb annotation
Ma classe SelectionHTML :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
@Entity
public class SelectionHTML extends Selection 
{
	@Column(name = "SELECTIONHTML_CONTENT")
	private String content;
 
	public String getContent() {
		return content;
	}
 
	public void setContent(String content) {
		this.content = content;
	}
}
Ma classe Selection dont hérite SelectionHTML :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
@MappedSuperclass
@Table(name = "SELECTION")
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
public abstract class Selection implements Serializable
{
		@Id @GeneratedValue
	    @Column(name = "SELECTION_ID")
	    private Long id;
		@Column(name = "SELECTION_URL_SOURCE")
		private String url_source;
		@Column(name = "SELECTION_BEGIN")
		private String begin;
		@Column(name = "SELECTION_END")
		private String end;
 
		public Selection(){};
 
		public Long getId() {
			return id;
		}
		public String getUrl_source() {
			return url_source;
		}
		public void setUrl_source(String urlSource) {
			url_source = urlSource;
		}
		public String getBegin() {
			return begin;
		}
		public void setBegin(String begin) {
			this.begin = begin;
		}
		public String getEnd() {
			return end;
		}
		public void setEnd(String end) {
			this.end = end;
		}
}
Ma déclaration d'event dans portlet.xml :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
<event-definition>
		<qname>annotation-selection</qname>
		<value-type>fr.natoine.annotations_persistence.selection.Selection</value-type>
	</event-definition>