End of the Year and a new Book | 220101


220101

Now What

So I am going to try and break down each of the services that I have created to SQL schemes/Queries with the necessary item so that don’t have go into the database for any reason.

So stuff like this: sqlQuery Looking at that code you ’ll see items that lock me into postgres,(pgx , & “information_schema.table”) which removes one of the advantages of using pure SQL and that it can be database Agnostic. I may end hating this later, but whatever send it.

I am trying find a way to not have to maintain both the model for json and the sql schema together in the same struct so when I need to make changes or additions i can in one place, but there doesn’t seem to be one that can do that with references to other tables

Here is sqlx, but I still have to maintain the schema separate,

This is sqlx enter image description here

GORM did that, but doesn’t seem to a viable option for micro services or at least at my understanding for what I want to do with.

Next things

Reading another Book

If I am going to do the microservices things I guess I should read their bible things. Cause I think I missing some information on this topic. Going to Cherry pick some chapters that seem relevant to see if any insight can be gained Microservices Patterns

Get some schema together

With this I have exactly what I want, but I also have know what I want so a double edge sword.

This is not what I going with, but show some things, but is still very wrong Server Information

Red: UUID this was easier than I thought to get working, but I will need the extension to be enabled for each database it used in. Just another thing to error check for and implement.

Blue: Postgres allows for arrays, but after reading up on them they do append when updating they update the whole array which is a waste, so I think going with inter-between table for many-to-many at least.

Yellow: just being able to do a reference. I think have be able to alter a table with running a query while still using GORM, but doing so makes me just not want to use GORM or any ORM(go-pg did the same thing).

#devemeber2021

So I failed, but I will continue to work on this item for some time, but I need to find a new job so that may take of available brain availability

I will keep going with this. It was always a study first and it lined up with #devemeber2021. Granted I was hoping to get farther than getting to temporary user data model to implement messages and realizing my database interface conflicted with microservices aspirations.

https://i.imgur.com/rQIb4Vw.mp4