Three New Taffy Releases: 4.0.1, 4.1.0, and 5.0.0

Tags: #taffy, #open source, #coldfusion

Yesterday I released three new versions of Taffy, the best REST API framework for ColdFusion and Lucee: 4.0.1, 4.1.0, and 5.0.0. A patch, a minor, and a major, all in one day.

The highlights are resource grouping in the dashboard and docs, useful errors for missing inputs, and tools to find slow resource initialization. Taffy 5 also has four breaking changes, detailed below with instructions for upgrading.

Most users upgrading from Taffy 4.0 to 5.0 won't need to change any code. The breaking changes affect older Adobe CF engines and a few default behaviors. They're worth reviewing, but this should be a straightforward upgrade for most APIs.

Taffy 4.0.1: compatibility fixes

Release notes and download. No breaking changes.

  • Null external bean factories: Fixed a startup failure when the external factory is null. This bug only affected users with "true null support" enabled.
  • Adobe ColdFusion 2025: Added compatibility fixes and expanded automated testing against current Adobe CF releases.

Taffy 4.1.0: grouping and better request handling

Release notes and download. No breaking changes.

  • Resource groups: Taffy can now group related resources in the dashboard and generated docs. By default, resources are grouped by their first URI segment: /messages and /messages/{id} both appear under messages. Set taffy_docs_group on a resource to assign it to a different group. The generated OpenAPI spec uses these group names as tags.
  • Missing required inputs return 400: Instead of a generic 500, the response names the missing required fields. Override onTaffyMissingArguments() to customize that response.
  • Optional dashboard inputs stay optional: Request body templates omit optional arguments without defaults and preserve declared default values.
  • DI/1 resource discovery: Resources are discovered correctly when omitDirectoryAliases is enabled.
  • Multipart PUT on Adobe CF: Form fields and file uploads no longer get dropped from multipart PUT requests.

Taffy 5.0.0: breaking changes

Release notes and download. These changes are in addition to everything in 4.0.1 and 4.1.0.

1. Adobe ColdFusion 2021 is the minimum supported ACF version

Taffy 5 drops support for Adobe ColdFusion 2016 and 2018. Upgrade your engine to 2021 or later before upgrading Taffy. If you're staying on either older engine, use Taffy 4.1.0.

Lucee 5 through 8 remain supported. This change only raises the Adobe CF minimum.

2. The dashboard and docs default to collapsed resource groups

Grouping was added in 4.1.0; making it the initial view is the breaking change in 5.0.0. The dashboard and generated docs now start in grouped mode, with all groups collapsed. A view preference already saved in the browser still takes precedence.

To keep the Taffy 4.x initial alphabetical view by resource name, set this in Application.cfc:

variables.framework.defaultResourceView = "name";

You can also choose "uri", "match", or "group". See the resource view setting for details.

3. Disabling automatic CORS now actually disables it

allowCrossDomain defaults to false. Previously, Taffy could still supply some CORS headers and automatic OPTIONS responses with that setting disabled. Taffy 5 respects it: false disables both automatic resource CORS headers and automatic OPTIONS responses.

If your browser clients relied on that behavior, explicitly enable CORS. For example, allow your frontend's origin:

variables.framework.allowCrossDomain = "https://app.example.com";

The setting also accepts a list of allowed hosts, or true to allow any origin. If your application handles CORS itself, keep it disabled and supply your own headers and OPTIONS handler. Review the CORS configuration when upgrading.

4. API responses ask search engines not to index them

Taffy now sends X-Robots-Tag: noindex on API responses by default, including routing and resource errors. If you intentionally serve indexable content through your API, opt out in Application.cfc:

variables.framework.robotsTag = "";

That removes Taffy's default header; an X-Robots-Tag set in globalHeaders still applies. You can also override an individual response with .withHeaders({"X-Robots-Tag": "all"}).

The dashboard, generated public docs, and OpenAPI endpoints don't receive this policy. It's a request to cooperating crawlers, not access control. See the migration notes.

Everything else in Taffy 5, briefly

  • Read resource metadata: getTaffyMetadata() and getTaffyMetadataValue() expose taffy: metadata, including your own keys. Method values override component values, and onTaffyRequest() receives the merged metadata too.
  • Find slow cold starts: Enable variables.framework.profileStartup to see resource construction and dependency injection timings in the dashboard's Startup Profile, sorted slowest first. It's off by default. Startup profiling details.
  • Required URI arguments: The dashboard docs correctly label URI token arguments as required.
  • Route aliases in docs: Following an alias opens the correct resource panel.
  • Empty URI tokens: Empty values are passed through without throwing an error or shifting later tokens into the wrong arguments.

If you need to stay on Adobe CF 2016 or 2018, 4.1.0 gives you resource grouping and the 4.x fixes. Most users can move from 4.0 to 5.0 without code changes; just check your engine version and the three default behaviors above before upgrading. Grab a release and give it a try!

Webmentions

It's like comments, but you do it on social media.

Be the first to share this article on Bluesky or Mastodon.

Webmentions via webmention.io.

Edit on GitHub • Contributions