Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

URGENT: Problem setting up a Name Server

2 posts in General Discussion (old) Last posting was on 2000-03-27 22:57:12.0Z
Darryl Shields Posted on 2000-03-23 23:30:15.0Z
Newsgroups: sybase.public.easerver
Date: Fri, 24 Mar 2000 10:30:15 +1100
From: Darryl Shields <Darryl_Shields@ausaid.gov.au>
Organization: Australian Agency for International Development
X-Mailer: Mozilla 4.7 [en] (WinNT; I)
X-Accept-Language: en
MIME-Version: 1.0
Subject: URGENT: Problem setting up a Name Server
X-Priority: 1 (Highest)
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Lines: 69
NNTP-Posting-Host: saturn.ausaid.gov.au 202.6.56.2
Message-ID: <347_38DAA907.D031F053@ausaid.gov.au>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.easerver:25779
Article PK: 154343

Hi,

Can someone tell me what I've missed? I have a feeling there's a server
setting or two that I've missed in my configuration, but the problem
could be in the code.

I have a system running happily without a name server, but would like to
introduce one. I've setup the two servers as follows and use code like
the simple example below to try to connect. The code is written in
PowerJ (PowerJ & EAServer 3.0.1) for Java 1.1, but we're actually
running on the client under Java 1.2.2.

When I run my code I get a message saying
"org.omg.CORBA.OBJECT_NOT_EXIST"

JNS Server
----------

Jaguar Name Server
IIOP Listener = 9100
Name Service InitialContext is blank
"Enable as Name Serv" is ON and "Transient" is selected

JTS Server
----------

Jaguar Transaction Server
IIOP Listener = 9200
Name Service InitialContext is blank
"Enable as Name Serv" is OFF
Server Properties: com.sybase.jaguar.server.nameservice =
iiop://localhost:9100


SAMPLE CODE
-----------

private void jcb_actionPerformed(java.awt.event.ActionEvent event) {

org.omg.CORBA.ORB orb = null;

java.util.Properties props = new java.util.Properties();
props.put("org.omg.CORBA.ORBClass","com.sybase.CORBA.ORB");

try {
String[] args = {""};
orb = org.omg.CORBA.ORB.init(args,props);
}
catch (Exception e) {
e.printStackTrace();
}

Manager manager =
ManagerHelper.narrow(orb.string_to_object("iiop://localhost:9100"));

try {
session = manager.createSession("jadadmin", "");
}
catch (org.omg.CORBA.COMM_FAILURE cf){
System.out.println("org.omg.CORBA.COMM_FAILURE");
}
catch (org.omg.CORBA.NO_PERMISSION np){
System.out.println("org.omg.CORBA.NO_PERMISSION");
}
catch (org.omg.CORBA.SystemException se){
System.out.println("org.omg.CORBA.SystemException");
}

org.omg.CORBA.Object obj = create("AusAIDSIMS/TextProvider");

TextProvider tp = TextProviderHelper.narrow(obj);

String text = tp.getText();

jtextfield.setText(text);
}

public org.omg.CORBA.Object create(String ior) {

org.omg.CORBA.Object obj = null;

try {
Factory factory = (Factory) session.lookup(ior);
obj = factory.create();
}
catch (org.omg.CORBA.OBJECT_NOT_EXIST one){
System.out.println("org.omg.CORBA.OBJECT_NOT_EXIST");
}
catch (org.omg.CORBA.NO_PERMISSION np){
System.out.println("org.omg.CORBA.NO_PERMISSION");
}
catch (org.omg.CORBA.SystemException se){
System.out.println("org.omg.CORBA.SystemException");
}

return obj;
}


Darryl Shields


