Re[2]: [Eas-dev-rus] Вопросы по CODB

Uri uri на itk.ru
Вт Фев 10 11:46:15 MSK 2004


On Tue, 10 Feb 2004, Igor Satsyuk wrote:

> U> Я не шутил. Патент делался через посредников.
> U> Процесс регистрации длительный и может занимать около года.
> U> Только что я получил факс с регистрацией и сообщение что
> U> документы ушли в мою сторону курьерской почтой.
> U> Как только придет, могу отсканировать и выложить.
> U> Нада ?
> Нада!

Вот теперь собственно дождавшись документов, могу и опубликоывать
содержание.

Вот этот вариант был отправлен в адвокатскую контору,
возможно формулировка была слегка изменена под их требования
к оформлению патентов.

Method of storing objects in RDBMS

All existent methods of building ODB using RDBMS storage are based on a
number of ways in which information is stored in "attribute name ->
attribute value" form.

Classic method uses tables whose field names represent object’s
attribute names, and field values represent attribute values.

Shortcomings:

^ч         ^ч         Each class of objects requires separate table

^ч         ^ч         Number of object attributes is limited by number of
table fields preset in the table

^ч         ^ч         Types of attributes are limited to those RDBMS
supports

^ч         ^ч         Changing object structure requires changing SQL
queries, rebuilding tables and reprogramming the source code of a program

^ч         ^ч         Complicated preserving method of objects uniqueness
in different databases

This method doesn't provide any advantages opposed to regular SQL views,
only some kind of "pseudo-object" data views for developers.

In more advanced method, objects are stored in one table containing two
fields: attribute name and attribute value.

One object is stored in several rows depending on a number of object
attributes.

Shortcomings with advanced method:

^ч         ^ч         Very slow performance of object read queries, for
an object is formed from a number of table rows. Optimization of such
queries in RDBMS is complicated

^ч         ^ч         The size of table grows very fast, for each object
may require several records. This call for high load on optimization
which translates to slower performance of database.

^ч         ^ч         RDBMS does not allow storing data of different
types. Since an object can have data of various kinds, extra actions and
code is required.

^ч         ^ч         Problematical maintenance of data integrity,
triggers and good transactional model is required.

This method is more applicable for OOP demands, but very difficult in
optimization on RDBMS queries level.

The method that is being patented is based on storing objects in BLOB
(MEMO on some databases) fields as binary data. In this case the whole
object is stored in one place and system resources use for
reading/writing objects is minimal.

Main principles of patented method:

^ч         ^ч         Minimal and indivisible unit of stored data is
object

^ч         ^ч         Particular case of object is metaobject - object
used by ODB core for its own purposes. Metaobject is used for storing
description of attributes, data types, indexes, classes and their
hierarchy, triggers, methods and other data depending of implementation

^ч         ^ч         Metaobjects are stored in the same way as objects

^ч         ^ч         Correlation of all stored objects is called
depository

^ч         ^ч         Correlation of all metaobjects is called dictionary

^ч         ^ч         As every DBMS does, ODB should provide all basic
data operations: inserts, alteration, removal and object filtering. Also,
it should provide such common operations as transactions, trigger
execution, procedures and methods (ODB unique)

All these operations are provided by ODB engine. Also, ODB engine
provides data mapping to table structures implicitly.

ODB engine diagram:

    |--------------|            |----------------|        |-------------|
    |              | operation  |      ODB       |        |             |
    |    Object    | ---------->|                |<-------|  metadata   |
    |              |            |      engine    |        |             |
    |--------------|            |----------------|        |-------------|
				  | | | |      |
   |----<-------------------------| | | |      |
   |  |--<-----------------------| | |      | marshalling
   |  |           |---<------------| |      |------>-----|
   |  |           |                  |                   |
   |  |           |                  |                   |
----------------------------.......----------------------------------------
ID obj| ID type |  data1  |        |  dataN  |  BLOB - object body
------|---------|---------|--------|---------|-----------------------------
      |         |         |        |         | attr_name1:attr_value1
      |         |         |        |         | attr_name2:attr_value1
000001| type1   | index1  |        | indexN  | attr_name3:attr_value1
      |         |         |        |         | attr_name4:attr_value1
      |         |         |        |         | ......................
      |         |         |        |         | attr_nameN:attr_valueN
