| OOP
The CCI and CGI interfaces point to a general need for interprocedure comminication between web applications and other applications. Here are some critical interface points between components of the web.
The GET operation in the web retrieves the persistent state for an object across the network, so that the object can be activated/initialized on the client side.
Typically, the persistant state of an object is stored in a file, i.e. a document on the desktop. But it can also be in a database, or the output of a computation.
System | Facility | Example |
---|---|---|
libwww | HTAccess, SGML parsing | request = ...; HTRequest_setOutputStream(request, output); HTAnchor * anchor = HTAnchor_findAddress(url); HTRequest_setAnchor(request, anchor); return lauch_request(request, NO); ... parse stream, call SGML_start(), SGML_data(), SGML_end()... |
COM | Monikers, persistance | um = URLMoniker("http:...") ctx = CreateBindingContext() str = um.bindToStream(ctx) CoCreateInstance(read_uuid(str), &obj, IID_Document)) obj.initFromStream(str) |
M3 network objects | Stable, pickles. | lm = NEW(WebLogManager.T).init(); (* WebLogManager.T <: LogManager.T
*) obj = NEW(Document).init("http://...", r, lm := lm); .. which calls: lm.recover("http://...", log, checkpt) .. obj.readCheckPoint(checkpt) ... Pickle.Read(checkpoint) ... obj.replayLog(log) |
Java | URLConnection, Serialization | |
CORBA | persistance, Externalization | pid = PIDFactory.create_from_key("http://...") obj.restore(pid) /* CosPersistancePO::PO.restore */ /* hmmm... no way to access the persistant data directly!!! */ |
Note that web objects are animated by a variety of software systems on a variety of platforms. HTML works well across systems.
Tricky issue: type fingerprints (a checksum of the type definition). Modula-3, Java, ILU, and probably other use them, but they are specific to the type system. Hence, a persistance format like M3 Pickles or Java Serialization is unsuitable in the common case.
Format Negotiation is negotiation about the persistance format. Note that the APIs of the systems other than the web assume a single persistance format, and lack the equivalent of "accept" headers in their binding parameters.
Format negotiation should not be used for more ambitious purposes like different documents for different screen sizes, user agent capabilities, etc. Or should it? How does PEP relate? Perhaps interface negotiation can be combined with format negotiation; perhaps a contract is a contract is a contract, whether it's about the persistance format, client capabilities, commercial agreements, etc.
Type fingerprints map nicely into URL schemes: m3fingerprint:xxxx, java:xxxx, ilu:xxxx, and they are analagous to DTD system identifiers ala <!doctype html system "http://...">
XML should work well in this capacity as well. Hence an XML parser/generator API should support "marshalling" ala M3 StableGen logs, Java Serialization, CORBA externalization, COM serialization.
See also: an essay on pickling ideas.
Hmmm... both M3 and CORBA have a way of connecting an object to a store such that the store tracks updates to the object (stable.init() and PO.connect, resp.). See also: compound document architectures for update-in-place file formats like Bento and Structured Storage.
@@@@ M3 sources
CORBA persistance, 5.4: OIDs are for sharing, PIDs are not. pom_id: name of POM is passed around at runtime? (analog of clsid?) pre_store/post_store: concurrency?
DDL: ala SGML DTD, ANS.1
System | register class implementation | create instance | generic call |
---|---|---|---|
Web servers | /cgi-bin, config files | opaque | POST, www-form-urlencoded |
Java | class loader | new | apply in reflection API |
CORBA | registration of implementations | BOA::create. Called by implementation. Must provide all interfaces at once. | CORBA DII |
COM | CoRegisterClass | CoCreateInstance, called by client, who asks for any one interface. | IDispatch::invoke
(for example see visual Tcl) |
ILU | ilu_Publish() called by impl (I think) | ??? | ILU_PUBLIC void _ILU_C_GenericCall (ilu_Class class, ilu_Method method, _ILU_C_ExceptionDescription evec, ILU_C_Object *discriminant, ILU_C_ENVIRONMENT *status, char *argdesc, ...); |
Novel ideas in invocation:
@@@@@@@@@@@@
@@ need to review CORBA query service, etc.
@@ review of CORBA security spec ongoing.
See Also: Addressing: URIs, URLs, etc.
Netscape plug-ins have been grandfathered. (i.e. there's a control that runs plugins)