[Dev] WSO2ES 1.1.0 - Failed to add asset Error

2014-06-03 Thread Ayesha Dissanayaka
Hi,

When I try to add new asset to the created store 'Apache Stratos
Cartridges' as a newly registered user, it gives following error. As admin
user, I can add assets without any issue.
I have used default SampleLifeCycle2 as the life-cycle for this asset type.
When I try to add assets for already available ES asset type[ex: ebook]
which uses same life-cycle , assets successfully added.

What am I doing wrong here?


[2014-06-03 16:06:35,375] ERROR
{org.wso2.carbon.governance.api.common.GovernanceArtifactManager} -  Failed
to add artifact: artifact id: b3465be3-c41a-4bce-91e8-56196e594f6f. Failed
to add new resource. User ayesha does not have authorization to update the
collection /_system/governance/cartriges.
org.wso2.carbon.registry.core.exceptions.RegistryException: Failed to add
new resource. User ayesha does not have authorization to update the
collection /_system/governance/cartriges.
at
org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1167)
at
org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1156)
at
org.wso2.carbon.registry.core.jdbc.Repository.add(Repository.java:1013)
at
org.wso2.carbon.registry.core.jdbc.Repository.put(Repository.java:305)
at
org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.put(EmbeddedRegistry.java:709)
at
org.wso2.carbon.registry.core.caching.CacheBackedRegistry.put(CacheBackedRegistry.java:465)
at
org.wso2.carbon.registry.core.session.UserRegistry.put(UserRegistry.java:657)
at
org.wso2.carbon.governance.api.common.GovernanceArtifactManager.addGovernanceArtifact(GovernanceArtifactManager.java:194)
at
org.wso2.carbon.governance.api.generic.GenericArtifactManager.addGenericArtifact(GenericArtifactManager.java:170)
at sun.reflect.GeneratedMethodAccessor99.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
at
org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at
org.mozilla.javascript.gen.artifacts_18._c_anonymous_16(artifacts:235)
at org.mozilla.javascript.gen.artifacts_18.call(artifacts)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at
org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3._c_anonymous_4(/publisher/modules/ext/scripts/asset.action.save.js:90)
at
org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3.call(/publisher/modules/ext/scripts/asset.action.save.js)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at
org.jaggeryjs.rhino.publisher.modules.ext.core.c2._c_anonymous_14(/publisher/modules/ext/core/extension.core.js:235)
at
org.jaggeryjs.rhino.publisher.modules.ext.core.c2.call(/publisher/modules/ext/core/extension.core.js)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at
org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_10(/publisher/modules/ext/core/extension.management.js:144)
at
org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_8(/publisher/modules/ext/core/extension.management.js:111)
at
org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
at
org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java:85)
at
org.jaggeryjs.rhino.publisher.assets.default.c1._c_anonymous_8(/publisher/assets/default/asset.jag:254)
at
org.jaggeryjs.rhino.publisher.assets.default.c1.call(/publisher/assets/default/asset.jag)
at org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
at
org.jaggeryjs.rhino.publisher.modules.c4._c_anonymous_12(/publisher/modules/router-g.js:183)
at
org.jaggeryjs.rhino.publisher.modules.c4.call(/publisher/modules/router-g.js)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.assets.default.c1._c_anonymous_1(/publisher/assets/default/asset.jag:479)
at
org.jaggeryjs.rhino.publisher.assets.default.c1.call(/publisher/assets/default/asset.jag)
at
org.mozilla.javascript.ScriptRuntime.applyOrCall(ScriptRuntime.java:2430)
at org.mozilla.javascript.BaseFunction.execIdCall(BaseFunction.java:269)
at
org.mozilla.javascript.IdFunctionObject.call(IdFunctionObject.java:97)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
at
org.jaggeryjs.rhino.publisher.modules.c6._c_anonymous_17(/publisher/modules/publisher.js:436)
at
org.jaggeryjs.rhino.publisher.modules.c6.call(/publisher/modules/publisher.js)
at 

Re: [Dev] WSO2ES 1.1.0 - Failed to add asset Error

2014-06-03 Thread Ajith Vitharana
On Tue, Jun 3, 2014 at 4:28 PM, Ayesha Dissanayaka aye...@wso2.com wrote:

 Hi,

 When I try to add new asset to the created store 'Apache Stratos
 Cartridges' as a newly registered user, it gives following error. As admin
 user, I can add assets without any issue.
 I have used default SampleLifeCycle2 as the life-cycle for this asset
 type. When I try to add assets for already available ES asset type[ex:
 ebook] which uses same life-cycle , assets successfully added.

 What am I doing wrong here?


