You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Ole Ersoy <ol...@gmail.com> on 2007/04/09 20:20:10 UTC

[Schema] ObjectClass DN Correct?

When adding a new ObjectClass to the Schema
named "org.apache.tuscany.User"
is this how I do the DN?:

DN: objectClass=org.apache.tuscany.User, ou=objectClasses, ou=Schema

Thanks,
- Ole


Re: [Schema] ObjectClass DN Correct?

Posted by Alex Karasulu <ak...@apache.org>.
Wow thanks for pointing me to the the schema browser from right clicking the
connection.  I did not discover this before.

Thanks,
Alex

On 4/10/07, Stefan Seelmann <se...@apache.org> wrote:
>
> Alex Karasulu schrieb:
>
> > Yeah it's really good stuff.  But don't try to use the schema browser
> > now because I don't think it pulls the schema of the server.  What
> > you're looking at in the schema browser are the schema elements in
> > schema files.
> >
> > Correct me if I am wrong Stefan.
> >
>
> Sure ;)
>
> There are two kind of schema stuff in LS:
>
> 1st the Schemas Editor plugin with its own "Schemas" perspective. It is
> used to edit schema files in OpenLDAP format, atm only offline. It looks
> like this:
>
> http://directory.apache.org/ldapstudio/screenshots.data/Schemas_Editor_Plugin.png
>
> 2nd the Schema Browser that is part of the Browser plugin. It shows the
> schema from the server (from the subschemSubentry). To open it just
> rightclick the connection and select "Open Schema Browser". It looks
> like this:
>
> http://directory.apache.org/ldapstudio/static/users_guide/ldap_browser/tools_schema_browser_overview.html
>
>
> >     Incidentally, do you know (Stefan?) if LDAP Studio
> >     has a Schema drill down "Outline View" like the one
> >     in JXPlorer?  I think in JXPlorer (Just from looking
> >     at the "Writing Java Objects to ApacheDS Part1" article),
> >     has a Schema tab, and below it one can drill down into
> >     the various Schema nodes.  I looked LDAP Studio Schema Browser,
> >     and noticed the tabs with Schema node categories, and I was thinking
> >     that it would probably trigger a drill down view in the outline
> pane...
>
> Ok, the LS Schema Browser doesn't have a drill down outline. But I think
> it shows all information that JXplorer shows.
>
> The tree in JXplorer has tree levels:
>   1st "schema"
>     2nd category like objectClasses or attributeTypes
>       3rd the concrete schema element like person or cn
> When selecting the concrete schema element all its details are displayed
> in the right frame.
>
> In LS you could select the category using the tabs. Each tab contains a
> a master detail view. On the left side there is a list with all
> available objectClasses, when selecting one the details are displayed on
> the right side. You could click the links in the detail part to jump to
> the corresponding schema elements and you could use the history
> navigation to jump back/forward.
>
> Could you please describe how such a drill down outline could look like?
>
> Regards,
> Stefan
>
>
>

Re: [Schema] ObjectClass DN Correct?

Posted by Pierre-Arnaud Marcelot <pa...@marcelot.net>.
> I think the Schemas Editor plugin works in that way. Please take a look
> at it. Once it is extended to load and edit the schema directly from the
> server you will have what you want :)


Exactly, that's the next step. We need to separate some UI elements used in
the Schemas Editor Plugin in another project, so we can use already existing
editors in both the Standard Schemas Editor (based on files) and the Schemas
Editor for ADS.

As Stefan suggested me on IM yesterday, we also need to write an extension
point and then add a Schema File Wrapper and an ADS Schema Wrapper as
extensions.

Then It will be easy for third parties to add another extension point of
their choice, for editing  the schemas of OpenLDAP or SunDS for example, if
they want to.

It may be too short to have that for ApacheCon, but it will be my next
priority, just after the Apache DS configuration Editor.

Pierre-Arnaud

Re: [Schema] ObjectClass DN Correct?

Posted by Ole Ersoy <ol...@gmail.com>.

SNIP

> I think the Schemas Editor plugin works in that way. Please take a look
> at it. Once it is extended to load and edit the schema directly from the
> server you will have what you want :)

Saweeett!

