[JBoss Seam] - @Begin issue. Cannot make it work how we need
by anescu
Hi,
So, I have a generated Seam app, and we have placed a combo box and a button on top, near the "login" part (inside the loginout.xhtml file).
The button calles a method, which has the @Begin annotation.
After I login, I choose a value from the drop down and press the Change button. This will place some objects on the Conversation context.
i also removed the propagation="none" from the s:link elements, so now i can move around with the setted values. But if I change the value for the second time I get an exception about calling begin from inside a conversation, with hint that I should use (join=true).
So, here is what needs to work, and what is happening:
I need to allow the objects that are placed on context to exist in 2 different conversations, that is, if the user logs in, and sets the values from the combo to X & Y, and then opens a likn in another tab/browser, having the same session, he should be able to select from the combo a different option and work in both browsers concurently, with different values placed on the conversation context.
But, this is what I get:
1) If I place @Begin on the method that is called from the interface when changing the value, when I change the combo value from either of the windows I get an error, with the above hint.
2) If I use @Begin(join=true), then both windows will use the same conversation, that is, if I change from the combo in window 1 and then navigate somewhere else in window 2, the values from the conversation context will have the same values as those set in window 1
3) If I use for example this code, then it's like @Begin is not called:
//method called to change the value.
| @End
| public void changeSelected()
| {
| doStuff();
| }
|
|
| //method called from first one.
| @Begin
| public void doStuff()
| {
| //...
| }
4) The same if i use this to close the existing conversation and start a new one:
//method called to change the value.
| @End
| @Begin
| public void changeSelected()
| {
| doStuff();
| }
|
|
| //method called from first one.
| public void doStuff()
| {
| //...
| }
Am I missing something here? How do I end the conversation only when I want to change the value???
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045059#4045059
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045059
19 years, 1 month
[Beginners Corner] - hostname
by kuvera
My JBoss 4.2.0 CR2 is bound to address 0.0.0.0 because I need access from localhost, as well as from the internet. Actually I now have two such environments: a windows for development, and a linux for production.
I have EJB's deployed.
jndi.properties for the clients points to the FQ domain name of the server, on the standard port 1099.
Client program to EJB communication fails because RMI on the remote client obviously uses the server's simple one-word hostname instead of its FQDN. How do I get around this?
anonymous wrote :
| javax.naming.CommunicationException [Root exception is java.rmi.UnknownHostException: Unknown host: kuvera; nested exception is:
| java.net.UnknownHostException: kuvera]
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:722)
| at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:587)
| ...
| Caused by: java.rmi.UnknownHostException: Unknown host: kuvera; nested exception is:
| java.net.UnknownHostException: kuvera
| at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:572)
| at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:185)
| ...
| Caused by: java.net.UnknownHostException: kuvera
| at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
| at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:430)
| ...
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045058#4045058
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045058
19 years, 1 month