Ben Nadel
On User Experience (UX) Design, JavaScript, ColdFusion, Node.js, Life, and Love.
Ben Nadel at InVision In Real Life (IRL) 2018 (Hollywood, CA) with: Johnathan Hunt
Ben Nadel at InVision In Real Life (IRL) 2018 (Hollywood, CA) with: Johnathan Hunt@JHuntSecurity )

Recent Blog Posts by Ben Nadel

Using A File Upload Or The Request Body To Overcome The Slow Processing Of A Large Form POST In Lucee CFML

Yesterday, I demonstrated that Lucee CFML appears to incur a request-cloning cost when spawning CFThread tags . In most circumstances, this cost is negligible. However, if the parent HTTP request is generated by a large Form POST , the cost of spawning a CFThread tag can become shockingly ex... read more »

Lucee Appears To Incur Request-Cloning Overhead When Spawning CFThread Tags In Lucee CFML

Yesterday, we installed FusionReactor on some of our Lucee CFML servers in order to investigate curious JVM performance patterns. I'm still trying to understand what I'm seeing; but, I did notice something bizarre happening in some of the stack-traces. It looked as if the incoming HTTP Request Ob... read more »

Strange MongoDB Error When Incrementing A Document Property In Lucee CFML

Yesterday, I ran into a really strange error when trying to increment a numeric value on an in-memory MongoDB document in Lucee CFML Google didn't really provide any answers; so, I wanted to document the error here and share the work-around that I finally used. My ColdFusion code was at... read more »

Using A Closure To Encapsulate Depth-First Tree Traversal In Lucee CFML

In my last couple of Lucee CFML posts, I've looked at using a while loop to recursively iterate over a tree structure without creating a deep (and expensive) call-stack. I've done this using both a breadth-first algorithm and a depth-first algorithm . In both cases, the algorithm for the trave... read more »

Repositories And Data Access Layers Can Have As Many Methods As You Find Helpful

When I was first learning about Abstractions in programming, one of the early patterns that I came across was the Data Access Layer (DAL), which attempted to hide the implementation details of the underlying data persistence mechanism. I believe that the Repository Pattern is a more specific type o... read more »

Passing isArray() Decision Function Does Not Ensure Member Methods In Lucee CFML

