Subject: Re: [Tools-team] Event schema

From: Alex Rousskov <[email-masked]>
Date: Fri, 02 Sep 2005 15:35:23 -0600

On Tue, 2005-08-30 at 09:08 +0200, Henrik Levkowetz wrote:

> ------------------------------------------------------------------------
> element event {
>     element id { xsd:anyURI }		# actually, timebased uuid...
>     & element date { xsd:dateTime }
>     & element source { text }		# tag identifying the source
>     & element object {

What is an "object"? Can there be many objects per event?

If object is specific to events about drafts (as some of the fields
below imply), then we should rename the "object" element to "draft" or
similar.

If we plan to have objects of various kinds (as the type element seems
to imply), then we should delete draft-specific elements from the specs
or comment/specify that they exist only if type==draft.

> 	element type { text }		# tag identifying the type, e.g. draft
> 	& element tag { text }		# draft filename without extension and version
> 	& element date { xsd:date }
> 	& element rev { xsd:integer }
> 	& element authors { text }?
> 	& element title { text }?
> 	& element abstract { text }?
> 	& element state { text }	# a state text tag
> 	& element substate { text }?	# a sub-state text tag
> 	& element pages { xsd:integer }?
> 	& element url { xsd:anyURI }?	# actually, an URL...
> 
>     }
> }
> ------------------------------------------------------------------------

Thank you,

Alex.

_______________________________________________
Tools-team mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/tools-team

---

From: Henrik Levkowetz <[email-masked]>
Date: Sat, 03 Sep 2005 00:04:19 +0200

> What is an "object"? Can there be many objects per event?

Only one, I believe

> or comment/specify that they exist only if type==draft.

The latter has been my thought.  

Mmm.  It might be better, even so, to instead of an object with variants
depending on type specify 
   element draft {...} | element wg {...} | element announcement {...} | ...

Yes, I think I'll change to that.

	Henrik

---

From: Henrik Levkowetz <[email-masked]>
Date: Sat, 03 Sep 2005 00:47:55 +0200

> Yes, I think I'll change to that.

First cut at this:

# ----------------------------------------------------------------------
element event {
    element id { xsd:anyURI }		# actually, timebased uuid...
    & element date { xsd:dateTime }
    & element source { text }		# tag identifying the source

    # Optional elements
    & element url { xsd:anyURI }?	# actually, and URL

    # The object that the event is related to
        # --- draft ---
    & ( element draft {
	  element tag { text }		# draft filename without extension and version
	  & element date { xsd:date }
	  & element rev { xsd:integer }
	  & element state { 
	      attribute sub { text },	# a substate text tag
	      text			# a state text tag
	  }

	  # Optional elements
	  & element authors { text }?
	  & element title { text }?
	  & element abstract { text }?
	  & element pages { xsd:integer }?
	  & element rfc { xsd:integer }?
	  & element url { xsd:anyURI }?	# actually, an URL...
        }
	# --- wg ---
      | element wg {
	  element tag { text }		# wg acronym
	  & element name { text }
	  & element action { text }	# charter, re-charter, conclude ...
	  & element chair { 
	      element name { text },
	      element email { text }	# email ...
	    }+
	  & element charter { text }
	  & element list {
	      element email { text }
	      & element archive { xsd:anyURI }
	      & element subscribe { xsd:anyURI }?
	    }
	  & element area { 
	      element name { text }
	      & element ad {
	          element name { text },
		  element email { text }# email ...
	        }+
	      & element advisor {
	          element name { text },
		  element email { text }# email ...
	        }+
	    }
	}
	# --- area ---
      | element area { 
	  element name { text }
	  & element ad {
	      element name { text },
	      element email { text }# email ...
	    }+
	  & element advisor {
	      element name { text },
	      element email { text }# email ...
	    }+
	}
	# --- announcement ---
      | element announcement {
	  element date { xsd:date }
	  & element text { text }
        }
      )
}
# ----------------------------------------------------------------------

---

From: Henrik Levkowetz <[email-masked]>
Date: Wed, 07 Sep 2005 04:37:44 +0200

# Here's the next iteration on an event schema.  I'm using
# full-blown objects inside the events, and I've refined both
# events and object schemas.  
#
# Any element which has an attribute 'key' may be looked
# up using the value as a key under the category given by
# the element name in an envisioned meta-information repository.
#
# Any element which has an attribute 'changed' when occurring
# in an event has a new value.  After messing about with different
# event types (state-change, new-revision, new-charter, etc.) I
# decided it would be better to eliminate that concept, and
# simply indicate which parts of a draft, wg, etc. meta-information
# has changed.
#
# When an object (e.g., a draft) occurs as part of an event, there
# is no need for it to contain more than the key and the changed
# information, as long as it is possible to look up the complete
# set of information in a reasonably simple manner (both for tools
# and humans).
#
#	Henrik

start = (event | draft | wg | area | announcement )

event =
    element event {
	element id { attribute key, uuid }
	& element date { xsd:dateTime }
	& element source { 
	    attribute key,
	    ("tracker"
	     | "rfc-queue"
	     | "id-announce"
	     | "ietf-announce"
	     | "internet-drafts"
	     | "rfc"
	     | text)				# tag identifying the source
	}
	& element url { xsd:httpURI }?	
	& element comment { text }
	& ( draft | wg | area | announcement )
    }

draft =
    element draft {
	element tag { attribute key, text }
	& element date { attribute changed?, xsd:date }
	& element rev { attribute changed?, xsd:integer }

	# Optional elements
	& element author { attribute changed?, person }*
	& element title { attribute changed?, text }?
	& element abstract { attribute changed?, text }?
	& element pages { attribute changed?, xsd:integer }?
	& element url { attribute changed?, httpURI }?
	& element events { list { uuid } }
	& wg
    }

wg =
    element wg {
	attribute changed?, 
	element tag { attribute key, text }		# acronym
	& element name { attribute changed?, text }
	& element chair { attribute changed?, person }+
	& element charter { attribute changed?, text }
	& element list {
	    attribute changed?, 	    
	    element email { text }
	    & element archive { xsd:httpURI }
	    & element subscribe { xsd:httpURI }?
	  }?
	& element area { 
	    attribute changed?, 
	    "app" | "gen" | "int" | "ops" | "rtg" | "sec" | "tsv"
	  }
	& element events { list { uuid } }
    }

area = 
    element area { 
	element tag { attribute key, text }		# acronym
	element name { attribute changed?, text }
	& element ad { attribute changed?, person }+
	& element advisor { attribute changed?, person }+
	& element events { list { uuid } }
    }

announcement = 
    element announcement {

person = 
    element name { text },
    element email { attribute key?, email }+,
    element company { text }?,
    element phone { text }*,
    element address { text }?

httpURI = xsd:anyURI {pattern = "http://.*"}

hexDigit = xsd:token {pattern = "[0-9a-zA-Z]"}

uuid = xsd:anyURI {pattern = "uuid:\p{hexDigit}{8}-\p{hexDigit}{4}-\p{hexDigit}{4}-\p{hexDigit}{4}-\p{hexDigit}{12}"}

email = xsd:token {pattern = "[A-Za-z0-9.-]+@[A-Za-z0-9.-]+"}