Servlet Communication with Java WebStart

Hi there,
we have an application that works fine with Java WebStart whenever we start it in a local area network. But from outside the LAN the application cannot communicate to it's servlets. I use the codebase IP address with the servlet runner's port (http://<codebase IP>:port/) as URL for servlet communication, but the application's request never reaches the servlets.
My question is now, if anyone had the same or a similar problem with servlet communication using Java WebStart, or if anyone knows, if that might be a problem with proxy configuration.
The servlet runner we use, is JServ from Sun (JSDK2.0) and the webserver where it is running on is not behind a firewall or a proxy, but the client PC with the web start application is.
Thanks,
Katja

Thank you for your early reply. But I think, that's not the problem.
I get no security error and the webserver is identified the same way it is in the jnlp file. Also my application is not running in the Sandbox. My assumption is, that the http-request to the servlet does not go through the proxy server between my PC and the PC the servletrunner is running on.
I wonder if I have to configure my application to use a proxy server for communication with the servlets instead of the direct http-request to the servlet runner?

Similar Messages

  • Servlet communication with Java App.

    Hi currently I am working on a project in which with the current design I have to implement a servlet, which can communicate to other servlets and/or Java applications via calling their methods. I know that RMI would be ideal for this however, I do not want to have to setup or configure anything on the server end. Another approach I thought of was to extend the abilities of the servlet and Java app to communicate at the "socket" level, however this can cause issues when communicating through a firewall , I am sure there are workarounds. The last thing that I thought of was having the servlet and application communicate via the HTTP protocol and using HTTPMessage to pass arguments. This approach seems to be the easiest but I would have rather liked to access the Object methods of the two applications rather than send args back and forth. Again as mentioned technologies like RMI and CORBA would probably benifit me. While I don't know too much about CORBA I do know that RMI would require administration work which I would not like to deal with mostly b/c of paperwork and red tape.
    Any advice would be appreciated.
    thank you,
    Peyman m.

    HI,
    I think if your client is RMI, then you need to have RMI server running to answer that client.
    While here you have servlet as your server side component. So, I think in its orginal form servelet can not reply to RMI implelemnted client.
    The best approach I feel for the situatioin described by you is using java based HTTP classes.

  • Sir i am using datasocket read ,i am communicating with java but my problem is that bcz im using while loop to see if value has changed my labview consumes all the processors time ,sir i want a event like thing so that while loop is not in continuous loop

    sir i have given lot of effort but i am not able to solve my problem either with notifiers or with occurence fn,probably i do not know how to use these synchronisation tools.

    sir i am using datasocket read ,i am communicating with java but my problem is that bcz im using while loop to see if value has changed my labview consumes all the processors time ,sir i want a event like thing so that while loop is not in continuous loopHi Sam,
    I want to pass along a couple of tips that will get you more and better response on this list.
    1) There is an un-written rule that says more "stars" is better than just one star. Giving a one star rating will probably eliminate that responder from individuals that are willing to anser your question.
    2) If someone gives you an answer that meets your needs, reply to that answer and say that it worked.
    3) If someone suggests that you look at an example, DO IT! LV comes with a wonderful set of examples that demonstate almost all of the core functionality of LV. Familiarity with all of the LV examples will get you through about 80% of the Certified LabVIEW Developer exam.
    4) If you have a question first search the examples for something tha
    t may help you. If you can not find an example that is exactly what you want, find one that is close and post a question along the lines of "I want to do something similar to example X, how can I modify it to do Y".
    5) Some of the greatest LabVIEW minds offer there services and advice for free on this exchange. If you treat them good, they can get you through almost every challenge that can be encountered in LV.
    6) If English is not your native language, post your question in the language you favor. There is probably someone around that can help. "We're big, we're bad, we're international!"
    Trying to help,
    Welcome to the forum!
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Error with Java WebStart Signed Jars on 1.6.0_19's new Mixed  Code

    All,
    First, we have a valid code signing certificate/keystore from Thawte that works for signing webstart jars as of update 18. For some reason, if you run our webstart application on update 19 JRE, the runtime believes that some of the jars are not signed and some are. Even though we create and sign the jars in the exact same way and after inspecting the jar the JRE believes are not signed they have the necessary signing entries/files in the manifest folder. Not sure why the signing process would work for some of our jars and not for others. There is nothing really all that different.
    So, because the JRE believes some of the jars are not signed the new security warning "...contains both signed and unsigned code." pops up ( [Error Description|http://java.com/en/download/help/error_mixedcode.xml] ). If I press yes, then I get the following exception.
    java.lang.SecurityException: trusted loader attempted to load sandboxed resource from https://path-to-our.jar
         at com.sun.deploy.security.CPCallbackHandler$ParentCallback.check(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler$ParentCallback.access$1400(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler$ChildElement.checkResource(Unknown Source)
         at com.sun.deploy.security.DeployURLClassPath$JarLoader.checkResource(Unknown Source)
         at com.sun.deploy.security.DeployURLClassPath$JarLoader.getResource(Unknown Source)
         at com.sun.deploy.security.DeployURLClassPath.getResource(Unknown Source)
         at java.net.URLClassLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(Unknown Source)
         at com.sun.jnlp.JNLPClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at main.JwsMain.main(JwsMain.java:32)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at com.sun.javaws.Launcher.executeApplication(Unknown Source)
         at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
         at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
         at com.sun.javaws.Launcher.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)If I press "no" I get the following exception (I get this exception if I try to run our WebStart application with no signed jars as well, no warnings about missing certs, just straight to error)
    java.lang.NullPointerException
         at com.sun.deploy.cache.CachedJarFile.findMatchingSignerIndices(Unknown Source)
         at com.sun.deploy.cache.CachedJarFile.entryNames(Unknown Source)
         at com.sun.deploy.cache.DeployCacheJarAccessImpl.entryNames(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler.assertTrust(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler.access$700(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler$ParentCallback.check(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler$ParentCallback.access$1400(Unknown Source)
         at com.sun.deploy.security.CPCallbackHandler$ChildElement.checkResource(Unknown Source)
         at com.sun.deploy.security.DeployURLClassPath$JarLoader.checkResource(Unknown Source)
         at com.sun.deploy.security.DeployURLClassPath$JarLoader.getResource(Unknown Source)
         at com.sun.deploy.security.DeployURLClassPath.getResource(Unknown Source)
         at java.net.URLClassLoader$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(Unknown Source)
         at com.sun.jnlp.JNLPClassLoader.findClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at java.lang.ClassLoader.loadClass(Unknown Source)
         at main.JwsMain.main(JwsMain.java:32)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at com.sun.javaws.Launcher.executeApplication(Unknown Source)
         at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
         at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
         at com.sun.javaws.Launcher.run(Unknown Source)
         at java.lang.Thread.run(Unknown Source)Does anyone know why this would be happening? It only occurs with the new update. We use the same keystore and process for signing all of our jars so it really doesn't make since why some of them work and some of them don't. Also, our JNLP is correct or it wouldn't work in update 18.
    Edit: We've tried it on Windows XP SP3 and compiled the code using update 18 and used jarsigner both from 18 and 19 with same results.
    Edited by: chenthor on Apr 1, 2010 8:44 AM
    Edited by: chenthor on Apr 1, 2010 8:51 AM

    Hi All,
    So we've been battling this bug for a year or so now, and I've come up with a solution to the webstart bugs
    http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6967414
    http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6805618
    (see the bugs for more details)
    From what we can tell the bug stems from the way that the jar signers information is "cached" by webstart.
    When a jar is loaded by webstart, it is represented by a CachedJarFile instance. When loading and using classes the signature for the jar is verified. The signers used is the one that is stored in the CachedJarFile instances. These "signers" are stored as SoftReferences. SoftReferences are like WeakReferences, except that they only become eligible for garbage collection when there is a small amount of available heaps space remaining and that the object is only softly reachable. (That's a pretty crude description, but it will do for now)
    So what we found was happening is that when the JVM reached a certain heap size threshold and needed to allocate more heap, that these soft references (and hence the signers information) werebeing garbage collected. if you attempt to load a class after this you get the security error.
    So I came up with a hack to work around this. At application startup, iterate through all of the CachedJarFile objects on the classpath and create a hard reference to each of the signers info by putting them in a static list somewhere. From our tests this seems to work. (though with the intermittent nature of the problem, it has been hard to prove conclusively, though we've had some success repro-ing the issue, by reducing the intial heap size and using VisualVM to watch for heap expansions and forcing gc's)
    Below is the code for the hack, to run it just call JarSignersHardLinker.go() and it will do some sanity checks (running on webstart on java 1.6 update 19 or higher) before spawning a new thread to create hard refs for all signers info for all jars on the classpath.
    import java.io.IOException;
    import java.lang.ref.SoftReference;
    import java.lang.reflect.Field;
    import java.lang.reflect.InvocationTargetException;
    import java.lang.reflect.Method;
    import java.net.JarURLConnection;
    import java.net.URL;
    import java.net.URLConnection;
    import java.util.ArrayList;
    import java.util.Enumeration;
    import java.util.LinkedHashSet;
    import java.util.List;
    import java.util.Set;
    import java.util.jar.JarFile;
    * A utility class for working around the java webstart jar signing/security bug
    * see http://bugs.sun.com/view_bug.do?bug_id=6967414 and http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6805618
    * @author Scott Chan
    public class JarSignersHardLinker {
        private static final String JRE_1_6_0 = "1.6.0_";
         * the 1.6.0 update where this problem first occurred
        private static final int PROBLEM_JRE_UPDATE = 19;
        public static final List sm_hardRefs = new ArrayList();
        protected static void makeHardSignersRef(JarFile jar) throws java.io.IOException {
            System.out.println("Making hard refs for: " + jar );
            if(jar != null && jar.getClass().getName().equals("com.sun.deploy.cache.CachedJarFile")) {
                 //lets attempt to get at the each of the soft links.
                 //first neet to call the relevant no-arg method to ensure that the soft ref is populated
                 //then we access the private member, resolve the softlink and throw it in a static list.
                callNoArgMethod("getSigners", jar);
                makeHardLink("signersRef", jar);
                callNoArgMethod("getSignerMap", jar);
                makeHardLink("signerMapRef", jar);
    //            callNoArgMethod("getCodeSources", jar);
    //            makeHardLink("codeSourcesRef", jar);
                callNoArgMethod("getCodeSourceCache", jar);
                makeHardLink("codeSourceCacheRef", jar);
         * if the specified field for the given instance is a Softreference
         * That soft reference is resolved and the returned ref is stored in a static list,
         * making it a hard link that should never be garbage collected
         * @param fieldName
         * @param instance
        private static void makeHardLink(String fieldName, Object instance) {
            System.out.println("attempting hard ref to " + instance.getClass().getName() + "." + fieldName);
            try {
                Field signersRef = instance.getClass().getDeclaredField(fieldName);
                signersRef.setAccessible(true);
                Object o = signersRef.get(instance);
                if(o instanceof SoftReference) {
                    SoftReference r = (SoftReference) o;
                    Object o2 = r.get();
                    sm_hardRefs.add(o2);
                } else {
                    System.out.println("noooo!");
            } catch (NoSuchFieldException e) {
                e.printStackTrace();
                return;
            } catch (IllegalAccessException e) {
                e.printStackTrace();
         * Call the given no-arg method on the given instance
         * @param methodName
         * @param instance
        private static void callNoArgMethod(String methodName, Object instance) {
            System.out.println("calling noarg method hard ref to " + instance.getClass().getName() + "." + methodName + "()");
            try {
                Method m = instance.getClass().getDeclaredMethod(methodName);
                m.setAccessible(true);
                m.invoke(instance);
            } catch (SecurityException e1) {
                e1.printStackTrace();
            } catch (NoSuchMethodException e1) {
                e1.printStackTrace();
            } catch (IllegalArgumentException e) {
                e.printStackTrace();
            } catch (IllegalAccessException e) {
                e.printStackTrace();
            } catch (InvocationTargetException e) {
                e.printStackTrace();
         * is the preloader enabled. ie: will the preloader run in the current environment
         * @return
        public static boolean isHardLinkerEnabled() {
             boolean isHardLinkerDisabled = false;  //change this to use whatever mechanism you use to enable or disable the preloader
            return !isHardLinkerDisabled && isRunningOnJre1_6_0_19OrHigher() && isRunningOnWebstart();
         * is the application currently running on webstart
         * detect the presence of a JNLPclassloader
         * @return
        public static boolean isRunningOnWebstart() {
            ClassLoader cl = Thread.currentThread().getContextClassLoader();
            while(cl != null) {
                if(cl.getClass().getName().equals("com.sun.jnlp.JNLPClassLoader")) {
                    return true;
                cl = cl.getParent();
            return false;
         * Is the JRE 1.6.0_19 or higher?
         * @return
        public static boolean isRunningOnJre1_6_0_19OrHigher() {
            String javaVersion = System.getProperty("java.version");
            if(javaVersion.startsWith(JRE_1_6_0)) {
                //then lets figure out what update we are on
                String updateStr = javaVersion.substring(JRE_1_6_0.length());
                try {
                    return Integer.parseInt(updateStr) >= PROBLEM_JRE_UPDATE;
                } catch (NumberFormatException e) {
                    //then unable to determine updatedate level
                    return false;
            //all other cases
            return false;
          * get all the JarFile objects for all of the jars in the classpath
          * @return
         public static Set<JarFile> getAllJarsFilesInClassPath() {
              Set<JarFile> jars = new LinkedHashSet<JarFile> ();
             for (URL url : getAllJarUrls()) {
                 try {
                     jars.add(getJarFile(url));
                 } catch(IOException e) {
                      System.out.println("unable to retrieve jar at URL: " + url);
             return jars;
         * Returns set of URLS for the jars in the classpath.
         * URLS will have the protocol of jar eg: jar:http://HOST/PATH/JARNAME.jar!/META-INF/MANIFEST.MF
        static Set<URL> getAllJarUrls() {
            try {
                Set<URL> urls = new LinkedHashSet<URL>();
                Enumeration<URL> mfUrls = Thread.currentThread().getContextClassLoader().getResources("META-INF/MANIFEST.MF");
                while(mfUrls.hasMoreElements()) {
                    URL jarUrl = mfUrls.nextElement();
    //                System.out.println(jarUrl);
                    if(!jarUrl.getProtocol().equals("jar")) continue;
                    urls.add(jarUrl);
                return urls;
            } catch(IOException e) {
                throw new RuntimeException(e);
         * get the jarFile object for the given url
         * @param jarUrl
         * @return
         * @throws IOException
        public static JarFile getJarFile(URL jarUrl) throws IOException {
            URLConnection urlConnnection = jarUrl.openConnection();
            if(urlConnnection instanceof JarURLConnection) {
                // Using a JarURLConnection will load the JAR from the cache when using Webstart 1.6
                // In Webstart 1.5, the URL will point to the cached JAR on the local filesystem
                JarURLConnection jcon = (JarURLConnection) urlConnnection;
                return jcon.getJarFile();
            } else {
                throw new AssertionError("Expected JarURLConnection");
         * Spawn a new thread to run through each jar in the classpath and create a hardlink
         * to the jars softly referenced signers infomation.
        public static void go() {
            if(!isHardLinkerEnabled()) {
                return;
            System.out.println("Starting Resource Preloader Hardlinker");
            Thread t = new Thread(new Runnable() {
                public void run() {
                    try {
                        Set<JarFile> jars = getAllJarsFilesInClassPath();
                        for (JarFile jar : jars) {
                            makeHardSignersRef(jar);
                    } catch (Exception e) {
                        System.out.println("Problem preloading resources");
                        e.printStackTrace();
                    } catch (Error e) {
                         System.out.println("Error preloading resources");
                         e.printStackTrace();
            t.start();
    }

  • Can't find xml within jar with java webstart

    I use Jasper Reports,I am reading a xml file in my application.
    The code I use to read this xml file is:
    JasperCompileManager.compileReportToFile("xmlfile.xml","jasperfile.jasper");
    When I run this code in JBuilder it run fine.
    But when I compile the classes and this xml to my jar file,sign it and then try to run it in java Webstart.It tells me that it can not find the path.
    What is wrong?

    I don't know Jasper Reports, so I may be wrong here.
    A file inside a .jar file is not a file on the filesystem, and cannot be accessed with java.io file-related classes. You should use ClassLoader.getResource() to get an inputstream reading from it.

  • How to let JavaScript   Communication with java

    he *,
    i have develop a firefox extension , i am using liveconnect let javascript communicate with java,
    it's my java code :
    public class javaCode{
            private int i;
            public javaCode() {
                    this.i = 0;
            public void testCount() {
                    while (true) {
                            String msg = "Call Java Method Count :" + this.i;
    }my javascript :
    function test() {
                             var myClass = loader.loadClass('com.example. javaCodeclass); 
    var myObj = myClass.newInstance(); 
    var binval = myObj. testCount ();
                    }when i install the extension into my firefox , i get a problem that is when restart firefox after i instll it ,I can't open the firefox ,but i find the firefox process is still running
    the problem is looks like the java is using "while(true)" , so it's won't stop ,
    but how to solve the problem using js or java ??
    any idea ?
    cheers,

    bobby92 wrote:
    Actually , i don't know how it will be active , so i have to using while (true)No, I'm pretty sure you don't need to. There are few cases where while(true) is needed and this isn't one of them.
    but can't i using javascript to stop the java method ??Nope, not in the middle of a while loop.
    or how to solve the problem ?What was your problem in the first place, what are you trying to achieve?

  • Servlet communicating with database

    Hi ,i need 2 forms (html pages) where i can insert soem data in form1 (3 textfields)and some data(3 textfields) in form2,form1 is cnnected to form 2 with a continue button.then i mapped a java file page1 from form 2 then to database using page1 and dbconnection and started tomcat server.now tomact run succesfully but i am not getting values i inserted in form1 in the database but can get teh values in from2 .after form2 page is directed to javafile url/page therei can see the message as
    conn est record inserted null null null software computing eng
    also Database showing last 3 column values i.e software, computing ,eng

    The more I read your post, the more confused I got. Try to run the forum's built in spellchecker before posting the message.

  • Interesting! C client socket communicating with java server sockets after..

    Hi,
    I have a client(in C) open a socket and server(in java; jvm 1.2) listening on the same port(e.g. 4444) accepts the request and establishes a socket conn. Now the sockets are kept open indefinitely. If I kill the server process and bring it backup, the client(in C) cannot communicate with the server(in java).
    Why would this be happening? Aren't the server socket garbage collected?
    How do I make sure that the next time I bring up the server again, the client communicates with it.
    Any inputs is really appreciated.
    thanks
    atul.

    Check the client is closing the connection before it stops.
    I've had similar problems with JDBC before where if you don't explicitly close the connection it remains bound to the port, hence if your client only ever tries to connect to that port it will fail.
    I think.
    MrChris

  • Downloading updated jars with java webstart

    I have a web start application where I download individual data jars using the javaws DownloadService API. These jars change infrequently but do change. My initial implementation was relatively straightforward:
    String dataArchiveUrl = study.getDataArchiveUrl();
    URL url = new URL(dataArchiveUrl);
    DownloadServiceListener dsl = new MyTestDownloadServiceListener();
    ds.loadResource(url, null, dsl);This works great for the initial download and when there is no update to the data jar. The problem is that when the data jar is updated, javaws does not download the update unless I manually delete the original data jar from the web start cache. I had expected(hoped?) that loadResource would work like javaws and check the timestamp of the resource to determine if an update was needed, but that does not appear to be what happened. I have confirmed that the jar timestamps are being served accurately.
    I was able to put in a work around that checks the timestamp and, if the server timestamp is newer, removes the resource from the cache. This forces webstart to update the data jar when the timestamp is updated but is less than ideal for a couple reasons:
    (1) It seems inefficient to open up my own URLConnection to the resource. Is there a way to get webstart to handle the updating for me based on the timestamp?
    (2) The application is designed for offline use. The work around removes the data jar before downloading the new one. This would seem to open a gap where if a user starts downloading an update but gets disconnected before finishing, they won't have access to either the old or new data file. Does anyone have any ideas on closing this gap?

    I have a web start application where I download individual data jars using the javaws DownloadService API. These jars change infrequently but do change. My initial implementation was relatively straightforward:
    String dataArchiveUrl = study.getDataArchiveUrl();
    URL url = new URL(dataArchiveUrl);
    DownloadServiceListener dsl = new MyTestDownloadServiceListener();
    ds.loadResource(url, null, dsl);This works great for the initial download and when there is no update to the data jar. The problem is that when the data jar is updated, javaws does not download the update unless I manually delete the original data jar from the web start cache. I had expected(hoped?) that loadResource would work like javaws and check the timestamp of the resource to determine if an update was needed, but that does not appear to be what happened. I have confirmed that the jar timestamps are being served accurately.
    I was able to put in a work around that checks the timestamp and, if the server timestamp is newer, removes the resource from the cache. This forces webstart to update the data jar when the timestamp is updated but is less than ideal for a couple reasons:
    (1) It seems inefficient to open up my own URLConnection to the resource. Is there a way to get webstart to handle the updating for me based on the timestamp?
    (2) The application is designed for offline use. The work around removes the data jar before downloading the new one. This would seem to open a gap where if a user starts downloading an update but gets disconnected before finishing, they won't have access to either the old or new data file. Does anyone have any ideas on closing this gap?

  • Flash client communication with Java server

    I have written a Flash client in actionscript-3 and I have a Java server that is running locally using command prompt. I run the Flash app using Ctrl+Enter in Flash CS4 IDE and I am trying to receive some numbers from the server. I get the following message at trace output:
    Error #2044: Unhandled securityError:. text=Error #2048: Security sandbox violation: file:///C|/Documents%20and%20Settings/****/My%20Documents/CODE/FLASH/FlashApp/FlashApp.sw f cannot load data from localhost:12345.
    Why? What must i do to overcome this?
    Also when i publish the Flash app and use xampp to run a local web server and then use web browser to access FlashApp.html i also cannot receive any numbers from the java socket server that runs locally (on the same pc as the flash app does).

    Flash makes a request to the socket server automatically, if it doesn't get the proper response (a cross-domain XML document), then it won't connect.
    Here are a couple of links to get you started:
    http://help.adobe.com/en_US/as3/dev/WS5b3ccc516d4fbf351e63e3d118a9b90204-7c60.html
    http://www.adobe.com/devnet/air/flex/quickstart/articles/communicating_with_sockets.html
    If you have questions after reviewing these articles, let me know.

  • How to use Java WebStart with EJB ?

    hi forum...
    how to use Java WebStart with EJB ? examples ?
    thanks
    mindu

    Greetings,
    hi forum...
    how to use Java WebStart with EJB ? examples ?Well, for starters these are complementing, not 'cooperating', technologies. I presume, since EJB's do not - directly, at least - communicate with a web browser, that you intend for "Java WebStart" to somehow invoke an EJB?? Java WebStart is a technology for running client-side (Java) applications from the web browser - perceptively, the application resides on the server, but technically it, like an applet, is downloaded to the client and run there. Unlike an applet, however, it is not constrained by "sandbox" restrictions and does not have to be re-downloaded each time it is invoked - though the process allows for automagically updating the client-side with new versions of the application. ;) So, with this in mind, to "use Java WebStart with EJB" means little more than deploying an EJB client application with Java WebStart as the distribution channel.
    thanks
    minduRegards,
    Tony "Vee Schade" Cook

  • How can i create messenger with java tv API on STB

    deal all.
    how can i create messenger with java tv API on STB.
    how can Xlets communicate each other?
    how?
    i am interested in xlet communications with java tv.
    is it impossible or not?
    help all..

    You can create a messenger-style application using JavaTV fairly easily. JavaTV supports standard java.net, and so any IP-based connection is pretty easy to do. The hard part of the application will be text input, but people have been using cellphone keypads to send SMS messages for long enough that they're familiar with doing this. This doesn't work well for long messages, where you really need a decent keyboard, but for short SMS-type messages it's acceptable.
    The biggest problem that you need to work around is the return channel. Many receivers only have a dial-up connection, ties up the phone line and potentially costs people money if they don't get free local calls. Always-on return channels (e.g. ADSL or cable modem) are still pretty uncommon, so it's something that you nee to think about. Of course, if you do have an always-on connection then this problem just goes away.
    This is really one of those cases that's technically do-able, but the infrastructure may not be there to give users a good experience.
    Steve.

  • VB Client communicating with a Java servlet

    Hi,
    I have a java servlet and I would like to have a VB application communicating with the servlet.
    Can I do it ? and if yes, how to do it.
    Thanks in anticipation,
    Ayana

    The VB client can open an internet or Http connection to the servelet, send a request and parse the response. We've done it here but I don't know exactly which ActiveX control the VB guy uses.
    Also look into using webservices.

  • Need help with applet servlet communication .. not able to get OutputStream

    i am facing problem with applet and servlet communication. i need to send few image files from my applet to the servlet to save those images in DB.
    i need help with sending image data to my servlet.
    below is my sample program which i am trying.
    java source code which i am using in my applet ..
    public class Test {
        public static void main(String argv[]) {
            try {
                    URL serverURL = new URL("http://localhost:8084/uploadApp/TestServlet");
                    URLConnection connection = serverURL.openConnection();
                    Intermediate value=new Intermediate();
                    value.setUserId("user123");
                    connection.setDoInput(true);
                    connection.setDoOutput(true);
                    connection.setUseCaches(false);
                    connection.setDefaultUseCaches(false);
                    // Specify the content type that we will send binary data
                    connection.setRequestProperty ("Content-Type", "application/octet-stream");
                    ObjectOutputStream outputStream = new ObjectOutputStream(connection.getOutputStream());
                    outputStream.writeObject(value);
                    outputStream.flush();
                    outputStream.close();
                } catch (MalformedURLException ex) {
                    System.out.println(ex.getMessage());
                }  catch (IOException ex) {
                        System.out.println(ex.getMessage());
    }servlet code here ..
    public class TestServlet extends HttpServlet {
         * Processes requests for both HTTP <code>GET</code> and <code>POST</code> methods.
         * @param request servlet request
         * @param response servlet response
         * @throws ServletException if a servlet-specific error occurs
         * @throws IOException if an I/O error occurs
        protected void processRequest(HttpServletRequest request, HttpServletResponse response)
                throws ServletException, IOException {
             System.out.println(" in servlet -----------");
            response.setContentType("text/html;charset=UTF-8");
            PrintWriter out = response.getWriter();
            ObjectInputStream inputFromApplet = null;
            Intermediate aStudent = null;
            BufferedReader inTest = null;
            try {         
                // get an input stream from the applet
                inputFromApplet = new ObjectInputStream(request.getInputStream());
                // read the serialized object data from applet
                data = (Intermediate) inputFromApplet.readObject();
                System.out.println("userid in servlet -----------"+ data.getUserId());
                inputFromApplet.close();
            } catch (Exception e) {
                e.printStackTrace();
                System.err.println("WARNING! filename.path JNDI not found");
            } finally {
                out.close();
        @Override
        protected void doGet(HttpServletRequest request, HttpServletResponse response)
                throws ServletException, IOException {
            System.out.println(" in foGet -----------");
            processRequest(request, response);
         * Handles the HTTP <code>POST</code> method.
         * @param request servlet request
         * @param response servlet response
         * @throws ServletException if a servlet-specific error occurs
         * @throws IOException if an I/O error occurs
        @Override
        protected void doPost(HttpServletRequest request, HttpServletResponse response)
                throws ServletException, IOException {
            System.out.println(" in doPost -----------");
            processRequest(request, response);
         * Returns a short description of the servlet.
         * @return a String containing servlet description
        @Override
        public String getServletInfo() {
            return "Short description";
        }// </editor-fold>
    }the Intermediate class ..
    import java.io.Serializable;
    public class Intermediate implements Serializable{
    String userId;
        public String getUserId() {
            return userId;
        public void setUserId(String userId) {
            this.userId = userId;
    }

    Hi,
    well i am not able to get any value from connection.getOutputStream() and i doubt my applet is not able to hit the servlet. could you review my code and tell me if it has some bug somewhere. and more over i want to know how to send multiple file data from applet to servlet . i want some sample or example if possible.
    do share if you have any experience of this sort..
    Thanks.

  • Jar files download problems in Java Webstart with JRE 1.6

    We have encountered a few problems in Java Webstart with JRE 1.6
    In JRE 1.5, the jar files are getting downloaded onto the client
    machine with it's original names.
    Example :
    Server File Name : acm.jar
    Client File Name : RMacm.jar
    But in JRE 1.6, the jar files are getting downloaded with improper file names.
    Example :
    Server File Name : acm.jar
    Client File Name : 4fb074cc-66fc7407
    Moreover the path itself seems to be invalid.
    Example Path :
    JRE 1.5 path:
    C:\Documents and Settings\Administrator\Application
    Data\Sun\Java\Deployment\cache\javaws\https\D17.16.23.11\P443\DMtest\DMwebStart
    JRE 1.6 path:
    C:\Documents and Settings\Administrator\Application
    Data\Sun\Java\Deployment\cache\6.0\12
    Due to this, we are facing Classpath problems.
    What changes do we have to make to the code, for Java
    Webstart to work ?
    We are using JBoss 4.0.4 and JDK 1.5 in the Server
    On the client machine, we have IE 6 and JRE 1.6.01
    Help would be appreciated.

    Ask your Java Web Start question at:
    http://forum.java.sun.com/forum.jspa?forumID=38

Maybe you are looking for

  • Problem in VA02 call transaction

    Hi Friends I processed failured IDOC through ZPROGRAM, after processing IDOC it will create a sale order and display the order number in my program output.Whenever user clicks that button it should take him into VA03 transaction.It was working fine,

  • How to fetch and save file in common server using FTP in SAP

    Dear All, My requirement is to fetch a image and save an image in a common server through SAP . I think there is some concept of doing the same using FTP. Please put some light on this issue. REgards, Amruta

  • Web Dynpro ABAP application test - PORT

    Hi, I've created a custom WDA application, but I cannot test it. I've checked: SICF (appl. is active) Any application that I try to test (standard from SAP), opens a new window (IEXPLORE) but does not show anything in it. I get a message no page foun

  • Emailing in webdynpro abap

    hi all, i have done adobe forms in webdynpro abap.can anyone tell how to send emails using adobe in webdynpro. thanks in advance, chandana.

  • Cann't close form

    Hi , I creating a custom master-detail form on EBS 12.1.2 , and i can't close the form when i press on the close button i had modified the pre_form trigger on module level to have my new window name , and also the app_custom.close_window with my new