Hi Menuka

On Mon, Nov 13, 2017 at 2:45 PM, Menuka Warushavithana <men...@wso2.com>
wrote:

> Hi all,
>
> I'm working on implementing a CLI application for importing and exporting
> APIs between different API environments [1] as for my internship project --
> where I need to query APIs (from the publisher) with respect to the name of
> the API *AND *the version of the API.
>
> Example: name:sampleapi&version:1.0.0
>
> However, as of now, APIM 3.0.0 Publisher supports full text search only.
> Therefore I started implementing multi-attribute search for Publisher in
> API Manager 3.0.0 and opened a pull request [2]. I have not touched the
> database layer for this implementation since there needs to be a review of
> the design for this particular feature.
>
In the DAO layer attribute search is supported[1] . You can call the same
method from the publisher impl layer.

> My concerns are as follows.
>
>    - Should there be a limit to the number of attributes? i.e. Do we need
>    to support a query like 
> "name:sampleapi&version:1.0.0&provider:admin&LifeCycleStatus:created"
>    where four attributes are used for querying?
>
> Yes, the method[1] is written in way to support this type of queries.

>
>    - Even though the character  '&' is used for separating fields (for
>    clear representation), it's confusing to use '&' in the URL as it's used
>    for separating GET parameters. So what should be the delimiter to be used
>    in place of '&' ? [ I'm suggesting "," (the comma) ]
>       - Example: 'name:sampleapi,version:1.0.0,provider:admin,
>       LifeCycleStatus:created'
>    - Do the changes I have made in [2] need to be altered so that it can
>    be used to support further use cases?
>
>
> Suggestions are appreciated.
>
> [1] https://github.com/menuka94/product-apim-tooling/
> tree/master/import-export-cli
> [2] https://github.com/wso2/carbon-apimgt/pull/4712
>

[1] -
https://github.com/wso2/carbon-apimgt/blob/master/components/apimgt/org.wso2.carbon.apimgt.core/src/main/java/org/wso2/carbon/apimgt/core/dao/impl/ApiDAOImpl.java#L464


>
>
> Thanks and Regards
>
> *Menuka Warushavithana*
> *Software Engineering Intern*
> *WSO2*
>
> *Moblie:      + <%2B%2094%2011%202145345%20%C2%A0Ext.%205737> 94 77
> 6979690*
> *LinkedIn:   **https://www.linkedin.com/in/menukawarushavithana/
> <https://www.linkedin.com/in/menukawarushavithana/>*
> *GitHub:      **https://github.com/menuka94/
> <https://github.com/menuka94/>*
>
>
>


-- 
Rajith Roshan
Senior Software Engineer, WSO2 Inc.
Mobile: +94-7 <%2B94-71-554-8430>17-064-214
_______________________________________________
Architecture mailing list
Architecture@wso2.org
https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture

Reply via email to