Reason in the log, Please read the exceptions.

 Failed to add new resource. U*ser ayesha does not have authorization to
update the collection /_system/governance/cartriges.*

Thanks.
Ajith.



 [2014-06-03 16:06:35,375] ERROR
 {org.wso2.carbon.governance.api.common.GovernanceArtifactManager} -  Failed
 to add artifact: artifact id: b3465be3-c41a-4bce-91e8-56196e594f6f. Failed
 to add new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 org.wso2.carbon.registry.core.exceptions.RegistryException: Failed to add
 new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1167)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1156)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.add(Repository.java:1013)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.put(Repository.java:305)
 at
 org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.put(EmbeddedRegistry.java:709)
 at
 org.wso2.carbon.registry.core.caching.CacheBackedRegistry.put(CacheBackedRegistry.java:465)
 at
 org.wso2.carbon.registry.core.session.UserRegistry.put(UserRegistry.java:657)
 at
 org.wso2.carbon.governance.api.common.GovernanceArtifactManager.addGovernanceArtifact(GovernanceArtifactManager.java:194)
 at
 org.wso2.carbon.governance.api.generic.GenericArtifactManager.addGenericArtifact(GenericArtifactManager.java:170)
 at sun.reflect.GeneratedMethodAccessor99.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:597)
 at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
 at
 org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.mozilla.javascript.gen.artifacts_18._c_anonymous_16(artifacts:235)
 at org.mozilla.javascript.gen.artifacts_18.call(artifacts)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3._c_anonymous_4(/publisher/modules/ext/scripts/asset.action.save.js:90)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3.call(/publisher/modules/ext/scripts/asset.action.save.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2._c_anonymous_14(/publisher/modules/ext/core/extension.core.js:235)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2.call(/publisher/modules/ext/core/extension.core.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_10(/publisher/modules/ext/core/extension.management.js:144)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_8(/publisher/modules/ext/core/extension.management.js:111)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java:85)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1._c_anonymous_8(/publisher/assets/default/asset.jag:254)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1.call(/publisher/assets/default/asset.jag)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.c4._c_anonymous_12(/publisher/modules/router-g.js:183)
 at
 org.jaggeryjs.rhino.publisher.modules.c4.call(/publisher/modules/router-g.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1._c_anonymous_1(/publisher/assets/default/asset.jag:479)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1.call(/publisher/assets/default/asset.jag)
 at
 org.mozilla.javascript.ScriptRuntime.applyOrCall(ScriptRuntime.java:2430)
 at
 org.mozilla.javascript.BaseFunction.execIdCall(BaseFunction.java:269)
 at
 

Re: [Dev] WSO2ES 1.1.0 - Failed to add asset Error

2014-06-03 Thread Ayesha Dissanayaka
Hi Ajith,

Thank you very much for the reply. :)

Yes, I went through the log. My requirement is how to give authorization to
the user. Since I am using same configuration as default asset types such
as 'ebook', how can I not have permission for the created asset type(say
'cartridge').

When I assign 'admin' role to the created user, I can add assets without
any issue. But  my requirement is, users other than 'admin' to be able to
add assets.

Thank you :)



