EJB access from applet on Linux

Hi,
I've been trying for 2 days now to access an EJB in JServer from a Java Applet running in the Java Plugin 1.2.2 in Netscape on Linux.
After loading the applet web page the plugin fires up and downloads a whole bunch of needed classes. Then I get this exception:
java.lang.ExceptionInInitializerError: org.omg.CORBA.INITIALIZE: can't instantiate default ORB implementation
com.visigenic.vbroker.orb.ORB minor code: 0 completed: No
at org.omg.CORBA.ORB.create_impl(ORB.java, Compiled Code)
at org.omg.CORBA.ORB.<clinit>(ORB.java:202)
at oracle.aurora.jndi.orb_dep.Orb.init(Orb.java, Compiled Code)
at oracle.aurora.jndi.orb_dep.IRFinder.getObject(IRFinder.java, Compiled Code)
at oracle.aurora.jndi.orb_dep.IRFinder.initialReferences(IRFinder.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.SessionCtx.initialContext(SessionCtx.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.SessionCtx.<init>(SessionCtx.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.ServiceCtx.createSession(ServiceCtx.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.ServiceCtx.login(ServiceCtx.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.ServiceCtx.defaultSession(ServiceCtx.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.ServiceCtx.lookup(ServiceCtx.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.sess_iiopURLContext.lookup(sess_iiopURLContext.java, Compiled Code)
at oracle.aurora.jndi.sess_iiop.sess_iiopURLContext.lookup(sess_iiopURLContext.java, Compiled Code)
at javax.naming.InitialContext.lookup(InitialContext.java, Compiled Code)
at vtsi.location.NearSelectionApplet.start(NearSelectionApplet.java, Compiled Code)
at sun.applet.AppletPanel.run(AppletPanel.java, Compiled Code)
at sun.plugin.navig.motif.MotifAppletViewer.maf_run(MotifAppletViewer.java, Compiled Code)
at sun.plugin.navig.motif.MotifAppletViewer.run(MotifAppletViewer.java, Compiled Code)
at java.lang.Thread.run(Thread.java, Compiled Code)
The frustrating part is that the same applet works just fine when called in a Win NT broswer (IE and Netscape) or appletviewer. A java test application accessing the EJB also runs fine on Linux.
The only obivious difference is that my Windows machine has the Java Plugin 1.3 installed and Linux only 1.2.2. But since the applet has been compiled with the 1.2.2 compiler that shouldn't really make a difference, should it?
I'd appreciate any help on this subject.
Thx,
Thomas J.

i could answer this
but my colleagues are working on a client which uses client(applet) to access stateless session beans
but mine's giving a little problem
visit my problem for some of the overview which i think will be fixed or
the same could run on your machine
http://forum.java.sun.com/thread.jsp?forum=13&thread=538583&tstart=0&trange=15

Similar Messages

  • Accessing EJB's from Applet

    Hai friends,
    I want to access the ejb form the applet is it possible ?
    if passible please let me know how we access?
    Please send souce code to this id
    [email protected]
    Ok Friends i am wating for replys

    Is it possible to access EJB's from applet?Yes, but not recommended.
    if Yes,Please let me know how will happen and also if
    possible send me the peace of source code for this.
    mail id is : [email protected]
    Are you inviting spam by passing your mail id?
    Google and find out how EJB lookups are performed.

  • EJB access from C++ client / Failover+LoadBalancing

    We are accessing an EJB from VisiBroker for C++. The EJB is deployed in a WLS cluster.
    Trying to achieve something like 'failover', we discovered that VisiBroker supports
    multiloc addresses, so we are able to start our client as follows:
    ./client -ORBInitRef NameService=corbaloc::server1:8001,:server2:8002/NameService
    As a result, server2 is only used when NameService of server1 is not available.
    After connecting to a distinct NameService in a cluster, all further IIOP calls
    are routed to this cluster server only. If the server shuts down, a new NameService
    connection has to be made to get access to the other server and its objects.
    Is this correct so far?
    For the idea of 'load balancing' our EJB accesses, we didn't find a solution -
    so it seems that this is completely impossible or is there any trick we could
    use?
    Thanks for your help
    ml

    "Marko Lorentz" <[email protected]> writes:
    We are accessing an EJB from VisiBroker for C++. The EJB is deployed in a WLS cluster.
    Trying to achieve something like 'failover', we discovered that VisiBroker supports
    multiloc addresses, so we are able to start our client as follows:
    ./client -ORBInitRef NameService=corbaloc::server1:8001,:server2:8002/NameService
    As a result, server2 is only used when NameService of server1 is not available.
    After connecting to a distinct NameService in a cluster, all further IIOP calls
    are routed to this cluster server only. If the server shuts down, a new NameService
    connection has to be made to get access to the other server and its objects.
    Is this correct so far?
    For the idea of 'load balancing' our EJB accesses, we didn't find a solution -
    so it seems that this is completely impossible or is there any trick we could
    use?If you use the Tuxedo 8.1 C++ client, then you will get per-request
    load-balancing and failover. The C++ client is free to WLS licensees.
    andy

  • EJB access from LoginModule / Realm impl.

    iH:
    I have a custom LogingModule and Realm implementation for SJSAS (J2EE SDK 1.4). My user/group information is stored in a MySQL instance. I am currently using straight JDBC to perform authentication; I would like to use EJB instead (ie: implement a Session bean with a business method 'authenticate').
    However, it would appear that I "can't get there from here". When I try to lookup objects via JNDI, I get NamingException's encapsulating InvocationExceptions. It would appear that I can't lookup "java:comp/env/" names from within LoginModule / ISARealm implementations.
    This sort of makes sense to me ... my LoginModule implementation is essentially a J2EE client, invoked by the J2EE application server itself. Normally I would have to run J2EE client code with appclient (when using SJSAS) right?
    Is there a way to use J2EE services from within services added to the App server? I could probaby expose this stuff as a web service, but that just seems like a silly work around. At the very least I would like to be able to define a JDBC connection pool so that I don't have to manage JDBC connections myself. At the moment I am creating a new connection every time I authenticate a user (wince).
    Aaron.

    Thanks; it turns out that this is a red-herring. There is no problem. Accessing a session bean from a LoginModule implementation works just fine.
    I was trying to lookup names like "java:comp/env/....". This resulted in an InvocationException, which I thought was telling me that there was something horribly wrong. It turns out that everything works as expected if I lookup names relative to "java:comp/env" -- ie: if I lookup ejb/<session bean name>.
    I think I should be getting a "name not found" NamingException rather than an InvocationException encapsulated in a NamingException. Should I submit a (minor) bug for that?
    Thanks for your help. I see your posts here frequently. Keep fighting the good fight.

  • Resources access from applets

    I need to present images in a web page scaled to a proper size, depending on the context: small size in an index page and real size in a content page.
    Maybe I can do it in a simple way by means of Javascript, but I'm trying to do it by means of an applet.
    The problem I am experiencing when I try to test my applet with appletviewer is that I get the following exception:
    java.security.AccessControlException: access denied (java.net.SocketPermission www.cervantina.org resolve)
    Any hint? Thanks in advance (If anybody knows how to do it in Javascript, it will also be welcome)

    Yeah, it should be just to access a local file, i.e. in the same directory the .class file is located. Just to save some data that the Applet uses and which the user should be able to edit. I'd appreciate it if you could tell me how you did that!

  • Can't parse xml from applet using dom on linux on Netscape 7 using jre 1.4.

    Hi,
    I can't seem to parse xml from an applet on linux on Netscape 7 using the JRE 1.4.
    My code looks like the following:
    StringBufferInputStream is = new StringBufferInputStream("<foo></foo>");
    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    DocumentBuilder builder = null;
    try
      builder = factory.newDocumentBuilder();
      domDocument = builder.parse(is); // this line creates an exception
    catch (Exception e)
      System.out.println(e);
    This code works fine from an applet on windows. On linux, the error message is:
    java.security.AccessControlException: access denied (java.util.PropertyPermission entityExpansionLimit read)
    I've tried both JRE 1.4.0_04 and 1.4.1_03
    Thanks!
    Q

    There's another posting about this same problem (platform unspecified), but the same error message. I was also having this problem (Windows 1.4.03) and swithced back to 1.4.01 and the problem went away. In the future, I may sign my applets to get a more generous security policy. But, I'm sure it'll be a lot of work (vs. a line of code somewhere).

  • Configure ODBC to access a CSV file on Linux for access from BI Server

    How to configure an ODBC connection to a CSV file on Linux for access from the BI Server Repository physical layer
    I am migrating a working windows OBIEE installation to Linux and can not seem to connect to csv files on Linux (from th BI server also running on the same Linux machine).
    I am using SUse Linux Enterprise server / 10 (Slash 10) standard odbc drivers
    My odbc ini file entries are:
    [ODBC]
    Trace=0
    TraceFile=odbctrace.out
    TraceDll=/app/oracle/product/10.1.3/OracleBI/odbc/lib/odbctrac.so
    InstallDir=/app/oracle/product/10.1.3/OracleBI/odbc
    UseCursorLib=0
    IANAAppCodePage=4
    [ODBC Data Sources]
    AnalyticsWeb=Oracle BI Server
    Cluster=Oracle BI Server
    SSL_Sample=Oracle BI Server
    idcbicsvfiles=Odbc Text driver
    [idcbicsvfiles]
    Description = Odbc Text driver
    Driver = Odbc Text driver
    Directory = /data/oracle/OracleBIData/idc
    #ReadOnly = No
    #CaseSensitive = No
    #Catalog = No
    ColumnSeperator = ,
    #Trace = 1
    #Tracefile =/data/oracle/OracleBIData/odbctrace.txt
    #Username      = oracle
    #Password      = ''
    [AnalyticsWeb]
    Driver=/app/oracle/product/10.1.3/OracleBI/server/Bin/libnqsodbc.so
    Description=Oracle BI Server
    ServerMachine=local
    Repository=
    Catalog=
    UID=
    PWD=
    Port=9703
    The csv files I want to use are in the directory /data/oracle/OracleBIData/idc to which I have set up a working and checked connection ([idcbicsvfiles]) on the linux machine itself.
    The error message I get when I select view data in the physcial layer is:
    [NQODBC][SQL_STATE: HY000][nQSError: 10058] A general error has occurred.
    [nQSError: 43093] An error occurred while processing the EXECUTE PHYSICAL statement.
    [nQSError: 16023] The ODBC function has returned ans error. The database may not be available, or the network may be down.
    Please can anybody give me a clue on how to get this working e.g. a working odbc.ini file from your own installation (and/or a tip for the odbc driver choice/configuration)
    P.S. I know this is not supported by Oracle but can not imagine, that nobody is using this.

    Hi,
    Chekc this...Re: Is there ODBC driver for excel flat file in Unix Box
    Re: OBIEE to use a CSV file as a data source on Linux
    Regards,
    Srikanth
    Edited by: Srikanth Mandadi on Oct 8, 2010 2:50 AM

  • How to access database from applet using connection pooling.

    Hi,
    I am using tomcat 4.1, JRE 1.4.2_10, MySQL 5.0, and IE 6.0. I can access the database using connection pooling from JSP without problems. But, if I try to acess from the applet, I get the following exception (related to JNDI.):
    javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
    at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
    at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
    at javax.naming.InitialContext.getURLOrDefaultInitCtx(Unknown Source)
    at javax.naming.InitialContext.lookup(Unknown Source)
    I know what this acception means, but I don't know how to fix it. I set up connection pooling in my Tomcat 4.1 that talks to MySQL 5.0. As I said, when I access from jsp, JNDI works. But, applet complains. Please help. In my applet, the following code accesses the database:
    ArrayList toolTipData =
          access.getToolTipData (projectName,interfac);This is the snipet of my Access class:
    public ArrayList getToolTipData (String projectName, String interfac) {
        System.out.println("In getToolTipData");
        ArrayList toolTipData = new ArrayList();
       try{
        Context ctx = new InitialContext();
        if(ctx == null )
            throw new Exception("No Context");
        DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/interfacesDB");
        if (ds != null) {
          Connection conn = ds.getConnection();
          if(conn != null)  {
              Statement s = conn.createStatement();
              //For some reason paramtized queries don't work, so I am forced
              //to this in slighly less eficient way.
              ResultSet rst = s.executeQuery("select * from interfaces");
              while (rst.next()) {
                 if (rst.getString("Project_Name").equals(projectName) &&
                     rst.getString("Interface").equals(interfac)) {
                   System.out.println("getToolTipData: ITG #" + rst.getString("ITG"));
                   toolTipData.add("ITG #: " + rst.getString("ITG"));
                   toolTipData.add("SPNE Prime Name: " +
                                   rst.getString("SPNE_Prime_Name"));
                   toolTipData.add("PD Prime Name: " +
                                   rst.getString("PD_Prime_Name"));
                   toolTipData.add("IT Prime Name: " +
                                   rst.getString("IT_Prime_Name"));
                   toolTipData.add("MLC Priority: " +
                                   rst.getString("MLC_Priority"));
                   toolTipData.add("Gary's Prime: " + rst.getString("Garys_Prime"));
                   toolTipData.add("QA Prime: " + rst.getString("QA_Prime"));
                   toolTipData.add("Brief Description: " +
                                   rst.getString("Brief_Description"));
                   toolTipData.add("Project_Status: " +
                                   rst.getString("Project_Status"));
              conn.close();
      }catch(Exception e) {
        e.printStackTrace();
      return toolTipData;
    ....

    The jsp runs on the server, whereas the applet runs on the client so
    you must package with your applet any jndi implementation specific classes
    and
    Properties props = new Properties();
    props.setProperty("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory" );
    props.setProperty("java.naming.provider.url", "url:1099");
    Context ctx = new InitialContext(props);
    Object ref = ctx.lookup("...");

  • Calling EJB from applet

    Hi friends,
    I have a problem of caling EJB from applet.that too from browser.
    Through dos prompt,I am able to set the classpath and then open the applet and then call the EJB.but thru browser i am encontering two problems,
    First,The codebase of applet is not being set and i am unable to view the applet.
    Second,my Initial Context Factory is not being found it is giving error as
    Cannot instantiate class: com.evermind.server.rmi.RMIInitialContextFactory.I am using oracle app server Oc4j2.
    can any one help me out.
    i am able to get output thru dos prompt where i can set classpath

    kyren,
    he has used something called HTML ConvertersDepends on the version of the plug-in you are using.
    (I'm sorry, but I couldn't find that detail in any of your posts!)
    You have to use the (HTML) converter with java version 1.3 (for example), but you don't have to with java version 1.4.
    thru my jbuilder version i am able to solve my
    problem.
    but thru browser,i am first of all not able to
    display applet.That's because "JBuilder" uses the appletviewer to display the applet (and not a browser).
    I Think for normal displaying applet we don't need of
    signed or unsigned applet.when calling ejb we may
    require.As Anupama has stated, the "codebase" attribute of the applet tag must be relative to the directory where the HTML file (containing the "applet" tag) is located. Where I work, we also use the "archive" attribute that tells the applet where to download the JAR files from. In order to lookup your ejb from your applet, you need (at least) the "oc4jclient.jar" file.
    By the way, if you want your name to appear next to your posts (instead of your ID number), you need to update your profile. Click on the "Forum Settings" link at the top of the (Web) page.
    Good Luck,
    Avi.

  • Accessing EJB's from CORBA clients

    Hi!
    Can someone answer one badly important question?
    Is it possible to access EJB's from CORBA clients directly, as if the
    beans were ordinary CORBA objects? I mean DIRECT access - WIDHOUT
    CORBA/Java server application as a liason between CORBA client and EJB
    server!
    I'm using WebLogic Enterprise 5.0.1.
    Thanks in advance.
    Aleksey.

    Please reference a later posting on this very same question.
    -- Lou Caraballo
    Sr. Systems Engineer
    BEA Systems Inc., Denver Telco Group
    719-332-0818 (cell)
    720-528-6073 (denver)
    Aleksey Bukavnev <[email protected]> wrote in message
    news:[email protected]..
    Thank you!
    Aleksey.
    Bill Lloyd wrote:
    There is a java to IDL mapping, which is quite complex. To use it, you
    must
    have an ORB which supports, at minimum, CORBA 2.3. ORBs I know of which
    support this include Orbix 2000 for Java, Visibroker 4.0 for Java, and
    Orbacus 4.0 for Java.
    Also, check out the June 2000 "Java Report" which has an article onthis.
    >>
    To be perfectly honest, though, the best solution is to write a bridge,in
    Java. One side is IDL, which CORBA clients use. The implementation ofthat
    IDL makes RMI requests to get the necessary info. This solution willwork,
    guaranteed. The portion of the spec for the java to IDL mapping isstill
    quite new, and I would expect some, uh, "unexpected features" at thistime.
    >>
    -B
    "Aleksey Bukavnev" <[email protected]> wrote in message
    news:[email protected]..
    Hi!
    Can someone answer one badly important question?
    Is it possible to access EJB's from CORBA clients directly, as if the
    beans were ordinary CORBA objects? I mean DIRECT access - WIDHOUT
    CORBA/Java server application as a liason between CORBA client and EJB
    server!
    I'm using WebLogic Enterprise 5.0.1.
    Thanks in advance.
    Aleksey.

  • Problem with accessing Signed Applet from javascript method

    Hi,
    I am facing the following problem while accessing Signed Applet from javascript method.
    java.security.AccessControlException: access denied (java.io.FilePermission c:/temp.txt read)
         at java.security.AccessControlContext.checkPermission(Unknown Source)
         at java.security.AccessController.checkPermission(Unknown Source)
         at FileTest.testPerm(FileTest.java:19)
         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 sun.plugin.javascript.invoke.JSInvoke.invoke(Unknown Source)
         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 sun.plugin.javascript.JSClassLoader.invoke(Unknown Source)
         at sun.plugin.com.MethodDispatcher.invoke(Unknown Source)
         at sun.plugin.com.DispatchImpl.invokeImpl(Unknown Source)
         at sun.plugin.com.DispatchImpl$1.run(Unknown Source)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.plugin.com.DispatchImpl.invoke(Unknown Source)
    I am using jdk1.5 for my development...
    Can anyone help to resolve this security issue. Urgent...
    Thanks in advance.

    Hey thanks. I wasn't able to get it to work with that sample but I did find this very similar code that does allow javascript to call JFileChooser in an applets public method.
    java.security.AccessController.doPrivileged(
    new java.security.PrivilegedAction()
    public Object run(){                           
    //do your special code here
    return null; //return whatever you want
    It seems a bit tempermental in that if you don't select a file quickly, it will hang the browser....no perfect solution but I'm going in the right direction.
    Thanks,
    Scott

  • Accessing an applet from another applet

    Hi,
    I created a web page with a bunch of applets running on it, and I need to comunicate them. Is it possible to access the public methods and variables of one applet from another applet ? How do I do it ?

    I recently read an article that described how to access other applets in the same page, but I didn't pay much attention to it because I don't write applets. However, a quick look at the API documentation for the java.applet package shows this:
    "AppletContext: This interface corresponds to an applet's environment: the document containing the applet and the other applets in the same document."
    So I would try to get an AppletContext and see what could be done with it.

  • EJBs accessing protected classes from java classloader

    Hello,
    We are facing a problem with classes isolation. I read from this newsgroup that
    to access a package level class from the base classloader from a bean, the supporting
    classes has to be from the same classloader as the bean. Well I think the only
    way we could do that is to have the *Bean.class in the base classloader, which
    is not what's recommended or move the support classes into the bean's classloader,
    which we cannot do.
    The purpose of this mail is to ask: is it a bug from weblogic server? Will it
    be fixed one day? If not, does it mean that it is impossible to isolate classes
    for local access from public classes?
    Thank you, Khiet.

    Thank you for your reply.
    Hope that one day we will not be obliged to have anything in the main classpath.
    :) Khiet.
    Rob Woollen <[email protected]> wrote:
    Tran T. Khiet wrote:
    Hello,
    We are facing a problem with classes isolation. I read from this newsgroupthat
    to access a package level class from the base classloader from a bean,the supporting
    classes has to be from the same classloader as the bean. Well I thinkthe only
    way we could do that is to have the *Bean.class in the base classloader,which
    is not what's recommended or move the support classes into the bean'sclassloader,
    which we cannot do.All correct.
    The purpose of this mail is to ask: is it a bug from weblogic server?No, it's how java classloaders work.
    Will it
    be fixed one day? If not, does it mean that it is impossible to isolateclasses
    for local access from public classes?You can expect that future versions of WLS will allow the user more
    control over classloaders, but for now you'll need public or protected
    access to cross classloaders.
    -- Rob
    Thank you, Khiet.

  • TSWeb access from Linux

    Hi,
    We have installed Terminal Services in Windows 2008 R2 system. Now, we have 300 clients in the network (Xp,Vista, W7, Linux and MAC). Are there some possibility to access with tsweb in linux clients? it is possible with Opera or Firefox?
    Thanks!

    Nope, generally that's not true, TSWeb works with IE, FirefoX web browsers (tested by me) :) but to be able to run any RemoteApp you need to have Remote Desktop Client which is compatible with RDC 6.1 in Windows and as I know that version
    is ONLY in Windows :]
    So, you cannot run RemoteApps on Linux servers, because of missing RDC not IE :)
    @update: And of course, if you wish to use Remote Desktop within TS/RD Web Access, you need IE to support ActiveX
     @update2: My mistake ;) TSWeb works itself but do not display any shared apps :) So, IE and RDC are required to work with RemoteApps :) Sorry for inconvenience. 
    Regards, Krzysztof

  • Calling web service from applet

    Hi,
    I am trying to consume a .NET web service from a java applet. I use JDev9i and I generated a clientside-stub...
    It works fine in the development environnement, but I get this exception when executing from browser:
    java.lang.ExceptionInInitializerError: java.security.AccessControlException: access denied (java.util.PropertyPermission * read,write)
         at java.security.AccessControlContext.checkPermission(Unknown Source)
         at java.security.AccessController.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkPermission(Unknown Source)
         at java.lang.SecurityManager.checkPropertiesAccess(Unknown Source)
         at java.lang.System.getProperties(Unknown Source)
         at oracle.soap.transport.http.OracleSOAPHTTPConnection.<clinit>(OracleSOAPHTTPConnection.java:105)
         at AppletPackage.Service1Stub.<init>(Service1Stub.java:23)
    I replaceOracleSOAPHTTPConnection with SoapHTTPConnection, but then I get the same exception when trying to execute
    requestBodyEntries.addElement(toElement(wrappingName, targetNamespace, requestData)); (in the stub)
    Is there anything wrong with the methods of the Oracle packages that could cause security problems?

    Nope, the problem is that the webservice impl is trying to get all system properties and this is a restricted operation for applets. Seems like every single api impl done by oracle is not usable from applets, unless you sign them. I've tried webservices, xml and jndi.. all of them rely on system properties

Maybe you are looking for