You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by "Pierre-Arnaud Marcelot (JIRA)" <ji...@apache.org> on 2008/03/14 14:54:25 UTC
[jira] Created: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
No error thrown when removing a non existing value of an attribute
------------------------------------------------------------------
Key: DIRSERVER-1150
URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
Project: Directory ApacheDS
Issue Type: Bug
Affects Versions: 1.5.1
Reporter: Pierre-Arnaud Marcelot
It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
This request return a SUCCES response.
I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Reopened: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny reopened DIRSERVER-1150:
------------------------------------------
Oops, wrong issue :)
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.3
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Alex Karasulu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12606185#action_12606185 ]
Alex Karasulu commented on DIRSERVER-1150:
------------------------------------------
Any status on this. Did we agree on the behavior. If so I can get a quick fix out fast.
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.3
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny updated DIRSERVER-1150:
-----------------------------------------
Fix Version/s: (was: 1.5.3)
1.5.4
Not easy to fix.
Here are some ideas :
(01:54:38 AM) elecharny@gmail.com/Gaim: if I check the attribute before deleting it$
(01:54:47 AM) elecharny@gmail.com/Gaim: and thrown a NoSuchAttribute exception
(01:54:52 AM) elecharny@gmail.com/Gaim: it works well,
(01:55:05 AM) elecharny@gmail.com/Gaim: but the changelog is splitting chunks
(01:55:18 AM) elecharny@gmail.com/Gaim: because we already stored the reverted operation,
(01:55:25 AM) elecharny@gmail.com/Gaim: assuming that the attribute exists
(01:55:32 AM) elecharny@gmail.com/Gaim: which is obviously not the case
(01:55:45 AM) elecharny@gmail.com/Gaim: so when we try to revert to pass to the next test,
(01:55:48 AM) elecharny@gmail.com/Gaim: kaboom !
(01:56:14 AM) Alex Karasulu: well then preload the entry in changelog service before making the decision to determine what the proper reverse operation will be
(01:56:50 AM) elecharny@gmail.com/Gaim: I think we should revert the revert if we have an exception
(01:56:59 AM) Alex Karasulu: yeah good point
(01:57:04 AM) Alex Karasulu: we have to
(01:57:12 AM) Alex Karasulu: that's another thing that we do not do
(01:57:12 AM) elecharny@gmail.com/Gaim: or that we don't apply the revert if we get an exception
(01:57:27 AM) Alex Karasulu: we need transactions here
(01:57:39 AM) elecharny@gmail.com/Gaim: anyway, the modify/add/delete operations have to be reviewed from top to the bottom
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.4
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12612323#action_12612323 ]
Emmanuel Lecharny commented on DIRSERVER-1150:
----------------------------------------------
I have a fix... But it breaks other part of the server !
For instance, the ChangeLog interceptor is not anymore happy when trying to revert an operation which failed because an attribute was not existing ( a modify operation where we try to remove a non existing value, for instance).
I suggest that we postpone this issue to 1.5.4.
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.3
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny updated DIRSERVER-1150:
-----------------------------------------
Fix Version/s: 1.5.2
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.2
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny resolved DIRSERVER-1150.
------------------------------------------
Resolution: Fixed
This does not make a lot of sense to throw an exception because we try to remove a value which does not exist.
Closed the issue.
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.4
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny updated DIRSERVER-1150:
-----------------------------------------
Fix Version/s: (was: 1.5.2)
1.5.3
Postponed, as we don't have a clear answer.
I think that both returns are OK. OpenLDAP returns a noSuchAttribute error, and we consider that it's a Success, as the removed value _is_ removed, all in all :)
It's just a question of being consistent.
i'm just curious about how the other servers deal with this ? Stefan Z ?
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.3
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny reassigned DIRSERVER-1150:
--------------------------------------------
Assignee: Emmanuel Lecharny
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.2
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Alex Karasulu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12623699#action_12623699 ]
Alex Karasulu commented on DIRSERVER-1150:
------------------------------------------
Sure I think it's fine especially if there are implementation conflicts. The RFCs don't mandate one way or the other so I don't see it as a protocol issue but one of those vague areas.
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.4
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny resolved DIRSERVER-1150.
------------------------------------------
Resolution: Fixed
The following test demonstrates that the userCertificate;binary attribute is working on the server, and that the certificate is not modified.
There may be a bug in Studio, however.
public void testAddNewBinaryAttributeValue() throws NamingException
{
// Add a binary attribute
byte[] newValue = new byte[]{0x00, 0x01, 0x02, 0x03};
Attributes attrs = new AttributesImpl( "userCertificate;binary", newValue );
ctx.modifyAttributes( RDN_TORI_AMOS, DirContext.ADD_ATTRIBUTE, attrs );
// Verify, that attribute value is added
attrs = ctx.getAttributes( RDN_TORI_AMOS );
Attribute attr = attrs.get( "userCertificate" );
assertNotNull( attr );
assertTrue( attr.contains( newValue ) );
byte[] certificate = (byte[])attr.get();
assertTrue( Arrays.equals( newValue, certificate ) );
assertEquals( 1, attr.size() );
}
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.3
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Emmanuel Lecharny updated DIRSERVER-1150:
-----------------------------------------
Comment: was deleted
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.3
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (DIRSERVER-1150) No error thrown when removing a non
existing value of an attribute
Posted by "Pierre-Arnaud Marcelot (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Pierre-Arnaud Marcelot closed DIRSERVER-1150.
---------------------------------------------
Closed.
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.4
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (DIRSERVER-1150) No error thrown when removing a
non existing value of an attribute
Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/DIRSERVER-1150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12623696#action_12623696 ]
Emmanuel Lecharny commented on DIRSERVER-1150:
----------------------------------------------
So what do we do ?
IMHO, removing a non existing value from an existing attribute should just be accepted, as it's just a void operation.
Should we mark this issue as closed ?
> No error thrown when removing a non existing value of an attribute
> ------------------------------------------------------------------
>
> Key: DIRSERVER-1150
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1150
> Project: Directory ApacheDS
> Issue Type: Bug
> Affects Versions: 1.5.1
> Reporter: Pierre-Arnaud Marcelot
> Assignee: Emmanuel Lecharny
> Fix For: 1.5.4
>
>
> It's possible with Apache DS 1.5.1 and the latest trunk to execute a request where you remove a non existing value of an attribute.
> This request return a SUCCES response.
> I think an Error Response should be returned instead, as OpenLDAP does, indicating that the value does not exist.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.