On Tue, Jun 3, 2014 at 5:00 PM, Ajith Vitharana aji...@wso2.com wrote:




 On Tue, Jun 3, 2014 at 4:28 PM, Ayesha Dissanayaka aye...@wso2.com
 wrote:

 Hi,

 When I try to add new asset to the created store 'Apache Stratos
 Cartridges' as a newly registered user, it gives following error. As admin
 user, I can add assets without any issue.
 I have used default SampleLifeCycle2 as the life-cycle for this asset
 type. When I try to add assets for already available ES asset type[ex:
 ebook] which uses same life-cycle , assets successfully added.

 What am I doing wrong here?


 Reason in the log, Please read the exceptions.

  Failed to add new resource. U*ser ayesha does not have authorization to
 update the collection /_system/governance/cartriges.*

 Thanks.
 Ajith.



 [2014-06-03 16:06:35,375] ERROR
 {org.wso2.carbon.governance.api.common.GovernanceArtifactManager} -  Failed
 to add artifact: artifact id: b3465be3-c41a-4bce-91e8-56196e594f6f. Failed
 to add new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 org.wso2.carbon.registry.core.exceptions.RegistryException: Failed to add
 new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1167)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1156)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.add(Repository.java:1013)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.put(Repository.java:305)
 at
 org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.put(EmbeddedRegistry.java:709)
 at
 org.wso2.carbon.registry.core.caching.CacheBackedRegistry.put(CacheBackedRegistry.java:465)
 at
 org.wso2.carbon.registry.core.session.UserRegistry.put(UserRegistry.java:657)
 at
 org.wso2.carbon.governance.api.common.GovernanceArtifactManager.addGovernanceArtifact(GovernanceArtifactManager.java:194)
 at
 org.wso2.carbon.governance.api.generic.GenericArtifactManager.addGenericArtifact(GenericArtifactManager.java:170)
 at sun.reflect.GeneratedMethodAccessor99.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:597)
 at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
 at
 org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.mozilla.javascript.gen.artifacts_18._c_anonymous_16(artifacts:235)
 at org.mozilla.javascript.gen.artifacts_18.call(artifacts)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3._c_anonymous_4(/publisher/modules/ext/scripts/asset.action.save.js:90)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3.call(/publisher/modules/ext/scripts/asset.action.save.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2._c_anonymous_14(/publisher/modules/ext/core/extension.core.js:235)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2.call(/publisher/modules/ext/core/extension.core.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_10(/publisher/modules/ext/core/extension.management.js:144)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_8(/publisher/modules/ext/core/extension.management.js:111)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java:85)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1._c_anonymous_8(/publisher/assets/default/asset.jag:254)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1.call(/publisher/assets/default/asset.jag)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.c4._c_anonymous_12(/publisher/modules/router-g.js:183)
   

Re: [Dev] WSO2ES 1.1.0 - Failed to add asset Error

2014-06-03 Thread Ajith Vitharana
On Tue, Jun 3, 2014 at 5:15 PM, Ayesha Dissanayaka aye...@wso2.com wrote:

 Hi Ajith,

 Thank you very much for the reply. :)

 Yes, I went through the log. My requirement is how to give authorization
 to the user. Since I am using same configuration as default asset types
 such as 'ebook', how can I not have permission for the created asset
 type(say 'cartridge').

 When I assign 'admin' role to the created user, I can add assets without
 any issue. But  my requirement is, users other than 'admin' to be able to
 add assets.


Go to the registry location * /_system/governance/cartriges.*
Expand the the permission tab, and allow the required authorizations for
the role that user belong to.

