🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: aus.computers.java
Article #607

Codebase for sun's enterprise platform

#607
From: Paul Murray
Date: Sun, 09 Jul 2000 00:00
30 lines
2122 bytes
Hi.

When you fetch a reference from an enterprise server

    initialContext.lookup("iiopname://host:1049/SomeApp/SomeHomeInterface")

In order to do the PortableRemoteObject.narrow you need to have access to
the stub class. The sun deployment tool gives you a JAR file containing all
the stubs, and this works fine. But I don't want to distribute this JAR with
my client app.

The sun bean container ought to be passing codebases back with the objects,
from where RMI gets the codebases. But I know it's not, because when I do a
narrow without the stub on the local classpath I get a class cast exception.

So, how do you set the codebase for references passed back by the sun bean
container? Tomorrow at work I'll check what codebase it is actually using
via org.omg.CORBA_2_3.portable.ObjectImpl._get_codebase() (which I only
found out about tonight).

I presume I set the codebase by setting
java.rmi.server.codebase=http://myhost/EnterpriseApps/AppStubs.jar
in one of the config files - the one that is used by the VM instance tossing
references to beans around. I may answer this one for myself tomorrow, but
does anyone know without my asking?

--------------------------------------------------------------
Repent! Quit your job! Slack off!
http://www.users.bigpond.com/pmurray/index-2.html
ICQ: 26066755
Technical Details
Message-ID: <E6Z95.8725$c5.23931@newsfeeds.bigpond.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 108bbb,a4093510ca55f105,start
X-Google-Attributes: gid108bbb,public
X-Google-Thread: 10d6db,a4093510ca55f105,start
X-Google-Attributes: gid10d6db,public
From: "Paul Murray" <pmurray@nospam.bigpond.com>
Subject: Codebase for sun's enterprise platform
Date: 2000/07/09
Message-ID: <E6Z95.8725$c5.23931@newsfeeds.bigpond.com>
X-Deja-AN: 644211476
X-Priority: 3
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600
X-Trace: newsfeeds.bigpond.com 963141156 139.134.123.16 (Sun, 09 Jul 2000 21:12:36 EST)
Organization: Telstra BigPond Internet Services (http://www.bigpond.com)
X-MSMail-Priority: Normal
NNTP-Posting-Date: Sun, 09 Jul 2000 21:12:36 EST
Newsgroups: aus.computers.java,comp.lang.java.corba