Evan Ireland Posted on 2000-03-27 22:57:12.0Z
Newsgroups: sybase.public.easerver
Date: Tue, 28 Mar 2000 10:57:12 +1200
From: Evan Ireland <eireland@sybase.com>
Organization: Sybase, Inc.
X-Mailer: Mozilla 4.7 [en] (WinNT; U)
X-Accept-Language: en
MIME-Version: 1.0
To: Darryl Shields <Darryl_Shields@ausaid.gov.au>
Subject: Re: URGENT: Problem setting up a Name Server
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Lines: 84
NNTP-Posting-Host: vpn-eme-081.sybase.com 130.214.8.81
Message-ID: <347_38DFE748.CF597969@sybase.com>
References: <347_38DAA907.D031F053@ausaid.gov.au>
Path: forums-1-dub!forums-1-dub!forums-master.sybase.com!forums.sybase.com
Xref: forums-1-dub sybase.public.easerver:25568
Article PK: 155643


Darryl Shields wrote:
>
> Hi,
>
> Can someone tell me what I've missed? I have a feeling there's a server
> setting or two that I've missed in my configuration, but the problem
> could be in the code.
>
> I have a system running happily without a name server, but would like to
> introduce one. I've setup the two servers as follows and use code like
> the simple example below to try to connect. The code is written in
> PowerJ (PowerJ & EAServer 3.0.1) for Java 1.1, but we're actually
> running on the client under Java 1.2.2.
>
> When I run my code I get a message saying
> "org.omg.CORBA.OBJECT_NOT_EXIST"

Check the server log. Is AusAIDSIMS listed under the Installed Packages
section when you click on the server in Jaguar Manager?

> JNS Server
> ----------
>
> Jaguar Name Server
> IIOP Listener = 9100
> Name Service InitialContext is blank
> "Enable as Name Serv" is ON and "Transient" is selected
>
> JTS Server
> ----------
>
> Jaguar Transaction Server
> IIOP Listener = 9200
> Name Service InitialContext is blank
> "Enable as Name Serv" is OFF
> Server Properties: com.sybase.jaguar.server.nameservice =
> iiop://localhost:9100
>
> SAMPLE CODE
> -----------
>
> private void jcb_actionPerformed(java.awt.event.ActionEvent event) {
>
> org.omg.CORBA.ORB orb = null;
>
> java.util.Properties props = new java.util.Properties();
> props.put("org.omg.CORBA.ORBClass","com.sybase.CORBA.ORB");
>
> try {
> String[] args = {""};
> orb = org.omg.CORBA.ORB.init(args,props);
> }
> catch (Exception e) {
> e.printStackTrace();
> }
>
> Manager manager =
> ManagerHelper.narrow(orb.string_to_object("iiop://localhost:9100"));
>
> try {
> session = manager.createSession("jadadmin", "");
> }
> catch (org.omg.CORBA.COMM_FAILURE cf){
> System.out.println("org.omg.CORBA.COMM_FAILURE");
> }
> catch (org.omg.CORBA.NO_PERMISSION np){
> System.out.println("org.omg.CORBA.NO_PERMISSION");
> }
> catch (org.omg.CORBA.SystemException se){
> System.out.println("org.omg.CORBA.SystemException");
> }
>
> org.omg.CORBA.Object obj = create("AusAIDSIMS/TextProvider");
>
> TextProvider tp = TextProviderHelper.narrow(obj);
>
> String text = tp.getText();
>
> jtextfield.setText(text);
> }
>
> public org.omg.CORBA.Object create(String ior) {
>
> org.omg.CORBA.Object obj = null;
>
> try {
> Factory factory = (Factory) session.lookup(ior);
> obj = factory.create();
> }
> catch (org.omg.CORBA.OBJECT_NOT_EXIST one){
> System.out.println("org.omg.CORBA.OBJECT_NOT_EXIST");
> }
> catch (org.omg.CORBA.NO_PERMISSION np){
> System.out.println("org.omg.CORBA.NO_PERMISSION");
> }
> catch (org.omg.CORBA.SystemException se){
> System.out.println("org.omg.CORBA.SystemException");
> }
>
> return obj;
> }
>
> Darryl Shields

--
________________________________________________________________________________

Evan Ireland Sybase EAServer Engineering eireland@sybase.com
Wellington, New Zealand +64 4 934-5856