Thanks.
Ajith.



 Thank you :)



 On Tue, Jun 3, 2014 at 5:00 PM, Ajith Vitharana aji...@wso2.com wrote:




 On Tue, Jun 3, 2014 at 4:28 PM, Ayesha Dissanayaka aye...@wso2.com
 wrote:

 Hi,

 When I try to add new asset to the created store 'Apache Stratos
 Cartridges' as a newly registered user, it gives following error. As admin
 user, I can add assets without any issue.
 I have used default SampleLifeCycle2 as the life-cycle for this asset
 type. When I try to add assets for already available ES asset type[ex:
 ebook] which uses same life-cycle , assets successfully added.

 What am I doing wrong here?


 Reason in the log, Please read the exceptions.

  Failed to add new resource. U*ser ayesha does not have authorization to
 update the collection /_system/governance/cartriges.*

 Thanks.
 Ajith.



 [2014-06-03 16:06:35,375] ERROR
 {org.wso2.carbon.governance.api.common.GovernanceArtifactManager} -  Failed
 to add artifact: artifact id: b3465be3-c41a-4bce-91e8-56196e594f6f. Failed
 to add new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 org.wso2.carbon.registry.core.exceptions.RegistryException: Failed to
 add new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1167)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1156)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.add(Repository.java:1013)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.put(Repository.java:305)
 at
 org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.put(EmbeddedRegistry.java:709)
 at
 org.wso2.carbon.registry.core.caching.CacheBackedRegistry.put(CacheBackedRegistry.java:465)
 at
 org.wso2.carbon.registry.core.session.UserRegistry.put(UserRegistry.java:657)
 at
 org.wso2.carbon.governance.api.common.GovernanceArtifactManager.addGovernanceArtifact(GovernanceArtifactManager.java:194)
 at
 org.wso2.carbon.governance.api.generic.GenericArtifactManager.addGenericArtifact(GenericArtifactManager.java:170)
 at sun.reflect.GeneratedMethodAccessor99.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:597)
 at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
 at
 org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.mozilla.javascript.gen.artifacts_18._c_anonymous_16(artifacts:235)
 at org.mozilla.javascript.gen.artifacts_18.call(artifacts)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3._c_anonymous_4(/publisher/modules/ext/scripts/asset.action.save.js:90)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3.call(/publisher/modules/ext/scripts/asset.action.save.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2._c_anonymous_14(/publisher/modules/ext/core/extension.core.js:235)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2.call(/publisher/modules/ext/core/extension.core.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_10(/publisher/modules/ext/core/extension.management.js:144)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_8(/publisher/modules/ext/core/extension.management.js:111)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java:85)
 at
 org.jaggeryjs.rhino.publisher.assets.default.c1._c_anonymous_8(/publisher/assets/default/asset.jag:254)
 at
 

Re: [Dev] WSO2ES 1.1.0 - Failed to add asset Error

2014-06-03 Thread Ayesha Dissanayaka
Hi Ajith,

Go to the registry location * /_system/governance/cartriges.*
 Expand the the permission tab, and allow the required authorizations for
 the role that user belong to.


This worked. [?]

Thank you and Cheers!


On Tue, Jun 3, 2014 at 5:38 PM, Ajith Vitharana aji...@wso2.com wrote:




 On Tue, Jun 3, 2014 at 5:15 PM, Ayesha Dissanayaka aye...@wso2.com
 wrote:

 Hi Ajith,

 Thank you very much for the reply. :)

 Yes, I went through the log. My requirement is how to give authorization
 to the user. Since I am using same configuration as default asset types
 such as 'ebook', how can I not have permission for the created asset
 type(say 'cartridge').

 When I assign 'admin' role to the created user, I can add assets without
 any issue. But  my requirement is, users other than 'admin' to be able to
 add assets.


 Go to the registry location * /_system/governance/cartriges.*
 Expand the the permission tab, and allow the required authorizations for
 the role that user belong to.

 Thanks.
 Ajith.



 Thank you :)



 On Tue, Jun 3, 2014 at 5:00 PM, Ajith Vitharana aji...@wso2.com wrote:




 On Tue, Jun 3, 2014 at 4:28 PM, Ayesha Dissanayaka aye...@wso2.com
 wrote:

 Hi,

 When I try to add new asset to the created store 'Apache Stratos
 Cartridges' as a newly registered user, it gives following error. As admin
 user, I can add assets without any issue.
 I have used default SampleLifeCycle2 as the life-cycle for this asset
 type. When I try to add assets for already available ES asset type[ex:
 ebook] which uses same life-cycle , assets successfully added.

 What am I doing wrong here?


 Reason in the log, Please read the exceptions.

  Failed to add new resource. U*ser ayesha does not have authorization
 to update the collection /_system/governance/cartriges.*

 Thanks.
 Ajith.



 [2014-06-03 16:06:35,375] ERROR
 {org.wso2.carbon.governance.api.common.GovernanceArtifactManager} -  Failed
 to add artifact: artifact id: b3465be3-c41a-4bce-91e8-56196e594f6f. Failed
 to add new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 org.wso2.carbon.registry.core.exceptions.RegistryException: Failed to
 add new resource. User ayesha does not have authorization to update the
 collection /_system/governance/cartriges.
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1167)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.addEmptyCollection(Repository.java:1156)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.add(Repository.java:1013)
 at
 org.wso2.carbon.registry.core.jdbc.Repository.put(Repository.java:305)
 at
 org.wso2.carbon.registry.core.jdbc.EmbeddedRegistry.put(EmbeddedRegistry.java:709)
 at
 org.wso2.carbon.registry.core.caching.CacheBackedRegistry.put(CacheBackedRegistry.java:465)
 at
 org.wso2.carbon.registry.core.session.UserRegistry.put(UserRegistry.java:657)
 at
 org.wso2.carbon.governance.api.common.GovernanceArtifactManager.addGovernanceArtifact(GovernanceArtifactManager.java:194)
 at
 org.wso2.carbon.governance.api.generic.GenericArtifactManager.addGenericArtifact(GenericArtifactManager.java:170)
 at sun.reflect.GeneratedMethodAccessor99.invoke(Unknown Source)
 at
 sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
 at java.lang.reflect.Method.invoke(Method.java:597)
 at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
 at
 org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.mozilla.javascript.gen.artifacts_18._c_anonymous_16(artifacts:235)
 at org.mozilla.javascript.gen.artifacts_18.call(artifacts)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3._c_anonymous_4(/publisher/modules/ext/scripts/asset.action.save.js:90)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.scripts.c3.call(/publisher/modules/ext/scripts/asset.action.save.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2._c_anonymous_14(/publisher/modules/ext/core/extension.core.js:235)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c2.call(/publisher/modules/ext/core/extension.core.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call1(OptRuntime.java:32)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_10(/publisher/modules/ext/core/extension.management.js:144)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3.call(/publisher/modules/ext/core/extension.management.js)
 at
 org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:42)
 at
 org.jaggeryjs.rhino.publisher.modules.ext.core.c3._c_anonymous_8(/publisher/modules/ext/core/extension.management.js:111)
 at