> The Schema Browser works more generic, it works (should work) with every
> LDAP directory server. It reads the schema from the subschemaSubentry,
> that is described in the attribute subschemaSubentry of the RootDSE. In
> ADS this is "cn=schema", not the "cn", not "ou". And it is a read-only
> view. If you don't see the RootDSE and the cn=schema entry with LS
> please enable the option "Show Directory Metadata" in the LDAP Browser view.

Yes - Got it :-)
> 
> Stefan
> 

Wow - That rocks!

Thanks Stefan,
- Ole


> 

Re: [Schema] ObjectClass DN Correct?

Posted by Stefan Seelmann <se...@apache.org>.
Ole Ersoy schrieb:
> Hi Stefan,
> 
> ..  The only reason I would
> use something like an outline view is so I can see
> all the Schema name components.
> 
> Like "ou=objectClasses, ou=tuscany, ou=schema"
> 
> So in this case I imagined that when I opened the Schema Browser
> the outline view would have ou=schema at the root.
> Then I could drill down into the subcontexts, like
> ou=tuscany
> ou=core
> ou=ecore
> 
> etc.
> 
> Then their subcontext (ObjectClasses, AttributeTypes, Syntaxes).  The
> properties view would be used to display
> the attributes of entry.
> 
> That's just a two second imagineering :-)
> 
> Does it make any sense?
> 

Sure, that makes sense.

What you describe is ApacheDS specific. Only ADS has the dynamic schema
under ou=schema and only ADS has that structure.

I think the Schemas Editor plugin works in that way. Please take a look
at it. Once it is extended to load and edit the schema directly from the
server you will have what you want :)

The Schema Browser works more generic, it works (should work) with every
LDAP directory server. It reads the schema from the subschemaSubentry,
that is described in the attribute subschemaSubentry of the RootDSE. In
ADS this is "cn=schema", not the "cn", not "ou". And it is a read-only
view. If you don't see the RootDSE and the cn=schema entry with LS
please enable the option "Show Directory Metadata" in the LDAP Browser view.

Stefan


Re: [Schema] ObjectClass DN Correct?

Posted by Ole Ersoy <ol...@gmail.com>.
Hi Stefan,

Thanks for all the elaboration.

SNIP
> Could you please describe how such a drill down outline could look like?

The current Schema Browser is excellent btw.  The only reason I would
use something like an outline view is so I can see
all the Schema name components.

Like "ou=objectClasses, ou=tuscany, ou=schema"

So in this case I imagined that when I opened the Schema Browser
the outline view would have ou=schema at the root.
Then I could drill down into the subcontexts, like
ou=tuscany
ou=core
ou=ecore

etc.

Then their subcontext (ObjectClasses, AttributeTypes, Syntaxes).  The 
properties view would be used to display
the attributes of entry.

That's just a two second imagineering :-)

Does it make any sense?

Thanks again,
- Ole



> 
> Regards,
> Stefan
> 
> 
> 

Re: [Schema] ObjectClass DN Correct?

Posted by Stefan Seelmann <se...@apache.org>.
Alex Karasulu schrieb:

> Yeah it's really good stuff.  But don't try to use the schema browser
> now because I don't think it pulls the schema of the server.  What
> you're looking at in the schema browser are the schema elements in
> schema files.
> 
> Correct me if I am wrong Stefan.
> 

Sure ;)

There are two kind of schema stuff in LS:

1st the Schemas Editor plugin with its own "Schemas" perspective. It is
used to edit schema files in OpenLDAP format, atm only offline. It looks
like this:
http://directory.apache.org/ldapstudio/screenshots.data/Schemas_Editor_Plugin.png

2nd the Schema Browser that is part of the Browser plugin. It shows the
schema from the server (from the subschemSubentry). To open it just
rightclick the connection and select "Open Schema Browser". It looks
like this:
http://directory.apache.org/ldapstudio/static/users_guide/ldap_browser/tools_schema_browser_overview.html


>     Incidentally, do you know (Stefan?) if LDAP Studio
>     has a Schema drill down "Outline View" like the one
>     in JXPlorer?  I think in JXPlorer (Just from looking
>     at the "Writing Java Objects to ApacheDS Part1" article),
>     has a Schema tab, and below it one can drill down into
>     the various Schema nodes.  I looked LDAP Studio Schema Browser,
>     and noticed the tabs with Schema node categories, and I was thinking
>     that it would probably trigger a drill down view in the outline pane...

Ok, the LS Schema Browser doesn't have a drill down outline. But I think
it shows all information that JXplorer shows.

