users@glassfish.java.net

Re: Injection into WebStart Client not working?

From: <glassfish_at_javadesktop.org>
Date: Sun, 23 Mar 2008 05:52:18 PST

Hi, Markus.

Although I do not have exactly the same software running on my system that you have, I was able to reproduce exactly the same problem with your code.

Because the client will be remote from the EJB module at runtime, the EJB module needs to define the remote interface for the SLSB and the client needs to refer to that remote interface.

For example, I added this to the EJB module:

@Remote
public interface StatisticsServerRemote {

    double average(final double x, final double y);
 }

and changed the SLSB implementation to implement this remote I/F:

public class StatisticsServer [b]implements StatisticsServerRemote[/b]

Then I changed the client to use this:

    @EJB
    private static StatisticsServer[b]Remote[/b] statisticsServer;

With those changes your example worked for me.

Can you try this and let us know if this resolves the problem?

- Tim
[Message sent by forum member 'tjquinn' (tjquinn)]

http://forums.java.net/jive/thread.jspa?messageID=265362