• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Suddenly getting dreaded "Could not find the ColdFusion component or interface"

New Here ,
Nov 19, 2021 Nov 19, 2021

Copy link to clipboard

Copied

Coldfusion 2018, Linux server

This is on our development site but was working until last week. We've googled and see this is not uncommon and tried the suggested solutions such as creating a mapping, which seems the most popular, and a few others but nothing seems to fix the issue.

The development machine is shared so each developer is mapping their CFCs to their own unique location and each application has a unique name even on the same server, a hash is involved. 

 

When we create the Create the object

<cfobject component="/#APPLICATION.cfcroot#.Security" name="sec">

 

It seems to find the Security CFC because the error is on the "extends" attribute which is set to a CFC called Authenticate.

<cfcomponent extends="Authenticate" accessors="true" output="false" persistent="false">

 

It can't find the Authenticate CFC which is in the same directory and throws the error, "Could not find the ColdFusion component or interface var.www.html.mark.financeonline.account_services.cfcs.Authenticate". Which is the correct location just replace the dots.

 

Views

226

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 20, 2021 Nov 20, 2021

Copy link to clipboard

Copied

Is the component path 

"/#APPLICATION.cfcroot#.Security" ("/var.www.html.mark.financeonline.account_services.cfcs.Authenticate")

or is it

"#APPLICATION.cfcroot#.Security" ("var.www.html.mark.financeonline.account_services.cfcs.Authenticate")?

What happens when you use the following:

<cfobject component="#APPLICATION.cfcroot#.Security" name="sec">

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 22, 2021 Nov 22, 2021

Copy link to clipboard

Copied

Both of the examples you gave look the same to me. I tried the line you recommended and I got the same error:

Could not find the ColdFusion component or interface /emily/afo.Security.

and

Could not find the ColdFusion component or interface var.www.html.emily.afo.account_services.cfcs.Authenticate.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 22, 2021 Nov 22, 2021

Copy link to clipboard

Copied

Strange indeed.

The relative paths /emily/afo.Security and emily.afo.Security represent different notations. So, try the following test, just to rule out any differences:

<cfoutput>	
	APPLICATION.cfcroot: #APPLICATION.cfcroot# <br>
	fileExists(APPLICATION.cfcroot & ".Security.cfc"): #fileExists(APPLICATION.cfcroot & ".Security.cfc")# <br>
	fileExists("/" & APPLICATION.cfcroot & ".Security.cfc"): #fileExists("/" & APPLICATION.cfcroot & ".Security.cfc")# <br>
	fileExists(APPLICATION.cfcroot & ".Authenticate.cfc"): #fileExists(APPLICATION.cfcroot & ".Authenticate.cfc")# <br>
	fileExists("/" & APPLICATION.cfcroot & ".Authenticate.cfc"): #fileExists("/" & APPLICATION.cfcroot & ".Authenticate.cfc")# <br>
	fileExists("var/www/html/mark/financeonline/account_services/cfcs/Authenticate.cfc"): #fileExists("var/www/html/mark/financeonline/account_services/cfcs/Authenticate.cfc")# <br>
	fileExists("/var/www/html/mark/financeonline/account_services/cfcs/Authenticate.cfc"): #fileExists("/var/www/html/mark/financeonline/account_services/cfcs/Authenticate.cfc")# <br>
	fileExists("var/www/html/mark/financeonline/account_services/cfcs/Security.cfc"): #fileExists("var/www/html/mark/financeonline/account_services/cfcs/Security.cfc")# <br>
	fileExists("/var/www/html/mark/financeonline/account_services/cfcs/Security.cfc"): #fileExists("/var/www/html/mark/financeonline/account_services/cfcs/Security.cfc")# 	 	
</cfoutput>

<cfabort>

<cfobject component="#APPLICATION.cfcroot#.Security" name="sec">

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 23, 2021 Nov 23, 2021

Copy link to clipboard

Copied

Oh, could you please share the above output?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Nov 29, 2021 Nov 29, 2021

Copy link to clipboard

Copied

Problem solved?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Dec 01, 2021 Dec 01, 2021

Copy link to clipboard

Copied

Thanks for the assitance I was told that the team did resolve the issue, although I'm not sure what the fix was.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 01, 2021 Dec 01, 2021

Copy link to clipboard

Copied

LATEST

Thanks for the update.

This is a common problem, as you yourself hinted. Many, like me, would therefore be grateful if you could share your team's solution here. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation