Skip to content

TimHess/steeltoe-data-showcase

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

steeltoe.data.showcase

The project is based on the Steel Toe framework. SteelToe is a developer API framework for DotNet core applications. It brings microservice design patterns and lessons learned from Spring Boot to the Dotnet world.

Included in the showcase

MonoRep

dotnet new sln
 
 dotnet sln add applications/service.api/steeltoe.data.showcase.csproj
 dotnet sln add applications/streaming.consumer/steeltoe.streaming.consumer.csproj
 account.service.csproj

Make components

mkdir -p  components/account.domain
cd components/account.domain
dotnet new classlib -f net6.0
cd ../..
 dotnet sln add  components/account.domain/account.domain.csproj
 dotnet sln add  components/account.service/account.service.csproj

Running Applications

Servie API Application

Set connection string environment environment

export ConnectionString="Host=127.0.0.1;Database=postgres;Username=postgres;Password=$POSTGRES_DB_PASSWORD"
cd applications/service.api
dotnet run

Testing with Swagger

open http://localhost:5000/swagger/index.html

List Account

open http://localhost:5000/swagger/index.html

Example List Results

List Accounts

Set up Migration

This application creates the needed database schema on startup.

Install DB migration

dotnet tool install --global dotnet-ef --version "7.*"

Create a migration

dotnet ef migrations add InitialCreate

View migration SQL script

dotnet ef migrations script

Testing

dotnet  test

About

steeltoe-data-showcase

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 88.2%
  • HTML 6.6%
  • Dockerfile 5.2%