The tree in JXplorer has tree levels:
  1st "schema"
    2nd category like objectClasses or attributeTypes
      3rd the concrete schema element like person or cn
When selecting the concrete schema element all its details are displayed
in the right frame.

In LS you could select the category using the tabs. Each tab contains a
a master detail view. On the left side there is a list with all
available objectClasses, when selecting one the details are displayed on
the right side. You could click the links in the detail part to jump to
the corresponding schema elements and you could use the history
navigation to jump back/forward.

Could you please describe how such a drill down outline could look like?

Regards,
Stefan



Re: [Schema] ObjectClass DN Correct?

Posted by Ole Ersoy <ol...@gmail.com>.
Hey Alex,


SNIP
> My point to you was to just browse the ou=schema partition which 
> basically displays the schema elements using a meta schema that 
> describes schema entities.  

Coollll (It's my word of the day :-) )

> It's very easy while browsing this area to 
> understand the structure of the tree there and infer the schema used.
> 
> By 
> doing this you can use LDAP to more efficiently query the schema 
> information when you cannot do the same under the schemaSubentry which 
> is the mechanism supported by the LDAP standard.

Aha!  Even more cooolll.
> 
>     Hope your cold gets better soon.  I always chomp on a clove of Raw
>     Garlic (It releases a very powerful antibiotic when crushed - has to be
>     raw though).  It's also great if people are inviting you to too many
>     meetings at work :-)
> 
> 
> Oh thanks Ole but I am a vampire so that might not be so good for me.

Yeeaaah - I thought you looked a little pale in the fishing 
pictures...especially for someone living in Florida :-)

Thanks,
- Ole

> 
> :)
> 
> Regards,
> Alex
>  
> 
>     Thanks,
>     - Ole
> 
> 
>     Alex Karasulu wrote:
>      > Stefan is absolutely correct here.  Take a minute and start ADS 1.5.0
>      > and use LDAP Studio to browse the schema partition (ou=schema).  By
>      > browsing this partition you'll see the proper patterns required.
>      >
>      > Alex
>      >
>      > On 4/9/07, *Stefan Seelmann* < seelmann@apache.org
>     <ma...@apache.org>
>      > <mailto:seelmann@apache.org <ma...@apache.org>>> wrote:
>      >
>      >     Hi Ole,
>      >
>      >      > When adding a new ObjectClass to the Schema
>      >      > named "org.apache.tuscany.User"
>      >
>      >     An objectClass or attributeType name must be an OID (object
>     identifier),
>      >     that is defined as follows in RFC4512:
>      >       oid = descr / numericoid
>      >       descr = keystring
>      >       keystring = leadkeychar *keychar
>      >       leadkeychar = ALPHA
>      >       keychar = ALPHA / DIGIT / HYPHEN
>      >       numericoid = number 1*( DOT number )
>      >       ... and so on
>      >
>      >     So your name could be either something like
>      >       0.11.222.3333.44444
>      >     or
>      >       org-apache-tuscany-User
>      >
>      >
>      >      > is this how I do the DN?:
>      >      >
>      >      > DN: objectClass=org.apache.tuscany.User, ou=objectClasses,
>     ou=Schema
>      >      >
>      >
>      >     The DNs of the other objectclases in the schema looks like this:
>      >       "m-oid= 2.5.6.5 <http://2.5.6.5>
>     <http://2.5.6.5>,ou=objectClasses,cn=core,ou=schema"
>      >
>      >     So I would recommend to create your own schema suffix under
>     ou=schema
>      >     where you could put the DAS schema. Here is an example in
>     LDIF format,
>      >     how this could look like:
>      >
>      >     ----------------------------------------------
>      >     dn: cn=ecore,ou=schema
>      >     objectClass: metaSchema
>      >     objectClass: top
>      >     cn: ecore
>      >     m-dependencies: core
>      >     m-dependencies: system
>      >
>      >     dn: ou=objectClasses,cn=ecore,ou=schema
>      >     objectClass: organizationalUnit
>      >     objectClass: top
>      >     ou: objectClasses
>      >
>      >     dn: m-oid=0.11.222.3333.44444
>     ,ou=objectClasses,cn=ecore,ou=schema
>      >     objectClass: metaObjectclass
>      >     objectClass: metaTop
>      >     objectClass: top
>      >     m-oid: 0.11.222.3333.44444
>      >     m-description: org.apache.tuscany.User
>      >     m-must: cn
>      >     m-name: org-apache-tuscany-User
>      >     m-obsolete: FALSE
>      >     m-supObjectClass: top
>      >     m-typeObjectClass: AUXILIARY
>      >     ----------------------------------------------
>      >
>      >
>      >     BTW, the new schema feature is really cool. Once you have
>     created the
>      >     "ou=objectClasses,cn=ecore,ou=schema" entry you could add new
>     schema
>      >     elements by adding simple string values to cn=schema:
>      >
>      >     -------------------------------------------
>      >     dn: cn=schema
>      >     changetype: modify
>      >     add: objectClasses
>      >     objectClasses: ( 0.11.222.3333.44444 NAME
>     'org-apache-tuscany-User'
>      >     DESC 'org.apache.tuscany.User' SUP top AUXILIARY MUST cn
>      >     X-SCHEMA 'ecore' )
>      >     -
>      >     -------------------------------------------
>      >
>      >
>      >     Regards,
>      >     Stefan
>      >
>      >
> 
> 

