error editAccessRights operation in php script

Christian Coulon's Avatar

Christian Coulon

10 Jul, 2013 08:39 PM

so I'm adding a group to access a folder, and i've run this script in our test evnironment 7.2 with no problem, but the same script, gives me an error in 7. here is the error:

editAccessRights failed to conform to the WSDL. SoapFault exception: [soapenv:Server.generalException] Tried to invoke method public com.hannonhill.cascade.webservice.schema.operation.result.OperationResult com.hannonhill.cascade.webservice.handler.AssetOperationHandler.editAccessRights(com.hannonhill.cascade.webservice.schema.Authentication,com.hannonhill.cascade.webservice.schema.AccessRightsInformation,boolean) with arguments com.hannonhill.cascade.webservice.schema.Authentication,com.hannonhill.cascade.webservice.schema.AccessRightsInformation,null. The arguments do not match the signature.; nested exception is:java.lang.IllegalArgumentException

Now I have thoroughly examined the situation. The script reads access from the folder in both cases, and performs the same operation on the resulting asset object - I could post a bunch of script here, but it's just that simple - the editAccessRights operation fails in 7.0, not in 7.2
Additionally between the two reads I get slightly different result objects. Here's 7.0:

@@@
stdClass Object
(
    [identifier] => stdClass Object
        (
            [id] => c99403fe8078218865052f4922a2ea72
            [path] => stdClass Object
                (
                    [path] => manager_resources
                    [siteId] => c11ca9d280782184008ae431d43f52cf
                    [siteName] => GGNB v.2
                )

            [type] => folder
            [recycled] =>
        )

    [aclEntries] => stdClass Object
        (
            [aclEntry] => Array
                (
                    [0] => Array
                        (
                            [level] => write
                            [type] => group
                            [name] => GGNB managers
                        )

                )

        )

    [allLevel] => none
)
@@@

@@@
stdClass Object
(
    [identifier] => stdClass Object
        (
            [id] => ca25a6d580782184504ad009c0d35d51
            [path] => stdClass Object
                (
                    [path] => manager_resources
                    [siteId] => c11ca9d280782184008ae431d43f52cf
                    [siteName] =>
                )

            [type] => folder
            [recycled] =>
        )

    [aclEntries] => stdClass Object
        (
            [aclEntry] => Array
                (
                    [0] => Array
                        (
                            [level] => write
                            [type] => group
                            [name] => GGNB managers
                        )

                )

        )

    [allLevel] => none
)
@@@

these are the objects right before the edit operation - nothing different. Also the only aspect that has been changed is the addition of the aclEntry in both cases the same... and both environments have these managers since they are cloned.

any ideas?

thanks!

  1. 1 Posted by Ryan Griffith on 11 Jul, 2013 12:53 PM

    Ryan Griffith's Avatar

    Hi Christian,

    It sounds like you are running into this known defect in which the applyToChildren element is not optional, even though the WSDL says it is.

    This issue was resolved in 7.2, so upgrading should resolve the error you are encountering. This seems to coincide with your 7.2 testing.

    In the meantime, as a workaround try adding in the applyToChildren element as well (this is a boolean field) and let me know if this helps resolve the error message.

    Please let me know if you have any questions.

    Thanks!

  2. 2 Posted by Christian Coulo... on 11 Jul, 2013 05:01 PM

    Christian Coulon's Avatar

    Ryan,
    All fixed, thanks so much.

    cheers,
    Christian

  3. 3 Posted by Ryan Griffith on 11 Jul, 2013 06:16 PM

    Ryan Griffith's Avatar

    Not a problem at all, Christian. Glad to hear that did the trick.

    Have a great day!

  4. Ryan Griffith closed this discussion on 11 Jul, 2013 06:16 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac