[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Regestry Interface Description
- Date: Sun, 24 Nov 1996 12:32:55 -0800
- From: "Rick H. Wesson" <wessorh@ar.com>
- Subject: Regestry Interface Description
All:
What I'm proposing is a interface to distributed regestries. The consept is
one of networked objects. Where a regestry can lookup a handle for a
regestry object (Domain, Contact or Name Server) and then call methods
on that object. These methods can, in the case of a shared regestry, set or
get attributes of an object
The following is a description of these objects and the methods that each
would support. The Factory objects allow a client to the regestry to obtain a
object refrence to one of these objects so that a method may be called on
that object's attribute.
The description below will work for shared and exclusive regestries
and can be layered on top of *ANY* database system. It is upto the regestry
if they implement each method of an attribute. (eg dunn and bradstreet
may not want anyone to be able to set attributes, but allow anyone
to read attributes of an object)
If anything needs an expansion or to be more elearly elaberated on, just ask
I'll galdly explain. Most everything with CORBA can be written in C, C++, and
java. Most of what I have written is in C++, for the shared regestry
implementation I'll write in java, both will be using the same server described
below ;-)
-Rick
senerio #1 - Regestry A wants to build its zone file for the TLDs it serves.
A domain has been regestered that uses name servers regestered in another
regestry.
foreach(domain in Tld)
{
foreach ns (in domain){
if(ns is local)
get ns.name, ns.addr ;
else{
connect to distant regestry.
ns = ns_factory->find(handle) ;
get ns.name, ns.addr ;
}
print ns.name, ns.addr to zone file.
}
}
senerio #2 - A client of a shared regestry allocates a domain
parse domain template.
try{
dn = domain_factory->find(domain.name) ;
} catch(Nic::NotFound &e){
domain_hdl = domain_factory->create(domain.name) ;
domain_hdl->AdminHandle(admin.handle) ;
...
return ;
}
print "Pick a new name" ;
---------------------------- cut here -----------------------------
#ifndef _NIC_IDL
#define _NIC_IDL
#include <Cos/LifeCycle.idl>
module Nic {
exception NotFound { } ;
exception AlreadyExists { } ;
typedef sequence <string> StringList ;
enum Format_t { DEFAULT, INDEX, LDAP, RIPE, WHOIS } ;
interface Contact : CosLifeCycle::LifeCycleObject
{
enum Notify_t { BEFORE, AFTER, NOT_CARE } ;
enum AuthScheme_t { MAIL_FROM, CRYPT, PGP } ;
enum Role_t { INDIVIDUAL, ROLE } ;
readonly attribute string Handle ;
readonly attribute Role_t Type ;
readonly attribute long Created ;
attribute AuthScheme_t AuthScheme;
attribute Notify_t NotifyUpdate ;
attribute Notify_t NotifyUse ;
attribute string Name ;
attribute string OrgName;
attribute string Address;
attribute string City ;
attribute string State ;
attribute string PostalCode ;
attribute string CountryCode ;
attribute string Voice ;
attribute string Fax ;
attribute string EMailBox ;
attribute string AuthInfo ;
attribute long Updated;
attribute boolean Public ;
string toString(in Format_t fmt) ;
} ;
interface ContactFactory {
Contact create(in string name, in Nic::Contact::Role_t type,
in string phone, in string mbox)
raises(Nic::AlreadyExists) ;
Contact find(in string handle)
raises(Nic::NotFound) ;
Contact match(in string name, in string phone, in string mbox)
raises(Nic::NotFound) ;
} ;
interface NameServer : CosLifeCycle::LifeCycleObject {
readonly attribute string Handle ;
readonly attribute long Created ;
attribute string Fqdn ;
attribute string Addr ;
attribute long Ttl ;
attribute long Updated ;
attribute string Platform, OpprSys ;
attribute string TechContact ;
string toString(in Format_t fmt) ;
} ;
interface NameServerFactory {
NameServer create(in string fqdn, in string ip,
in string ct_handle)
raises(Nic::AlreadyExists) ;
NameServer find(in string handle)
raises(Nic::NotFound) ;
NameServer match(in string fqdn, in string ip)
raises(Nic::NotFound) ;
} ;
interface Domain : CosLifeCycle::LifeCycleObject {
enum Status_t { UP, RESERVED, HOLD } ;
readonly attribute string Handle ;
readonly attribute string Name ;
readonly attribute long Created ;
attribute string Purpose ;
attribute string OrgName ;
attribute string Address ;
attribute string City ;
attribute string State ;
attribute string PostalCode ;
attribute string CountryCode ;
attribute string AdminHandle ;
attribute string BillingHandle ;
attribute string TechHandle ;
attribute long Updated;
attribute StringList NS ;
attribute Status_t Status ;
void add_ns( in string handle )
raises(Nic::AlreadyExists) ;
void del_ns( in string handle )
raises(Nic::NotFound) ;
string toString(in Format_t fmt) ;
} ;
interface DomainFactory {
Domain create(in string fqdn)
raises(Nic::AlreadyExists) ;
Domain find(in string fqdn)
raises(Nic::NotFound) ;
// there is no match(fqdn) method because domain names are unique
// and no "key" is nessassary to 'find' one.
} ;
} ;
#endif
--
Rick H. Wesson