Re: [Schema] ObjectClass DN Correct?

Posted by Alex Karasulu <ak...@apache.org>.
Hi Ole

On 4/10/07, Ole Ersoy <ol...@gmail.com> wrote:
>
> Thanks Alex,
>
> LDAP Studio is so nice, I'm almost scared to look.


Yeah it's really good stuff.  But don't try to use the schema browser now
because I don't think it pulls the schema of the server.  What you're
looking at in the schema browser are the schema elements in schema files.

Correct me if I am wrong Stefan.

Incidentally, do you know (Stefan?) if LDAP Studio
> has a Schema drill down "Outline View" like the one
> in JXPlorer?  I think in JXPlorer (Just from looking
> at the "Writing Java Objects to ApacheDS Part1" article),
> has a Schema tab, and below it one can drill down into
> the various Schema nodes.  I looked LDAP Studio Schema Browser,
> and noticed the tabs with Schema node categories, and I was thinking
> that it would probably trigger a drill down view in the outline pane...


Yeah again I think you need to know that the schema browser browses the
entities in schema files loaded by the plugin.  It does not display the
schema elements that are in the server that it is connected to.  I think the
LS team will soon display this information as well.

My point to you was to just browse the ou=schema partition which basically
displays the schema elements using a meta schema that describes schema
entities.  It's very easy while browsing this area to understand the
structure of the tree there and infer the schema used.

This area is very much like the system tables in oracle which describe data
types and other schema elements.  We use entries to describe schema entities
here.  This kind of structure is used as the master copy of schema
information in the server.  Changes to these entries will be directly
reflected in the schemaSubentry of the server (cn=schema).  The nice thing
about this structure is that we've parameterized the schema information
rather than leaving it as one big text description.  By doing this you can
use LDAP to more efficiently query the schema information when you cannot do
the same under the schemaSubentry which is the mechanism supported by the
LDAP standard.

Hope your cold gets better soon.  I always chomp on a clove of Raw
> Garlic (It releases a very powerful antibiotic when crushed - has to be
> raw though).  It's also great if people are inviting you to too many
> meetings at work :-)


Oh thanks Ole but I am a vampire so that might not be so good for me.

:)

Regards,
Alex