This post is primarily a note-to-self so I don't make this mistake again. But, the other day, when I was working on the memory-leak detector code for Lucee CFML , I ran into a fun edge-case having to do with Reflection-style programming. In that post, I used Lucee's Decision functions (ex, isArra... read more »

Snapshotting ColdFusion Component State In Order To Find Memory Leaks In Lucee CFML

A couple of years ago, I wrote about a "Snooper" component that I created that would allow you to peek into the private scope of your ColdFusion component state in order to try and find memory leaks. That approach worked. Sort of. But, it was clumsy and hard to use. Then, the other week... read more »

Depth-First vs Breadth-First Tree Traversal Using A While-Loop In Lucee CFML

As part of my post yesterday on how I sometimes replace recursive algorithms with loop-based algorithms in Lucee CFML, I mentioned that the algorithm incidentally shifted from a depth-first strategy to a breadth-first strategy. In a follow-up conversation that I had about the post with fellow InV... read more »

Replacing Depth-First Recursion With A Breadth-First While-Loop In Lucee CFML

Recursion is a very powerful programming construct. And, I absolutely love recursion just as much as the next person (whether I'm dealing with recursive Promises in JavaScript , recursive templates in Angular , recursive components in Angular , or recursive algorithms in ColdFusion). But, recu... read more »

Struct Iteration Methods Like Each, Map, And Filter Include Null Values In Lucee CFML

Earlier this week, I was working on some reflection-style code in CFML wherein I was recursively looking through structs of data. As I was doing this, it occurred to me that some of the values stored in the structs could be null; and, I wasn't sure off-hand how Lucee would handle these values durin... read more »

Considering HTTP Methods PUT And PATCH Indicators Of An Anemic Domain Model And A Leaky Abstraction

A few years ago, I wrote about how I don't like "Update" methods in my API design . In that post, I talked about my "feelings" on the matter because I couldn't really articulate the red flags that were going off in the back of my mind. Over the weekend, however, I was reading t... read more »

The Unicorn Project: A Novel About Developers, Digital Disruption, And Thriving In The Age Of Data By Gene Kim

Early last week, I posted my review of The Phoenix Project : A Novel About IT, DevOps, and Helping Your Business Win. I found that book to be absolutely riveting. And, in the multitude of conversations that I was having about that book, I discovered that Gene Kim - co-author of The Phoenix Proje... read more »

Sand In The Gears As A Metaphor For People's Work Capacity

Yesterday, I reviewed The Phoenix Project , an excellent novel about IT, DevOps, and helping your business win. In the book, Kim et al talk a lot about resource utilization, task queues, idle time, and unplanned work. These are all topics that make some sense at an intuitive level; but, aren't a... read more »

The Phoenix Project: A Novel About IT, DevOps, And Helping Your Business Win By Gene Kim, Kevin Behr, And George Spafford

Last week, just before my holiday break, Chris Leavoy - one of our SREs (Site Reliability Engineers) here at InVision - recommended that people checkout The Phoenix Project by Gene Kim , Kevin Behr , and George Spafford . It's been a while since I've read a fiction book. And, given the fac... read more »

Getting ColdFusion Date Objects From UTC Milliseconds In Lucee CFML

The fun thing about maintaining a legacy code base is that you're constantly turning over stones to find new and exciting areas of code-rot and technical debt . Just yesterday, I discovered that one of my ColdFusion servers was deadlocked on some Date/Time code that was not thread-safe . The CF... read more »

Error Variable Randomly Exists After Running CFExecute In Lucee CFML

Yesterday, I was running into a bit of confusion when running the cfexecute tag in Lucee CFML When you define your cfexecute attributes, you have the opportunity to provide both a variable attribute and an errorVariable attribute that hold the success results and the error results... read more »

Linking My Loggly JSON-Parsing Bookmarklet To My JSON Explorer App

At work , we use Loggly as our log aggregator. Loggly has great search functionality; but, it has a host of user experience (UX) problems. Over the years, I've been trying to improve the UX of Loggly on my end with Bookmarklets , which has been a life-saver. But, one of the critical features that... read more »

Common Mistakes That Engineers Make During The Designer-Developer Hand-Off

As an engineer at InVision , I'd love to believe that having a Prototype ensures a project's success. But, the truth is, designing a prototype is only a step in the process. There's no doubt that it's an invaluable step ; but, it's just one of many. And, even with a prototype, there's ample opp... read more »

Creating Linked Slider Inputs Constrained To A Given Total In Angular 9.0.0-rc.5

Last weekend, I suddenly got inspired to create a set of linked slider / range input controls in Angular, where adjusting one slider would implicitly change the values of the related sliders. It seemed like a fun little code-kata; but, when I sat down to implement it, the challenge was more, well, ... read more »

Rendering A List Of Mixed Types Using NgFor And NgTemplateOutlet In Angular 9.0.0-rc.5

Earlier this year, I looked at rendering a list of mixed-types using ngFor and ngSwitch in Angular 7. The technique outlined in that post is the technique that I generally use. However, as of late, I've been doing a lot of experimentation with various use-cases for ng-template ; and, it rece... read more »

Rendering A TemplateRef As A Child Of The Body Element In Angular 9.0.0-rc.5

CAUTION : The concept that I explore here goes outside my area of expertise. As such, please take this with a grain of salt and forgive anything that is grossly inaccurate. A few weeks ago, I discovered that you could translocate Angular DOM nodes without breaking template bindings . This kind ... read more »

Using $any() To Temporarily Disable Type-Checking Within A Component Template In Angular 9.0.0-rc.4

In recent releases of Angular, type-checking has been extended to include our component templates. Which is awesome for catching compile-time bugs. However, the type-checking within our template is not quite as clever as the type-checking within our TypeScript code. For example, type-checking does... read more »

The Elvis Operator Can Be Chained Multiple Times In A Single Expression In Lucee CFML

In Lucee CFML, the "Elvis operator" - ?: - is a binary operator that returns the first operand if it is non-null; otherwise, it evaluates and returns the second operand. I haven't used the Elvis operator all that much, so I am still getting used to how it works. And, historically, I've ... read more »

Capturing Pointer Events Using Bookmarklets

As a web application developer, I spend a lot of time looking at the source code of HTML pages. This includes pages that my team has created; and, pages that I find in the wild about which I am curious. In either case, there's nothing more frustrating than right-clicking on an Element with the inte... read more »

Monolith To Microservices: Evolutionary Patterns To Transform Your Monolith By Sam Newman

Three years ago, I read Building Microservices by Sam Newman . And, in the years since then, I've been trying - and struggling - to wrap my head around the concept of microservices and distributed systems. While I think I understand microservices at a conceptual level, I continually find mysel... read more »

Fixing Connection Failure: Unable To Determine MIME Type Errors With sslCertificateInstall() In Lucee CFML

Yesterday, I took a look at tracking feature flags in New Relic Transactions as part of a Lucee CFML application. As part of that write-up, I had a CommandBox Lucee Server hitting my local development environment in order to simulate a steady stream of external HTTP traffic. At first, the traff... read more »

Tracking Feature Flags In New Relic And NRQL Using The Java Agent In Lucee CFML

Over the last few years, I've talked a lot about how much I love using LaunchDarkly feature flags . Feature flags have completely changed the way that we deploy changes here at InVision . One of the common use-cases we have for feature flags is to add code that we think will lead to a performance... read more »

TypeScript And .parentNode vs .parentElement

For years (?decades?), I've been using .parentNode to travel up the DOM (Document Object Model) tree. And, to be honest, I thought that was the only traversal option we had. However, over the weekend as I was perusing the Mozilla Developer Network (MDN) documentation - as you do - I happened ... read more »

Customizing A Select Component Using TemplateRef And NgTemplateOutlet In Angular 9.0.0-rc.3

A few weeks ago, Stephen Cooper was on the Adventures in Angular podcast discussing the use of the NgTemplateOutlet Directive as a means to customize components in Angular. This is a topic that I've touched-on briefly in the past ; but, it's been quite a while. And, since I just finished an ... read more »

Creating A Custom Select Component With The Options-Menu In The Root Stacking Context In Angular 9.0.0-rc.3

Over the last few weeks, I've performed a number of experiments in Angular 9 in an attempt to work towards a particular solution: how can I create a custom Select / Dropdown component in which the Options menu mimics the stacking-order provided by the native <select> element? This is tricky... read more »