[teiid-issues] [JBoss JIRA] (TEIID-3615) Add a api-docs page with Swagger-UI in REST Service Through VDB

Kylin Soong (JIRA) issues at jboss.org
Mon Aug 10 06:09:01 EDT 2015


     [ https://issues.jboss.org/browse/TEIID-3615?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Kylin Soong updated TEIID-3615:
-------------------------------
    Description: 
With document [1], we can use REST API to access the data in VDB, for example, there are 4 procedures defined in PortfolioRest VDB as [2] under 'Rest' Model:
* foo
* getAllStocks
* getAllStockById
* getAllStockBySymbol

Correspondingly, there are 4 api:

~~~
http://{host}:8080/portfoliorest_1/rest/foo/{id}
http://{host}:8080/portfoliorest_1/rest/getAllStocks
http://{host}:8080/portfoliorest_1/rest/getAllStockById/{id}
http://{host}:8080/portfoliorest_1/rest/getAllStockBySymbol/{symbol}
~~~

With Swagger UI, it's easy to add a api-doc page for all api, [3] is a example.

[1] https://docs.jboss.org/author/display/TEIID/REST+Service+Through+VDB
[2] https://raw.githubusercontent.com/kylinsoong/teiid-quickstarts/master/dynamicvdb-restservice/src/vdb/portfolio-rest-vdb.xml
[3] http://petstore.swagger.io/

  was:
With document [1], we can use REST API to access the data in VDB, for example, there are 4 procedures defined in PortfolioRest VDB as [2] under 'Rest' Model:
* foo
* getAllStocks
* getAllStockById
* getAllStockBySymbol

Correspondingly, there are 4 api:

http://{host}:8080/portfoliorest_1/rest/foo/{id}
http://{host}:8080/portfoliorest_1/rest/getAllStocks
http://{host}:8080/portfoliorest_1/rest/getAllStockById/{id}
http://{host}:8080/portfoliorest_1/rest/getAllStockBySymbol/{symbol}

With Swagger UI, it's easy to add a api-doc page for all api, [3] is a example.

[1] https://docs.jboss.org/author/display/TEIID/REST+Service+Through+VDB
[2] https://raw.githubusercontent.com/kylinsoong/teiid-quickstarts/master/dynamicvdb-restservice/src/vdb/portfolio-rest-vdb.xml
[3] http://petstore.swagger.io/



> Add a api-docs page with Swagger-UI in REST Service Through VDB
> ---------------------------------------------------------------
>
>                 Key: TEIID-3615
>                 URL: https://issues.jboss.org/browse/TEIID-3615
>             Project: Teiid
>          Issue Type: Feature Request
>    Affects Versions: 8.12
>            Reporter: Kylin Soong
>            Assignee: Kylin Soong
>             Fix For: 9.0
>
>
> With document [1], we can use REST API to access the data in VDB, for example, there are 4 procedures defined in PortfolioRest VDB as [2] under 'Rest' Model:
> * foo
> * getAllStocks
> * getAllStockById
> * getAllStockBySymbol
> Correspondingly, there are 4 api:
> ~~~
> http://{host}:8080/portfoliorest_1/rest/foo/{id}
> http://{host}:8080/portfoliorest_1/rest/getAllStocks
> http://{host}:8080/portfoliorest_1/rest/getAllStockById/{id}
> http://{host}:8080/portfoliorest_1/rest/getAllStockBySymbol/{symbol}
> ~~~
> With Swagger UI, it's easy to add a api-doc page for all api, [3] is a example.
> [1] https://docs.jboss.org/author/display/TEIID/REST+Service+Through+VDB
> [2] https://raw.githubusercontent.com/kylinsoong/teiid-quickstarts/master/dynamicvdb-restservice/src/vdb/portfolio-rest-vdb.xml
> [3] http://petstore.swagger.io/



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


More information about the teiid-issues mailing list