----------------------------.......--------------------------------------

Diagram explanations:

^ч         ^ч         Engine receives an object and operation. Object
could come to the engine via SQL queries, programming language
constructions, XML documents, as a delimited string, and other ways

^ч         ^ч         Operation contains type (adding, modifying,
deleting atc) and type/class of an object. Type/class of object could be
contained within an object

^ч         ^ч         Engine extracts object's type/class definition from
dictionary, and according to it does the following:

^ч         ^ч         In case of adding new object generates object's ID

^ч         ^ч         Finds out which type/class the object is

^ч         ^ч         Checks object for any conflicts with metadata and
corrects object if necessary, e.g. fills absent attributes with default
values. In the case if dictionary is absent inspection is not performed

^ч         ^ч         Calculates index key values and puts them into the
table. If tables and indexes don't support indexes with unidentified
type, engine converts key values to those supported by RDBMS, string type
for example, which is supported by every RDBMS. In the case of absence of
dictionary index keys could be calculated accordingly to statistical
knowledge about using attributes in queries

^ч         ^ч         Does marshalling of object to byte sequence and
writes encoded object to the BLOB field. Marshalling operation depends on
programming language and RDBMS capabilities. In particularity, object
could be encoded to the delimited string. Such kind of encoding takes
minimal processor time. In addition, encoding operation could produce
compression and encryption, if necessary.

^ч         ^ч         Finds object with ID in database and writes all its
components: id_obj,id_type,data1...dataN, BLOB

Read operation is performed in reversed order:

^ч         ^ч         Encoded object is pulled from BLOB

^ч         ^ч         Object is decoded

^ч         ^ч         Object is then passed to a user in required form:
XML, programming language

^ч         ^ч         constructions, SQL response or any other form,
depending on implementation

Filter operation is performed like SELECT query in SQL RDBMS:

^ч         ^ч         Parsing of query string and filter expression

^ч         ^ч         Changing real attribute names to the inner names:
data1, data2, ..., dataN, corresponding to the metadata

Further operations use existing RDBMS mechanisms:

^ч         ^ч         Optimization of an expression

^ч         ^ч         Selecting rows meeting the condition(s)

^ч         ^ч         Depending on the query, intersection, merging and
other operations are performed

During the execution of any operation ODB engine could execute triggers,
object methods or object-oriented procedures, described in the
dictionary.

Described method of storing objects in BLOB allows storing objects of any
form, type or content. This method allows using attributes of any type,
including these not supporting by RDBMS.

Patented method lacks all the problems described above and provides new
possibilities:

^ч         ^ч         Subject sphere and classes/methods structure
descriptions are stored in the form of metaobjects in ODB dictionary.
Metadata are the same objects and are managed by the same means.
Documentation of subject sphere becomes a part of ODB. CASE/UML means id
used for metadata managing

^ч         ^ч         ODB performs object validation on the metadata
level, decreasing probability of developer errors and amount of coding
needed

^ч         ^ч         When class descriptions or metadata are changed,
conversion of objects to the new structure is not necessary. Such
conversion could be made during object read

^ч         ^ч         Selecting objects, meeting some condition is
performed by one simple query and could be easily optimized by RDBMS

^ч         ^ч         Object reading/writing is performed by one simple
query

^ч         ^ч         Patented method allows storing objects in almost
any RDBMS with minimal functions requirements. Supporting triggers,
stored procedures, complex transactional model, views and built in
language is not necessary

^ч         ^ч         Minimal requirements to the support of data
integrity in RDBMS

^ч         ^ч         ODB could be designed as a server or simple DBMS
based on formats like DBF with BLOB support as well as XML files with
special tags for indexing

^ч         ^ч         Unique identification of all objects and
metaobjects could be made easily on ODB engine level, what allows
operating with references and IDs only which decreases amount of complex
queries to RDBMS

Patented method can be used for:

^ч         ^ч         Creating libraries for programming languages

^ч         ^ч         Creating object or object oriented application
server

^ч         ^ч         Upgrading existing RDBMS to support object
extensions

^ч         ^ч         Creating object OLAP/OLTP servers

^ч         ^ч         Creating distributed systems for storing, caching
and synchronizing objects of any complexity on the ground of unique
identification, provided by ODB engine





Подробная информация о списке рассылки Eas-dev-rus