c# – How to organize database access logic for the infrastructure and application layer when avoiding ORM tools?

ORMs like Entity Framework do not preclude you from using Raw SQL queries.

If Entity Framework is a bit too much for your liking, consider using Dapper or any of a number of different micro-frameworks. These tools remove a lot of the hassle of making a connection to the database and managing query parameters without encountering Little Bobby Tables, allowing you to focus your time and effort on writing the SQL queries.

ORMs also serve as your Data Access Layer, abstracting CRUD operations away from the more interesting Service Layer of your application. If you still feel like writing your own Data Access Layer, you can still do so. You will need one class and four methods for each table in your database (Create, Read, Update & Delete).

The way you manage your connection can vary. Depending on how quickly MariaDB can open connections and whether or not it caches connections, you might want to just open a connection for each query. You could also do it at the Aggregate level if you’re practicing DDD. Or, you could simply open a connection and leave it open. It really all depends on your application and what you want to do with it.

One file per SQL statement sounds like a bit much. Try putting your SQL statements inside your entity classes; it’s a very convenient place to stash them.

Folder structures are largely a matter of taste. There’s no “standard,” and everyone does them differently.

Further Reading
P of EAA : Data Mapper
P of EAA : Repository
P of EAA : Service Layer

What Are The Best Paid Seo Tools In 2020?


dnd 5e – Do cobbler tools work on horseshoes?

Xanathar's Guide to Everything significantly expands the use of tools. Here are parts of the section on Cobblers & # 39; Tools:

Although the cobbler trade may seem too modest
As an adventurer, a good pair of boots will see a character
through rough wilderness and deadly dungeons.

Components. Cobbler’s tools consist of a hammer,
an awl, a knife, a shoe stand, a cutter, spare leather,
and thread.

Take care of your shoes. You can repair during a long break
your companion's shoes. For the next 24 hours up to six
Creatures of your choice who wear shoes you've worked on
can travel up to 10 hours a day without saving
throws to avoid exhaustion.

The book also extends the craft and its requirements:

A character must be familiar with the tools
needed to craft an item and have access to the appropriate equipment.

My question is: If you are familiar with Cobblers tools, can the advantages (making non-magic and magic shoes, caring for shoes, etc.) also apply to horseshoes? Or are shoes and horseshoes too different from each other?