architecture - Should you store current application state in a database? -
i have started working on project postgres database used integral component in system architecture. has forced me abandon previous notions database well, store things.
there api translates incoming requests database queries/updates. causes triggers in database notify application update actual system accordingly.
to me seems unnecessary. in system critical architecture, , yet have no way guarantee knowledge of underlying systems failure making chain since async. in short don't @ all. view should restart scratch using direct communication between api , underlying system, using database store persistant state updates / user information etc.
what i'm looking here explain me why i'm wrong before end falling out team, views welcome.
the reason support such integration low cost, if 2 integrated systems uses own proprietry technologies comminucating bad each other. also, db integration presents old style of integration.
what want acheive (or @ least increase) called "autonomy". big topic talk about, i'll try highlight important things according situation.
- triggers , stored procedures evil. leads "logic leak" db , hence results in bad portability , maintainability of busines logic , whole app. thing stored procedures may usefull increasing of performance. there many ways tune performance without them.
- as applications connected via db dealing tight coupling between them, tightly depend on each other , hence maintainability , reusability of both applications suffer.
- by connecting of applications via db in complex manner may stuck scaling in future.
- using db solution invokation of dealing coupling technology, not designed that. it's bad because of inflexibility , possible future limitations. more poorly if non-standardized of proprietary tools , protocols used.
today (enterprise) best practice in using of autonomous applications application (not integration) non-shared database, communicating via standardized protocol, through reliable middleware. more expensive provides lots of benefits (scalability, maintainability, flexibility, etc).
to decide if should rewrite something, @ first need estimate costs , benefits. if big legacy tightly coupled composition works fine, it's better way not touch it, create facade-like wrapper if needed.
finally,
what i'm looking here explain me why i'm wrong
i don't think wrong.
Comments
Post a Comment