[jira] [Commented] (SYNCOPE-1321) Search doesn't work for date attributes with conversion pattern with time zone
[ https://issues.apache.org/jira/browse/SYNCOPE-1321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16518967#comment-16518967 ] Francesco Chicchiriccò commented on SYNCOPE-1321: - No worries [~moonworm]! I had some spare time yesterday, and jumped ahead, as the time for 2.0.9 is approaching. Looking forward to your further involvement. > Search doesn't work for date attributes with conversion pattern with time zone > -- > > Key: SYNCOPE-1321 > URL: https://issues.apache.org/jira/browse/SYNCOPE-1321 > Project: Syncope > Issue Type: Bug > Components: core >Affects Versions: 2.0.8 >Reporter: Alexey >Assignee: Francesco Chicchiriccò >Priority: Major > Labels: date, format, formatDate, schema, time_zone > Fix For: 2.0.9, 2.1.0 > > Attachments: after.PNG, before.PNG > > > 1.) I have _date type_ *PlainSchemaTO* configured with conversion pattern > {{org.apache.cxf.jaxrs.ext.search.SearchUtils.TIMESTAMP_WITH_TIMEZONE_Z = > }}{{"-MM-dd\'T\'HH:mm:ssZ"}} > 2.) For instance, I built a new query using > {{org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder with an > appropriate settings for date format.}} > 3.) Query is built successfully, for instance > "date_att=lt=2018-06-12T15:21:00+0300" > but after its value being processed by *URLDecoder* in > {{org.apache.syncope.core.persistence.api.search.SearchCondVisitor, see line > 79:}} > {{value = > SearchUtils.toSqlWildcardString(*URLDecoder*.*decode*(sc.getStatement().getValue().toString(), > StandardCharsets.UTF_8.name()), false).replaceAll("_", "_");}} > plus sign ('*+*') is replacing with space (' ') which leads to incorrect > query processing in further Syncope code. > I assume *URLDecoder.decode* should be removed, it should be already done by > a servlet container. > Currently, I'm using a quite ugly fix by double encoding date schema value on > a client side and dealing with date values as string ones... > Kind Regards, > Alexey -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (SYNCOPE-1321) Search doesn't work for date attributes with conversion pattern with time zone
[ https://issues.apache.org/jira/browse/SYNCOPE-1321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16518647#comment-16518647 ] Alexey commented on SYNCOPE-1321: - Thanks, sorry I was quite busy and wasn't able to fix it by myself... > Search doesn't work for date attributes with conversion pattern with time zone > -- > > Key: SYNCOPE-1321 > URL: https://issues.apache.org/jira/browse/SYNCOPE-1321 > Project: Syncope > Issue Type: Bug > Components: core >Affects Versions: 2.0.8 >Reporter: Alexey >Assignee: Francesco Chicchiriccò >Priority: Major > Labels: date, format, formatDate, schema, time_zone > Fix For: 2.0.9, 2.1.0 > > Attachments: after.PNG, before.PNG > > > 1.) I have _date type_ *PlainSchemaTO* configured with conversion pattern > {{org.apache.cxf.jaxrs.ext.search.SearchUtils.TIMESTAMP_WITH_TIMEZONE_Z = > }}{{"-MM-dd\'T\'HH:mm:ssZ"}} > 2.) For instance, I built a new query using > {{org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder with an > appropriate settings for date format.}} > 3.) Query is built successfully, for instance > "date_att=lt=2018-06-12T15:21:00+0300" > but after its value being processed by *URLDecoder* in > {{org.apache.syncope.core.persistence.api.search.SearchCondVisitor, see line > 79:}} > {{value = > SearchUtils.toSqlWildcardString(*URLDecoder*.*decode*(sc.getStatement().getValue().toString(), > StandardCharsets.UTF_8.name()), false).replaceAll("_", "_");}} > plus sign ('*+*') is replacing with space (' ') which leads to incorrect > query processing in further Syncope code. > I assume *URLDecoder.decode* should be removed, it should be already done by > a servlet container. > Currently, I'm using a quite ugly fix by double encoding date schema value on > a client side and dealing with date values as string ones... > Kind Regards, > Alexey -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (SYNCOPE-1321) Search doesn't work for date attributes with conversion pattern with time zone
[ https://issues.apache.org/jira/browse/SYNCOPE-1321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16508138#comment-16508138 ] Alexey commented on SYNCOPE-1321: - Ok, I will provide PR as soon as I have some spare time. > Search doesn't work for date attributes with conversion pattern with time zone > -- > > Key: SYNCOPE-1321 > URL: https://issues.apache.org/jira/browse/SYNCOPE-1321 > Project: Syncope > Issue Type: Bug > Components: core >Affects Versions: 2.0.8 >Reporter: Alexey >Priority: Major > Labels: date, format, formatDate, schema, time_zone > Fix For: 2.0.9, 2.1.0 > > Attachments: after.PNG, before.PNG > > > 1.) I have _date type_ *PlainSchemaTO* configured with conversion pattern > {{org.apache.cxf.jaxrs.ext.search.SearchUtils.TIMESTAMP_WITH_TIMEZONE_Z = > }}{{"-MM-dd\'T\'HH:mm:ssZ"}} > 2.) For instance, I built a new query using > {{org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder with an > appropriate settings for date format.}} > 3.) Query is built successfully, for instance > "date_att=lt=2018-06-12T15:21:00+0300" > but after its value being processed by *URLDecoder* in > {{org.apache.syncope.core.persistence.api.search.SearchCondVisitor, see line > 79:}} > {{value = > SearchUtils.toSqlWildcardString(*URLDecoder*.*decode*(sc.getStatement().getValue().toString(), > StandardCharsets.UTF_8.name()), false).replaceAll("_", "_");}} > plus sign ('*+*') is replacing with space (' ') which leads to incorrect > query processing in further Syncope code. > I assume *URLDecoder.decode* should be removed, it should be already done by > a servlet container. > Currently, I'm using a quite ugly fix by double encoding date schema value on > a client side and dealing with date values as string ones... > Kind Regards, > Alexey -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (SYNCOPE-1321) Search doesn't work for date attributes with conversion pattern with time zone
[ https://issues.apache.org/jira/browse/SYNCOPE-1321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16508036#comment-16508036 ] Francesco Chicchiriccò commented on SYNCOPE-1321: - Mind proposing an implementation for such a change? You can do that also by forking [https://github.com/apache/syncope] and sending a PR (branch {{2_0_X]]). In case, please ensure to have a look at * [https://cwiki.apache.org/confluence/display/SYNCOPE/Git+workflow] * [http://syncope.apache.org/contributing.html#How_do_I_become_a_contributor_or_a_committer] > Search doesn't work for date attributes with conversion pattern with time zone > -- > > Key: SYNCOPE-1321 > URL: https://issues.apache.org/jira/browse/SYNCOPE-1321 > Project: Syncope > Issue Type: Bug > Components: core >Affects Versions: 2.0.8 >Reporter: Alexey >Priority: Major > Labels: date, format, formatDate, schema, time_zone > Fix For: 2.0.9, 2.1.0 > > Attachments: after.PNG, before.PNG > > > 1.) I have _date type_ *PlainSchemaTO* configured with conversion pattern > {{org.apache.cxf.jaxrs.ext.search.SearchUtils.TIMESTAMP_WITH_TIMEZONE_Z = > }}{{"-MM-dd\'T\'HH:mm:ssZ"}} > 2.) For instance, I built a new query using > {{org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder with an > appropriate settings for date format.}} > 3.) Query is built successfully, for instance > "date_att=lt=2018-06-12T15:21:00+0300" > but after its value being processed by *URLDecoder* in > {{org.apache.syncope.core.persistence.api.search.SearchCondVisitor, see line > 79:}} > {{value = > SearchUtils.toSqlWildcardString(*URLDecoder*.*decode*(sc.getStatement().getValue().toString(), > StandardCharsets.UTF_8.name()), false).replaceAll("_", "_");}} > plus sign ('*+*') is replacing with space (' ') which leads to incorrect > query processing in further Syncope code. > I assume *URLDecoder.decode* should be removed, it should be already done by > a servlet container. > Currently, I'm using a quite ugly fix by double encoding date schema value on > a client side and dealing with date values as string ones... > Kind Regards, > Alexey -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (SYNCOPE-1321) Search doesn't work for date attributes with conversion pattern with time zone
[ https://issues.apache.org/jira/browse/SYNCOPE-1321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16508030#comment-16508030 ] Alexey commented on SYNCOPE-1321: - It would be a solution too. Thanks for the quick reply! > Search doesn't work for date attributes with conversion pattern with time zone > -- > > Key: SYNCOPE-1321 > URL: https://issues.apache.org/jira/browse/SYNCOPE-1321 > Project: Syncope > Issue Type: Bug > Components: core >Affects Versions: 2.0.8 >Reporter: Alexey >Priority: Major > Labels: date, format, formatDate, schema, time_zone > Fix For: 2.0.9, 2.1.0 > > Attachments: after.PNG, before.PNG > > > 1.) I have _date type_ *PlainSchemaTO* configured with conversion pattern > {{org.apache.cxf.jaxrs.ext.search.SearchUtils.TIMESTAMP_WITH_TIMEZONE_Z = > }}{{"-MM-dd\'T\'HH:mm:ssZ"}} > 2.) For instance, I built a new query using > {{org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder with an > appropriate settings for date format.}} > 3.) Query is built successfully, for instance > "date_att=lt=2018-06-12T15:21:00+0300" > but after its value being processed by *URLDecoder* in > {{org.apache.syncope.core.persistence.api.search.SearchCondVisitor, see line > 79:}} > {{value = > SearchUtils.toSqlWildcardString(*URLDecoder*.*decode*(sc.getStatement().getValue().toString(), > StandardCharsets.UTF_8.name()), false).replaceAll("_", "_");}} > plus sign ('*+*') is replacing with space (' ') which leads to incorrect > query processing in further Syncope code. > I assume *URLDecoder.decode* should be removed, it should be already done by > a servlet container. > Currently, I'm using a quite ugly fix by double encoding date schema value on > a client side and dealing with date values as string ones... > Kind Regards, > Alexey -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (SYNCOPE-1321) Search doesn't work for date attributes with conversion pattern with time zone
[ https://issues.apache.org/jira/browse/SYNCOPE-1321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16508021#comment-16508021 ] Francesco Chicchiriccò commented on SYNCOPE-1321: - URL decoding was introduced as part of SYNCOPE-1223, by [this commit|https://github.com/apache/syncope/commit/a1e9c04fa1edd4812876fb8c943b0c2e37c3d80b], hence it cannot simply removed. We might reserve a special treatment for the '+' sign, if found right before the last 4 characters, and if such characters are all digits: what do you think? > Search doesn't work for date attributes with conversion pattern with time zone > -- > > Key: SYNCOPE-1321 > URL: https://issues.apache.org/jira/browse/SYNCOPE-1321 > Project: Syncope > Issue Type: Bug > Components: core >Affects Versions: 2.0.8 >Reporter: Alexey >Priority: Major > Labels: date, format, formatDate, schema, time_zone > Fix For: 2.0.9, 2.1.0 > > Attachments: after.PNG, before.PNG > > > 1.) I have _date type_ *PlainSchemaTO* configured with conversion pattern > {{org.apache.cxf.jaxrs.ext.search.SearchUtils.TIMESTAMP_WITH_TIMEZONE_Z = > }}{{"-MM-dd\'T\'HH:mm:ssZ"}} > 2.) For instance, I built a new query using > {{org.apache.cxf.jaxrs.ext.search.client.FiqlSearchConditionBuilder with an > appropriate settings for date format.}} > 3.) Query is built successfully, for instance > "date_att=lt=2018-06-12T15:21:00+0300" > but after its value being processed by *URLDecoder* in > {{org.apache.syncope.core.persistence.api.search.SearchCondVisitor, see line > 79:}} > {{value = > SearchUtils.toSqlWildcardString(*URLDecoder*.*decode*(sc.getStatement().getValue().toString(), > StandardCharsets.UTF_8.name()), false).replaceAll("_", "_");}} > plus sign ('*+*') is replacing with space (' ') which leads to incorrect > query processing in further Syncope code. > I assume *URLDecoder.decode* should be removed, it should be already done by > a servlet container. > Currently, I'm using a quite ugly fix by double encoding date schema value on > a client side and dealing with date values as string ones... > Kind Regards, > Alexey -- This message was sent by Atlassian JIRA (v7.6.3#76005)