###############################
Tue Mar 15 12:22:35 AM EDT 2022
###############################
A few days ago I wasn't feeling well ~ couldn't focus on
some day-to-day stuff. Gave my brain a rest ~ let it do what
it wanted to do for a bit.
A couple of days screaming into the void and issuing fatwas
against some ever-cheery and trendy tech youtubers who think
you can do anything on a pi, I suddenly have microk8s
running on a capable desktop with a few dockerized work
items and a few "functions" offloaded from some monolithic
processes to openfaas.
WTF, Brain?!? WTF...
If you ever start to think you've got installing,
configuring, and O&M of these self-hosted services down, ...
yeah.
OTOH, if you ever want a sharp lesson to make you go back
and understand how all those self-hosted things are built
and deployed on small scale, ... also yeah. :-p
Trying to describe my thinking to someone: "You know what it
really needs? It needs a smaller server off to the side -- a
bolt-on where you can offload longer running processes,
complex integrations, and async calls." I thought some
motorcycle imagery captured it best -- a "sidecar." Turns
out other people were clever well before me X-)
Anyway, kubernetes, "serverless," ... Some of it has me
thinking back to AppleScript and Automator, big pushes to
have monolithic product makers expose key functions from
their intellectual property as scriptable, drag & drop
functions that the end user could strap into their own
workflows. After that, "Service-Oriented Architectures,"
"The Cloud,", "*aaS" (for arbitrary values of *), ... It
never gets old, I guess.
Tonight I took a process out of a workflow and replaced it
with an API call to the same code reworked as a FaaS. It
gets hit a lot by different events, so why not? Take the
"function," template it for the openfaas platform, dockerize
it and push it to microk8s private container registry, spit
out the yaml descriptions and deployment instructions, and
we're good to go! ... except it was failing sometimes. Let's
try upping its availability with some replication... Better.
Except now those are just sitting there idle at off hours.
Auto-scaling -- right! Let's read up on that... Now I have
some somewhat heavy pieces of code spinning up just to make
that API call... Wouldn't it be better to just have that
piece of code just run right then and there without the API
call? Exactly when it's needed? Not keeping anything idle in
between? X-)
Whatever, friends. I know there are uses, sure. And it'll
probably look good on a resume someday. Most importantly
though? Brain / gut thought it was important, and there's
not much arguing with them.
We'll see where it leads.
Response:
text/plain