Intermittent CFC not found - Coldfusion 2021 Standard

227 Views Asked by At

We have a very strange issue. We have a large CF application that was originally written in CF9, upgraded to CF2016, then onto CF2021. There is a invoicing job that runs as a scheduled task everyday. This invoicing job does many steps (creates, checks, and pays) invoices. There are many components (functions) that are used during this process. We went live with this new server in late November of 2021 and since we have done that, the invoicing job has had issues about 4 or 5 times so far.

The errors I am seeing are usually something like:

Could not find the ColdFusion component or interface components/distributor.distribcontroller.

I say usually, because even the "missing" component changes and they are different each time.

I have checked every component for errors, so that should not be it and most days this invoice job runs fine.

CF2021 is running on Ubuntu 20.04 LTS, 4 CPU.4GB ram. other than this invoice job, application is fine (users never experience missing components)

I also do not use mappings, I have a custom mechanism where I set the compent path in a cfm file and use the "request" structure like: <cfset request.components.distributor = 'components/distributor'> in a file that gets included in the Application.cfc - its may not be ideal, but it is just the was it was build years ago and too much work to change it. (i think).

Any ideas? Any help would be appreciated.

1

There are 1 best solutions below

1
On BEST ANSWER

I have a custom mechanism

Feels like a red flag. Especially since it uses the request structure.

How many CFCs are you dealing with? Would it be worth looking at WireBox to handle CFC configuration and creation? Might be overkill for the current issue, but worth looking into.

https://wirebox.ortusbooks.com/

Are you caching component paths? It may be that unchecking the component cache could address this issue.

You might post this issue over on the CFML Slack workspace. Some of the Adobe CF Engineers hang out there.