In ldbm_back_init a lot of functions are registered with the database plugin. but some of them are not used or useless.
SLAPI_PLUGIN_DB_INIT_INSTANCE_FN, (void *)ldbm_back_init); /* register itself so that the secon instance can be initialized */
it registers itself as INIT funcction, but it is not used and I don't see a possible use case.
SLAPI_PLUGIN_DB_SIZE_FN, (void *)ldbm_db_size);
The implementation warns that it might be incorrect and it is not called. There is a cb_db_size in the chaining backend, but it always returns 0, and it is not called.
SLAPI_PLUGIN_DB_ADD_SCHEMA_FN, (void *)ldbm_back_add_schema);
It is called once directly, but not via the plugin struct. And the question is: shouldn't we provide required schema in a schema file and not add it via a function ?
Metadata Update from @mreynolds: - Custom field component adjusted to None - Custom field origin adjusted to None - Custom field reviewstatus adjusted to None - Custom field type adjusted to None - Custom field version adjusted to None - Issue set to the milestone: 1.4.0
Metadata Update from @vashirov: - Issue priority set to: normal - Issue set to the milestone: 1.4.3 (was: 1.4.0)
Metadata Update from @mreynolds: - Custom field rhbz adjusted to https://bugzilla.redhat.com/show_bug.cgi?id=1859224
Issue linked to Bugzilla: Bug 1859224
Metadata Update from @mreynolds: - Issue assigned to mreynolds
We still need to register SLAPI_PLUGIN_DB_ADD_SCHEMA_FN, as it sets a function pointer that is called in the dse init phase: init_schema_dse_ext()
https://pagure.io/389-ds-base/pull-request/51217
But the question is why do we set the schema for entryid, parentid,.. in a function at each stratup and not define them in the schema files. Only if the ldbm backend, the level above bdb, lmdb, .. would be replaced by something else the schema definitions would be obsolet (but that also could be changed again)
Those attributes comes from Netscape implementation and are required by backend. It makes sense to move their definitions to standard schema file (like 01core389.ldif) as changing the backend can not be anticipated.
except this the patch looks good
I updated the schema and made other changes. The basic test suite passes. Please review...
Commit 98d6c7f8 fixes this issue
Metadata Update from @mreynolds: - Issue close_status updated to: None (was: Fixed) - Issue set to the milestone: 1.4.4 (was: 1.4.3)
389-ds-base is moving from Pagure to Github. This means that new issues and pull requests will be accepted only in 389-ds-base's github repository.
This issue has been cloned to Github and is available here: - https://github.com/389ds/389-ds-base/issues/2540
If you want to receive further updates on the issue, please navigate to the github issue and click on subscribe button.
subscribe
Thank you for understanding. We apologize for all inconvenience.
Metadata Update from @spichugi: - Issue close_status updated to: wontfix