Thanks,
> - Ole
>
>
> Alex Karasulu wrote:
> > Stefan is absolutely correct here.  Take a minute and start ADS 1.5.0
> > and use LDAP Studio to browse the schema partition (ou=schema).  By
> > browsing this partition you'll see the proper patterns required.
> >
> > Alex
> >
> > On 4/9/07, *Stefan Seelmann* <seelmann@apache.org
> > <ma...@apache.org>> wrote:
> >
> >     Hi Ole,
> >
> >      > When adding a new ObjectClass to the Schema
> >      > named "org.apache.tuscany.User"
> >
> >     An objectClass or attributeType name must be an OID (object
> identifier),
> >     that is defined as follows in RFC4512:
> >       oid = descr / numericoid
> >       descr = keystring
> >       keystring = leadkeychar *keychar
> >       leadkeychar = ALPHA
> >       keychar = ALPHA / DIGIT / HYPHEN
> >       numericoid = number 1*( DOT number )
> >       ... and so on
> >
> >     So your name could be either something like
> >       0.11.222.3333.44444
> >     or
> >       org-apache-tuscany-User
> >
> >
> >      > is this how I do the DN?:
> >      >
> >      > DN: objectClass=org.apache.tuscany.User, ou=objectClasses,
> ou=Schema
> >      >
> >
> >     The DNs of the other objectclases in the schema looks like this:
> >       "m-oid=2.5.6.5 <http://2.5.6.5
> >,ou=objectClasses,cn=core,ou=schema"
> >
> >     So I would recommend to create your own schema suffix under
> ou=schema
> >     where you could put the DAS schema. Here is an example in LDIF
> format,
> >     how this could look like:
> >
> >     ----------------------------------------------
> >     dn: cn=ecore,ou=schema
> >     objectClass: metaSchema
> >     objectClass: top
> >     cn: ecore
> >     m-dependencies: core
> >     m-dependencies: system
> >
> >     dn: ou=objectClasses,cn=ecore,ou=schema
> >     objectClass: organizationalUnit
> >     objectClass: top
> >     ou: objectClasses
> >
> >     dn: m-oid=0.11.222.3333.44444 ,ou=objectClasses,cn=ecore,ou=schema
> >     objectClass: metaObjectclass
> >     objectClass: metaTop
> >     objectClass: top
> >     m-oid: 0.11.222.3333.44444
> >     m-description: org.apache.tuscany.User
> >     m-must: cn
> >     m-name: org-apache-tuscany-User
> >     m-obsolete: FALSE
> >     m-supObjectClass: top
> >     m-typeObjectClass: AUXILIARY
> >     ----------------------------------------------
> >
> >
> >     BTW, the new schema feature is really cool. Once you have created
> the
> >     "ou=objectClasses,cn=ecore,ou=schema" entry you could add new schema
> >     elements by adding simple string values to cn=schema:
> >
> >     -------------------------------------------
> >     dn: cn=schema
> >     changetype: modify
> >     add: objectClasses
> >     objectClasses: ( 0.11.222.3333.44444 NAME 'org-apache-tuscany-User'
> >     DESC 'org.apache.tuscany.User' SUP top AUXILIARY MUST cn
> >     X-SCHEMA 'ecore' )
> >     -
> >     -------------------------------------------
> >
> >
> >     Regards,
> >     Stefan
> >
> >
>

Re: [Schema] ObjectClass DN Correct?

Posted by Ole Ersoy <ol...@gmail.com>.
Thanks Alex,

LDAP Studio is so nice, I'm almost scared to look.

Incidentally, do you know (Stefan?) if LDAP Studio
has a Schema drill down "Outline View" like the one
in JXPlorer?  I think in JXPlorer (Just from looking
at the "Writing Java Objects to ApacheDS Part1" article),
has a Schema tab, and below it one can drill down into
the various Schema nodes.  I looked LDAP Studio Schema Browser,
and noticed the tabs with Schema node categories, and I was thinking
that it would probably trigger a drill down view in the outline pane...

Hope your cold gets better soon.  I always chomp on a clove of Raw 
Garlic (It releases a very powerful antibiotic when crushed - has to be
raw though).  It's also great if people are inviting you to too many 
meetings at work :-)

Thanks,
- Ole


