Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

require createValues, defaultValues and forceValues in xsd #215

Open
davidcoutadeur opened this issue May 31, 2023 · 4 comments
Open

require createValues, defaultValues and forceValues in xsd #215

davidcoutadeur opened this issue May 31, 2023 · 4 comments

Comments

@davidcoutadeur
Copy link
Contributor

In a LSC synchronization DB -> DB, I noticed that defaultValues, forceValues and createValues are mandatory, else we get a generic nullPointerException. (which is hard to understand)

For example, this one is ok:

        <dataset>
          <name>userPassword</name>
          <policy>KEEP</policy>
          <defaultValues>
            <string>"changethis"</string>
          </defaultValues>
          <forceValues></forceValues>
          <createValues></createValues>
        </dataset>

This one is ko:

        <dataset>
          <name>userPassword</name>
          <policy>KEEP</policy>
          <defaultValues>
            <string>"changethis"</string>
          </defaultValues>
        </dataset>

I think it could be a good idea to fail fast when the tags are absent

Maybe we could make the default/force/createValues to be mandatory in the XSD verification?

@coudot
Copy link
Member

coudot commented May 31, 2023

I think we should not require them, as they are not mandatory for a DB -> LDAP or LDAP -> LDAP connector. There is no reason that a dataset has to be specific to source or destination type.

@coudot coudot added the bug label May 31, 2023
@coudot coudot added this to the 2.1.7 milestone May 31, 2023
@davidcoutadeur
Copy link
Contributor Author

Ok, if it is not mandatory for DB -> LDAP or LDAP -> LDAP.

By the way, it can be interesting to give a look to the code to understand why it is required for DB -> DB.

@coudot
Copy link
Member

coudot commented May 31, 2023

Indeed, I consider this is a bug and has to be fixed.

@davidcoutadeur
Copy link
Contributor Author

I don't reproduce with a hsqldb -> ldap connector.

Maybe this is specific to a special database. The bug was found on a DB2 -> LDAP connector

@coudot coudot modified the milestones: 2.1.7, Future Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants