Hi Imesh,
Some of these issues were there earlier and I have fixed them. Anyway I'll
check and fix them soon.
Thanks.

On Sun, May 17, 2015 at 10:31 AM, Imesh Gunaratne <[email protected]> wrote:

> Hi Dinithi,
>
> I found series of issues in the CLI:
>
> 1. When an invalid password is given following error message is raised:
>
> >/apache-stratos-cli-4.1.0-SNAPSHOT$ sh bin/stratos.sh
> Username: admin
> Password: *********
> An unknown error occurred: null
>
>
> 2. When an invalid network partition is added following error message is
> raised:
>
> stratos> add-network-partition --resource-path
> /Users/imesh/sandboxes/apache/stratos/4.1.0/cli/network-partition-1.json
> HTTP/1.1 500 Internal Server Error
> Internal server error occurred
>
>
> 3. When a none existing network partition is removed, the following error
> message is raised:
>
> stratos> remove-network-partition abc
> HTTP/1.1 500 Internal Server Error
> Internal server error occurred
>
>
> 4. Adding an already existing deployment policy shows HTTP status code:
>
> stratos> add-deployment-policy --resource-path
> /Users/imesh/sandboxes/apache/stratos/4.1.0/cli/deployment-policy-1.json
> HTTP/1.1 409 Conflict
> Specified deployment policy already exists
>
>
> 5. Adding a deployment policy with a none existing network partition does
> not show the correct error message:
>
> stratos> add-deployment-policy --resource-path
> /Users/imesh/sandboxes/apache/stratos/4.1.0/cli/deployment-policy-1.json
> HTTP/1.1 400 Bad Request
>
>
> 6. Removing a none existing deployment policy shows HTTP status code:
>
> stratos> remove-deployment-policy deployment-policy-12
> HTTP/1.1 404 Not Found
> Deployment policy not found
>
>
> 7. Tenant domain validation error message is not shown to the user:
>
> stratos> add-tenant -d abc -e [email protected] -f imesh -l gunaratne -p
> abc123 -u imesh
> Tenant added successfully: abc
>
> [2015-05-17 10:17:50,272] ERROR
> {org.apache.stratos.rest.endpoint.api.StratosApiV41Utils} -  Tenant domain
> validation error for tenant abc
> java.lang.Exception: You should have an extension to your domain.
> at
> org.wso2.carbon.tenant.mgt.util.TenantMgtUtil.validateDomain(TenantMgtUtil.java:152)
>
>
> 8. Adding an existing tenant shows the below error message:
>
> stratos> add-tenant -d abc.com -e [email protected] -f imesh -l gunaratne -p
> abc123 -u imesh
> HTTP/1.1 500 Internal Server Error
>
>
> [2015-05-17 10:19:54,815] ERROR
> {org.apache.stratos.rest.endpoint.handlers.CustomExceptionMapper} -  Could
> not add tenant: Domain is not available to register
> org.apache.stratos.rest.endpoint.exception.RestAPIException: Could not add
> tenant: Domain is not available to register
> at
> org.apache.stratos.rest.endpoint.api.StratosApiV41Utils.addTenant(StratosApiV41Utils.java:2895)
>
>
> 9. Activating a none existing tenant does not show the correct error
> message:
>
> stratos> activate-tenant abc.com2
> Could not activate tenant: abc.com2
>
> [2015-05-17 10:21:42,682] ERROR
> {org.apache.stratos.rest.endpoint.handlers.CustomExceptionMapper} -  The
> tenant with domain name: abc.com2 does not exist.
> org.apache.stratos.rest.endpoint.exception.RestAPIException: The tenant
> with domain name: abc.com2 does not exist.
> at
> org.apache.stratos.rest.endpoint.api.StratosApiV41Utils.activateTenant(StratosApiV41Utils.java:3203)
>
>
> 10. Deactivating a none existing tenant shows an invalid message:
>
> stratos> deactivate-tenant abc2
> You have successfully deactivated the tenant: abc2
>
>
> I did not completely test the CLI, this is just on few commands. IMO we
> need to fix these issues for 4.1.0-RC1.
>
> Thanks
>
>
> --
> Imesh Gunaratne
>
> Senior Technical Lead, WSO2
> Committer & PMC Member, Apache Stratos
>



-- 
*Dinithi De Silva*
Associate Software Engineer, WSO2 Inc.
m:+94716667655 | e:[email protected] | w: www.wso2.com
| a: #20, Palm Grove, Colombo 03

Reply via email to