Alex Karasulu wrote:
> Stefan is absolutely correct here.  Take a minute and start ADS 1.5.0 
> and use LDAP Studio to browse the schema partition (ou=schema).  By 
> browsing this partition you'll see the proper patterns required. 
> 
> Alex
> 
> On 4/9/07, *Stefan Seelmann* <seelmann@apache.org 
> <ma...@apache.org>> wrote:
> 
>     Hi Ole,
> 
>      > When adding a new ObjectClass to the Schema
>      > named "org.apache.tuscany.User"
> 
>     An objectClass or attributeType name must be an OID (object identifier),
>     that is defined as follows in RFC4512:
>       oid = descr / numericoid
>       descr = keystring
>       keystring = leadkeychar *keychar
>       leadkeychar = ALPHA
>       keychar = ALPHA / DIGIT / HYPHEN
>       numericoid = number 1*( DOT number )
>       ... and so on
> 
>     So your name could be either something like
>       0.11.222.3333.44444
>     or
>       org-apache-tuscany-User
> 
> 
>      > is this how I do the DN?:
>      >
>      > DN: objectClass=org.apache.tuscany.User, ou=objectClasses, ou=Schema
>      >
> 
>     The DNs of the other objectclases in the schema looks like this:
>       "m-oid=2.5.6.5 <http://2.5.6.5>,ou=objectClasses,cn=core,ou=schema"
> 
>     So I would recommend to create your own schema suffix under ou=schema
>     where you could put the DAS schema. Here is an example in LDIF format,
>     how this could look like:
> 
>     ----------------------------------------------
>     dn: cn=ecore,ou=schema
>     objectClass: metaSchema
>     objectClass: top
>     cn: ecore
>     m-dependencies: core
>     m-dependencies: system
> 
>     dn: ou=objectClasses,cn=ecore,ou=schema
>     objectClass: organizationalUnit
>     objectClass: top
>     ou: objectClasses
> 
>     dn: m-oid=0.11.222.3333.44444 ,ou=objectClasses,cn=ecore,ou=schema
>     objectClass: metaObjectclass
>     objectClass: metaTop
>     objectClass: top
>     m-oid: 0.11.222.3333.44444
>     m-description: org.apache.tuscany.User
>     m-must: cn
>     m-name: org-apache-tuscany-User
>     m-obsolete: FALSE
>     m-supObjectClass: top
>     m-typeObjectClass: AUXILIARY
>     ----------------------------------------------
> 
> 
>     BTW, the new schema feature is really cool. Once you have created the
>     "ou=objectClasses,cn=ecore,ou=schema" entry you could add new schema
>     elements by adding simple string values to cn=schema:
> 
>     -------------------------------------------
>     dn: cn=schema
>     changetype: modify
>     add: objectClasses
>     objectClasses: ( 0.11.222.3333.44444 NAME 'org-apache-tuscany-User'
>     DESC 'org.apache.tuscany.User' SUP top AUXILIARY MUST cn
>     X-SCHEMA 'ecore' )
>     -
>     -------------------------------------------
> 
> 
>     Regards,
>     Stefan
> 
> 

Re: [Schema] ObjectClass DN Correct?

Posted by Alex Karasulu <ak...@apache.org>.
Stefan is absolutely correct here.  Take a minute and start ADS 1.5.0 and
use LDAP Studio to browse the schema partition (ou=schema).  By browsing
this partition you'll see the proper patterns required.

Alex

On 4/9/07, Stefan Seelmann <se...@apache.org> wrote:
>
> Hi Ole,
>
> > When adding a new ObjectClass to the Schema
> > named "org.apache.tuscany.User"
>
> An objectClass or attributeType name must be an OID (object identifier),
> that is defined as follows in RFC4512:
>   oid = descr / numericoid
>   descr = keystring
>   keystring = leadkeychar *keychar
>   leadkeychar = ALPHA
>   keychar = ALPHA / DIGIT / HYPHEN
>   numericoid = number 1*( DOT number )
>   ... and so on
>
> So your name could be either something like
>   0.11.222.3333.44444
> or
>   org-apache-tuscany-User
>
>
> > is this how I do the DN?:
> >
> > DN: objectClass=org.apache.tuscany.User, ou=objectClasses, ou=Schema
> >
>
> The DNs of the other objectclases in the schema looks like this:
>   "m-oid=2.5.6.5,ou=objectClasses,cn=core,ou=schema"
>
> So I would recommend to create your own schema suffix under ou=schema
> where you could put the DAS schema. Here is an example in LDIF format,
> how this could look like:
>
> ----------------------------------------------
> dn: cn=ecore,ou=schema
> objectClass: metaSchema
> objectClass: top
> cn: ecore
> m-dependencies: core
> m-dependencies: system
>
> dn: ou=objectClasses,cn=ecore,ou=schema
> objectClass: organizationalUnit
> objectClass: top
> ou: objectClasses
>
> dn: m-oid=0.11.222.3333.44444,ou=objectClasses,cn=ecore,ou=schema
> objectClass: metaObjectclass
> objectClass: metaTop
> objectClass: top
> m-oid: 0.11.222.3333.44444
> m-description: org.apache.tuscany.User
> m-must: cn
> m-name: org-apache-tuscany-User
> m-obsolete: FALSE
> m-supObjectClass: top
> m-typeObjectClass: AUXILIARY
> ----------------------------------------------
>
>
> BTW, the new schema feature is really cool. Once you have created the
> "ou=objectClasses,cn=ecore,ou=schema" entry you could add new schema
> elements by adding simple string values to cn=schema:
>
> -------------------------------------------
> dn: cn=schema
> changetype: modify
> add: objectClasses
> objectClasses: ( 0.11.222.3333.44444 NAME 'org-apache-tuscany-User'
> DESC 'org.apache.tuscany.User' SUP top AUXILIARY MUST cn
> X-SCHEMA 'ecore' )
> -
> -------------------------------------------
>
>
> Regards,
> Stefan
>

Re: [Schema] ObjectClass DN Correct?

Posted by Ole Ersoy <ol...@gmail.com>.
Hi Stefan,

Stefan Seelmann wrote:
> Hi Ole,
> 
>> When adding a new ObjectClass to the Schema
>> named "org.apache.tuscany.User"
> 
> An objectClass or attributeType name must be an OID (object identifier),
> that is defined as follows in RFC4512:
>   oid = descr / numericoid
>   descr = keystring
>   keystring = leadkeychar *keychar
>   leadkeychar = ALPHA
>   keychar = ALPHA / DIGIT / HYPHEN
>   numericoid = number 1*( DOT number )
>   ... and so on
> 
> So your name could be either something like
>   0.11.222.3333.44444
> or
>   org-apache-tuscany-User

Oh Yeah - Emmanuel told me that the periods have to be replaced
with dashes as well.  Thanks for the reminder though.  I think I 
definitely got it now :-)

SNIP
> -------------------------------------------
> dn: cn=schema
> changetype: modify
> add: objectClasses
> objectClasses: ( 0.11.222.3333.44444 NAME 'org-apache-tuscany-User'
>  DESC 'org.apache.tuscany.User' SUP top AUXILIARY MUST cn
>  X-SCHEMA 'ecore' )
> -
Yeah - That's extremely cooolll!
OK - I'm going to start playing.
Thanks for all the terrific elaboration.
Hopefully we'll have something rockin in a few days :-)

Cheers,
- Ole


Re: [Schema] ObjectClass DN Correct?

Posted by Stefan Seelmann <se...@apache.org>.
Hi Ole,

> When adding a new ObjectClass to the Schema
> named "org.apache.tuscany.User"

An objectClass or attributeType name must be an OID (object identifier),
that is defined as follows in RFC4512:
  oid = descr / numericoid
  descr = keystring
  keystring = leadkeychar *keychar
  leadkeychar = ALPHA
  keychar = ALPHA / DIGIT / HYPHEN
  numericoid = number 1*( DOT number )
  ... and so on

So your name could be either something like
  0.11.222.3333.44444
or
  org-apache-tuscany-User


> is this how I do the DN?:
>
> DN: objectClass=org.apache.tuscany.User, ou=objectClasses, ou=Schema
>

The DNs of the other objectclases in the schema looks like this:
  "m-oid=2.5.6.5,ou=objectClasses,cn=core,ou=schema"

So I would recommend to create your own schema suffix under ou=schema
where you could put the DAS schema. Here is an example in LDIF format,
how this could look like:

----------------------------------------------
dn: cn=ecore,ou=schema
objectClass: metaSchema
objectClass: top
cn: ecore
m-dependencies: core
m-dependencies: system

dn: ou=objectClasses,cn=ecore,ou=schema
objectClass: organizationalUnit
objectClass: top
ou: objectClasses

dn: m-oid=0.11.222.3333.44444,ou=objectClasses,cn=ecore,ou=schema
objectClass: metaObjectclass
objectClass: metaTop
objectClass: top
m-oid: 0.11.222.3333.44444
m-description: org.apache.tuscany.User
m-must: cn
m-name: org-apache-tuscany-User
m-obsolete: FALSE
m-supObjectClass: top
m-typeObjectClass: AUXILIARY
----------------------------------------------


BTW, the new schema feature is really cool. Once you have created the
"ou=objectClasses,cn=ecore,ou=schema" entry you could add new schema
elements by adding simple string values to cn=schema:

-------------------------------------------
dn: cn=schema
changetype: modify
add: objectClasses
objectClasses: ( 0.11.222.3333.44444 NAME 'org-apache-tuscany-User'
 DESC 'org.apache.tuscany.User' SUP top AUXILIARY MUST cn
 X-SCHEMA 'ecore' )
-
-------------------------------------------


Regards,
Stefan