[
https://issues.apache.org/jira/browse/DIRSERVER-2256?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16675948#comment-16675948
]
Emmanuel Lecharny commented on DIRSERVER-2256:
----------------------------------------------
Ok, the {{LdifUtils.convertToLdif}} method does not properly check the
attribute it has to encode. typically, we have an attribute which value is a
DN, and that should be encoded as a String, and isn't because it's considered
as not H-R. This might be improved.
Note that this will not solve the initial problem (the previous fix is going to
fix it), but it's the way to process the value no matter what.
I'll get it patched tomorrow.
> Schema Import - ERR_13215_VALUE_EXPECT_STRING
> ---------------------------------------------
>
> Key: DIRSERVER-2256
> URL: https://issues.apache.org/jira/browse/DIRSERVER-2256
> Project: Directory ApacheDS
> Issue Type: Bug
> Components: schema
> Affects Versions: 2.0.0.AM25
> Environment: Windows 7, jre1.8.0_131, DS 2.0.0.AM25, Studio
> 2.0.0.v20180908-M14
> Reporter: Stefan Humbold
> Priority: Major
> Attachments: test.ldif
>
>
> The new Apache DS-Server 2.0.0.AM25 makes problems when we try to import our
> schema file (was not a problem so far).
> Importing a new schema-file in ldif-format don't generates errors.
> But when we try to restart the server then the server won't start up and we
> see the following exceptions in the log file:
> [17:07:23] INFO [org.apache.directory.server.UberjarMain] - Starting the
> service.
> [17:07:23] ERROR [org.apache.directory.api.ldap.model.entry.DefaultAttribute]
> - ERR_13215_VALUE_EXPECT_STRING The value is expected to be a String
> [17:07:23] ERROR
> [org.apache.directory.api.ldap.schema.loader.LdifSchemaLoader] -
> ERR_16009_LDIF_LOAD_FAIL Failed to load schema LDIF file cn=test.ldif
> org.apache.directory.api.ldap.model.exception.LdapInvalidAttributeValueException:
> ERR_13215_VALUE_EXPECT_STRING The value is expected to be a String
> at
> org.apache.directory.api.ldap.model.entry.DefaultAttribute.getString(DefaultAttribute.java:517)
> at
> org.apache.directory.api.ldap.model.schema.registries.AbstractSchemaLoader.getSchema(AbstractSchemaLoader.java:171)
> at
> org.apache.directory.api.ldap.schema.loader.LdifSchemaLoader.initializeSchemas(LdifSchemaLoader.java:141)
> at
> org.apache.directory.api.ldap.schema.loader.LdifSchemaLoader.<init>(LdifSchemaLoader.java:111)
> at
> org.apache.directory.server.ApacheDsService.initSchemaManager(ApacheDsService.java:288)
> at
> org.apache.directory.server.ApacheDsService.start(ApacheDsService.java:183)
> at
> org.apache.directory.server.ApacheDsService.start(ApacheDsService.java:152)
> at org.apache.directory.server.UberjarMain.start(UberjarMain.java:151)
> at org.apache.directory.server.UberjarMain.main(UberjarMain.java:77)
> [17:07:23] ERROR [org.apache.directory.server.UberjarMain] - Failed to start
> the service.
> org.apache.directory.api.ldap.model.exception.LdapInvalidAttributeValueException:
> ERR_13215_VALUE_EXPECT_STRING The value is expected to be a String
> at
> org.apache.directory.api.ldap.model.entry.DefaultAttribute.getString(DefaultAttribute.java:517)
> at
> org.apache.directory.api.ldap.model.schema.registries.AbstractSchemaLoader.getSchema(AbstractSchemaLoader.java:171)
> at
> org.apache.directory.api.ldap.schema.loader.LdifSchemaLoader.initializeSchemas(LdifSchemaLoader.java:141)
> at
> org.apache.directory.api.ldap.schema.loader.LdifSchemaLoader.<init>(LdifSchemaLoader.java:111)
> at
> org.apache.directory.server.ApacheDsService.initSchemaManager(ApacheDsService.java:288)
> at
> org.apache.directory.server.ApacheDsService.start(ApacheDsService.java:183)
> at
> org.apache.directory.server.ApacheDsService.start(ApacheDsService.java:152)
> at org.apache.directory.server.UberjarMain.start(UberjarMain.java:151)
> at org.apache.directory.server.UberjarMain.main(UberjarMain.java:77)
> [17:07:23] INFO [org.apache.directory.server.UberjarMain] - Stopping the
> service.
> [17:07:23] ERROR [org.apache.directory.server.UberjarMain] - Failed to start
> the service.
> java.lang.NullPointerException
> at
> org.apache.directory.server.ApacheDsService.stop(ApacheDsService.java:634)
> at org.apache.directory.server.UberjarMain.stop(UberjarMain.java:216)
> at org.apache.directory.server.UberjarMain.start(UberjarMain.java:158)
> at org.apache.directory.server.UberjarMain.main(UberjarMain.java:77)
>
> I could reproduce the errors with a very simple schema-file (test.ldif) -
> only one new attribute and one new objectclass.
> I think, the problem ist in the generated file called cn=test.ldif
> (...\partitions\schema\ou=schema\cn=test.ldif )
> In this file, the creatorsName ist set to "0.9.2342.19200300.100.1.1= admin
> ,2.5.4.11= system"
> creatorsName::
> MC45LjIzNDIuMTkyMDAzMDAuMTAwLjEuMT0gYWRtaW4gLDIuNS40LjExPSBzeXN0Z
> W0g
> When i manually change the creatorsName uid=admin,ou=system (like in the
> other lidf-schema-files) then the server starts again.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)