The Summer of Loss

My name is Bob Bloom.

Today is Labour Day, 2018.

This has been my summer of loss.

After six weeks in palliative care, my mom passed away on July 19th.

After five weeks in post-operative care, my step father of 35 years passed away on August 22nd.

This was supposed to be the summer of code.

This was the summer that I release my LaSalle Software Version Two. My web application software based on the fabulous Laravel Framework, built on the micro-services architecture. Alas, this has not happened.

This fall, I look forward to releasing my Software.

This fall, I look forward to seeing you at our full slate of PHP meet-ups, which will start in October.

This fall, I look forward to seeing you at Richmond Hill Board of Trade events.

My podcast will resume in October.

Micro-services is the way to go for small and medium sized businesses. The costs have come down tremendously to make it worthwhile. So instead of having one huge website with integrated front and back ends, it is now feasible to have multiple front ends accessing a single back end. This makes it possible to have separate front ends for each line of business, for landing pages, for login areas, while using a unified database.

There is no standard micro-services software based on the Laravel Framework. So I am working on my own, starting with an API Gateway and Authentication Server.

-Bob

Cannot Implement Micro-Services. This Is What I Am Doing About It

Today is October 10, 2018.

The Laravel Framework cannot natively accommodate the micro-services architecture. Laravel’s internal Eloquent Object Relationship Mapping language is not set up to handle it.

From the (Laravel documentation):

The Eloquent ORM included with Laravel provides a beautiful, simple ActiveRecord implementation for working with your database. Each database table has a corresponding "Model" which is used to interact with that table. Models allow you to query for data in your tables, as well as insert new records into the table

Eloquent needs the full database resident in one location. Pieces of the database cannot reside in different physical databases.

The micro-service architecture requires multiple independent services. Each service is its own app with its own deployment and its own database.

Why after all this time have I just discovered this little problem? I finally looked the database square in the eye and realized that Laravel’s Eloquent is a no-go for micro-services.

I cannot have the user database in the authentication service, the blog database in the blogging service, the order database in the order service, etc. The data has to reside in a single physical database.

I could develop my own way of handling multiple databases, but then I will lose a key aspect of what makes the Laravel Framework so appealing. I am going to use Laravel and its Eloquent ORM.

I could use separate databases, but basically replicate the user management tables in each independent service. Um, no. Not Worth The Trouble. So many database tables relate to the user tables, and permissions are associated with the user tables, that each service would need the user tables.

The real fun starts when a service’s database tables relate to another non-authentication service’s database tables. Such as: a separate CRM database relating to the core user tables and the order service’s database tables. Now I have to wire these associations together as well.

So I asked myself what I really wanted to accomplish. Is LaSalle Software supposed to be an exercise in implementing the micro-services architecture? Not necessarily. A big thing that I want is a single administrative back-end to support multiple front-ends. A front-end can be natively mobile. A front-end can have a completely different domain than the back-end.

Maybe a car dealership wants a separate web app front-end for its service department and for its car sales department. The same people manage the front-ends, so it would be nice if there was just one single admin back-end with which to update each front-end.

I manage three meet-up sites. It would be handy to log into one admin back-end to update each site.

I want to off-load processes from the main back-end to somewhere else. This idea is very micro-services-ish. Laravel already has a facility for queuing processes, so I will make more prodigious use of queuing than I did in LaSalle Software Version One. The wonderful aspect of queuing is that the main process is not waiting for the queues to process. So I do not have to set up a new queuing service!

So, for what I want to accomplish, and for the type of web apps I envision, I can cheat. I can still achieve a micro-service-y architecture, and still retain the full power and scope of the fabulous Laravel Framework, by maintaining one single physical database. So that’s what I am going to do.

So I am going through my entire project again. In so doing, I am going through my version one code. I have now gone full circle, doing what I originally set out to do: clean up my version one code!

-->


LaSalle Software News Podcasts Contact Me