You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@syncope.apache.org by Jesse van Bekkum <be...@gmail.com> on 2013/04/08 14:58:11 UTC

Key Column field in connectors

Hi

I am using a CSV connector, and I have some issues/remarks about the Key
column name

When you use a multivalued key, syncope will default concatenate the key
fields with a comma to form a username. However, the comma is not allowed
in usernames. I think it is silly if the default options do not work.
Besides that, I would like to just concatenate the two fields, without
anything in between. That seems to be impossible.

I would suggest to use the empty string as a default concatenation value
for the property "Key separator" in connectors, instead of the comma. That
will solve both issues.

I also noticed that when you have one key in the property "Key column
name", that field is removed from the external attributes in the schema
mapping. If you have two key columns, the columns are not removed. I think
you should be able to use a field both as username, and as something else,
so it should not be removed from the external attributes.

I am using syncope 1.0.7 with the CSV connector 0.6.1

Jesse van Bekkum

Re: Key Column field in connectors

Posted by Francesco Chicchiriccò <il...@apache.org>.
On 08/04/2013 14:58, Jesse van Bekkum wrote:
> Hi
>
> I am using a CSV connector, and I have some issues/remarks about the
> Key column name
>
> When you use a multivalued key, syncope will default concatenate the
> key fields with a comma to form a username. However, the comma is not
> allowed in usernames. I think it is silly if the default options do
> not work.

You need to distinguish here the default values defined by the ConnId
CSV connector [1] and the usage that Syncope makes of it.

In Syncope, the username values are checked by AccountPolicyEnforcer [2]
against a set of predefined patterns, excluding comma as you already
noticed: this is performed regardless of the external resource, hence
regardless of the ConnId connector. You might, of course, override this
behavior in your own overlay project.

> Besides that, I would like to just concatenate the two fields, without
> anything in between. That seems to be impossible.

I suggest to ask this on connid-users@googlegroups.com, but I don't
think this is feasible since there would be no way to distinguish the
original values.
Have you considered using a derived schema for this purpose?

> I would suggest to use the empty string as a default concatenation
> value for the property "Key separator" in connectors, instead of the
> comma. That will solve both issues.

See above.

> I also noticed that when you have one key in the property "Key column
> name", that field is removed from the external attributes in the
> schema mapping. If you have two key columns, the columns are not
> removed. I think you should be able to use a field both as username,
> and as something else, so it should not be removed from the external
> attributes.

You need definitely to address this to connid-users@googlegroups.com and
eventually file an issue there (mode details: it's the schema() operation).

Regards.

> I am using syncope 1.0.7 with the CSV connector 0.6.1

[1] https://github.com/Tirasa/ConnIdCSVDirBundle
[2]
https://svn.apache.org/repos/asf/syncope/branches/1_0_X/core/src/main/java/org/apache/syncope/core/policy/AccountPolicyEnforcer.java

-- 
Francesco Chicchiriccò

ASF Member, Apache Syncope PMC chair, Apache Cocoon PMC Member
http://people.apache.org/~ilgrosso/