An open API service indexing awesome lists of open source software.

https://github.com/cosh/spring-boot-sqlserver-test


https://github.com/cosh/spring-boot-sqlserver-test

Last synced: about 1 year ago
JSON representation

Awesome Lists containing this project

README

          

[![Build Status](https://travis-ci.org/cosh/spring-boot-sqlserver-test.svg?branch=master)](https://travis-ci.org/cosh/spring-boot-sqlserver-test)

# spring boot sqlserver test on Azure

this is a small test project in order to verify the jdbc connection string for a MSSQL server on azure

## build

mvn clean package

## run
set the following config parameter:
* sqlserver.test.database (the database name)
* sqlserver.test.node (the database host/node)
* spring.datasource.username
* spring.datasource.password

java -jar target/sqlserver-0.0.1-SNAPSHOT.jar --sqlserver.test.node=YOURDATABASENODE --sqlserver.test.database=YOURDATABASENAME --spring.datasource.username=YOURUSERNAME --spring.datasource.password=YOURPW

## test

### create a new person

curl --user user:password  -X POST -d '{"name": "cosh", "salary": 23}' http://localhost:8080/person --header "Content-Type:application/json"

### get all created persons

curl --user user:password  -X GET http://localhost:8080/person --header "Content-Type:application/json"