Where Should Business Logic Live?

As a newcomer to Text Blaze, I'm amazed at some of the recipes created and shared in this community. One that served as the tipping point for this commentary is from @Stephanie_Bouldin that contains some profound and carefully scripted logic that transforms a few keystrokes into a transparent workflow with a very predictable and productive outcome. Many other mind-bending snippets demonstrate how we can do so much more typing so much less.

Observation #1

No other text expansion product can do this. Hats off to the TB team. Stephanie's snippet and many others I've seen here validate some competitive advantages that place TB in what can only be described as defining (for itself) a new category. If TextExpander were the Estes of model rockery, Text Blaze would surely be SpaceX.

Observation #2

Where will the depth of business logic living inside a snippet end? The good news is there are no bounds; we can build, test, and share almost any workflow logic. And this logic has reach; it can communicate with other modern APIs. Logical components can be designed to lean on each other in a magical dance of reuse. The bad news; there are no bounds. :wink:

Observation #3

Arguably, Text Blaze is in the #no-code world. It makes it possible to do cody-like stuff without really being a coder. Business experts who understand how to create products and services that customers love can use Text Blaze without hiring expensing development talent. They can address critical business needs directly and in ways that even the best coders could not easily envision.

These three observations suggest [to me] that there's a potential for users to paint themselves into a corner, and it's central to the question in this title.

Where Should Business Logic Live?

I often ask myself and others this question over in the Airtable Community. Backup strategies alone present huge challenges that Airtable cannot [presently] address. Solution-builders effortlessly plough more business logic into formulas without considering the impact of catastrophic recovery should such logic be unintentionally deleted or destroyed.

Adjacent to this topic is the economics of scripting in a #no-code climate. The hidden side of scripting and software engineering is a classical blind spot. We write scripts (and snippets) because it's so easy, but not necessarily because it's the right approach or architecturally sound.

While I generally question the existence of deep logic in a snippet, I have to point out that Text Blaze brings three key abilities that mitigate my worries:

  1. Snippets are fundamentally javascript
  2. Data Blaze provides a unique persistence layer for snippets
  3. URLSend and the Data Blaze API make it possible to preserve, manage, and recover business logic

These abilities embrace the notion and attraction to move business logic to the edge - i.e., closest to the activity where such logic is most meaningful.

Marc Andreesen's watershed exposé, Software is Eating the World, was the prologue to Peter Levine's The End of Cloud Computing which heralds the future of an edge-centric computing model.

Most edge-related discussions point to compute-power and data at the edge as the biggest challenge. I think it's time we add business logic to this discussion, and I'd love to hear your feedback and especially the founder's thoughts concerning deep logic embedded in snippets.

3 Likes

I think this is a very interesting question.

In many ways Text Blaze is similar to Excel/Google Sheets/Data Blaze :smile:/etc... in that the presentation (or "view") layer is intermingled with business logic. This makes things very accessible and easy to adopt, but you can run into the same challenge that you have with spreadsheets where very complex spreadsheets can potentially become difficult to manage due to that intermingling.

What I personally do for complex snippets is to have a {note} block at the start or end of the snippet where I implement business logic, defining intermediate variables or inputs that I want to use. I find this to work well for me.

1 Like

Yep, and this is where dysfunction can breed very quickly.

Imagine a formula to compute (x) exists in a snippet, and it was patterned after a process initially developed elsewhere in the organization. Further, imagine the snippet version has a subtle flaw in it that was replicated from the original version. The flaw was recognized by the team that built the original version and corrected it, but the snippet-based replica remains flawed.

Copies of anything - especially cody-like things or spreadsheet formulas - can get you into tricky situations. In isolation, single-purpose one-off recipes are impervious to this. Deep business logic, not so much because, by definition, business logic tends to be core to the business value proposition.

This is indeed very useful. And I have observed that arbitrary content can be placed inside a {note} including syntactical tags like this...

{note}
{comment}...{endcomment}
{endnote}
{if: 1 == 2}
  Do this...
{else}
  Do that...
{endif}

This is a good example to deepen the conversation by asking - if you commented a given snippet, how would your team find snippets that contained keywords such that they might avoid creating the same snippet again?