Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nkonev/ktor-spring-example
https://github.com/nkonev/ktor-spring-example
ktor ktor-framework ktor-server spring spring-boot springboot springframework
Last synced: 10 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/nkonev/ktor-spring-example
- Owner: nkonev
- Created: 2021-12-28T07:43:33.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2022-01-06T10:57:41.000Z (almost 3 years ago)
- Last Synced: 2024-10-11T02:51:02.694Z (about 1 month ago)
- Topics: ktor, ktor-framework, ktor-server, spring, spring-boot, springboot, springframework
- Language: Kotlin
- Homepage:
- Size: 79.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
```
docker run --rm -d -p 27017:27017 mongo:5.0.5
```# Querying
```
curl -i -X POST -H "Accept: application/json" 'http://localhost:8098/customer'
```# Logging in
```
curl -i -X GET 'http://localhost:8098/login'
```# Getting session info
```
curl -i -X GET -H 'Cookie: user_session=48377d001c21a99547290c00395dd461' 'http://localhost:8098/session'
```# Logout
```
curl -i -X GET -H 'Cookie: user_session=48377d001c21a99547290c00395dd461' 'http://localhost:8098/logout'
```# Open Mongo
```
docker exec -it ktor-sandbox_mongo_1 mongosh
```# Stopping
```
kill -2 $(ps -ef | grep SandboxApplication | grep -v 'grep' | awk '{print $2}')
```# Save to mongo
```
curl -i -X POST 'http://localhost:8098/mongo'
```# Get from mongo
```
curl -i 'http://localhost:8098/mongo'
```