April 2, 2021
COLDFUSION 2021 MIGRATION FROM COLDFUSION 11 ISSUE
Comments
(10)
April 2, 2021
COLDFUSION 2021 MIGRATION FROM COLDFUSION 11 ISSUE
Newbie 2 posts
Followers: 1 people
(10)

I am trying to go from ColdFusion 11 to ColdFusion 2021 and I am having issues with the Datasource connection in the Administrator.  I can verify that the datasource is working and connecting properly to my Oracle database but when I try and select the edit button I get the following error:

Element urlmap.servicename is undefined in STDSN.  The specific sequence of files included or processed is f:coldfusion2021/cfusion/wwwroot/administrator/datasources/oracle.cfm, line:653.

When I try and open this file it shows that it is encrypted and I cannot read the data.

10 Comments
2022-08-11 14:35:36
2022-08-11 14:35:36

Hi Charlie,

In our agency we planning migrate CF16 to CF21, I install CF21 and place code without any issues, however

when I run application on CF21 I have this errors:

class coldfusion.runtime.ApplicationScope cannot be cast to class coldfusion.runtime.Struct (coldfusion.runtime.ApplicationScope and coldfusion.runtime.Struct are in unnamed module of loader coldfusion.bootstrap.BootstrapClassLoader @2fb25f4c)

on CF2018 no any errors .

could please give us suggestions

Like
()
(8)
>
albert3162
's comment
2022-08-11 15:20:13
2022-08-11 15:20:13
>
albert3162
's comment

Albert, that problem would not be at all related to the issue in this post. But I realize the title has left it seeming as good a place as any to ask about your issue. 🙂 

But I will go further and say that I don’t think your error is a “migration” error (like anyone could get in such a migration of cf versions), and I don’t expect it has anything to do with your specific cfml code.

Instead, I suspect it’s a specific configuration issue, or perhaps a failure during your install or recent update to cf. Or maybe someone fiddled with some config files, trying to solve another problem.

Honestly, there are too many possibilities, as well as diagnostics, to consider. I doubt it’s something you can reasonably hope to solve based on that info alone. If this is important to solve, I’d say that we could have a zoom session together where I could help guide you to the solution. It would likely take less than an hour. For more on that, see carehart.org/consulting.

But also, I’m on my phone as I see this. When I get back to my computer, I may well find something to offer specific to that error, based on prior discussions/help I’ve offered. If you were to grab a slot, but then I found the answer and we didn’t need to meet, there would be no charge of course.

Just giving you options, and something to chew on to start. Maybe someone else will offer something else sooner.

Like
()
>
albert3162
's comment
2022-08-11 21:00:51
2022-08-11 21:00:51
>
albert3162
's comment

Albert, I finally got a chance to do more digging, into both thousands of past email discussions, my notes from thousands of client engagements, and even searching the tracker.adobe.com. I just find no other reference to that error, “class coldfusion.runtime.ApplicationScope cannot be cast to class coldfusion.runtime.Struct”.

But here’s something else you can check: see the CF logs (especially coldfusion-error.log, coldfusion-out.log, and the server.log) during the time that CF started (for the run where you get this error accessing your apps). You may find it indicating that the startup tripped over something. I could be a bad config file, or something.

Indeed, did you by any chance copy in any neo*.xml files from another CF instance (or earlier version), into the cfusion/lib folder of this instance? You should not do that. Or might you have tried to use the CAR import feature? If so, there will be car* logs in the CF logs folder. Perhaps something failed during that import.

Or did you let CF import settings at initial startup? If so, there will be migration*.log files. Again, perhaps they will indicate a problem.

Finally, to find out if there’s a connection to some CFML you’re failing app is running (though I’d not expect that sort of error for a coding issue), you could create a new folder where you run your CFML code, and in that create a blank application.cfm file, then a blank test.cfm file. If you then request that folder’s test.cfm via the URL for your app, does that return a blank page or an error? If a blank page, what if you add some simple CFML code, like <cfdump var=”#server#”>?

Like
()
>
Charlie Arehart
's comment
2022-08-12 16:51:59
2022-08-12 16:51:59
>
Charlie Arehart
's comment

Albert, I’m curious to hear if you solved things. Other readers following along may wonder as well (if they search for that error and find your comment in this post).

Like
()
>
Charlie Arehart
's comment
2022-08-12 18:39:19
2022-08-12 18:39:19
>
Charlie Arehart
's comment

Charlie,

Thank you for curiosity, I spend whole day to re-install CF21 many times, clean all registers- and so on, however just now install application and the same error returned:

class coldfusion.runtime.ApplicationScope cannot be cast to class coldfusion.runtime.Struct (coldfusion.runtime.ApplicationScope and coldfusion.runtime.Struct are in unnamed module of loader coldfusion.bootstrap.BootstrapClassLoader @2fb25f4c)

all logs ok,

I already, sent email to adobe support, our agency has this, I am working in SSA

Like
()
>
albert3162
's comment
2022-08-12 19:03:55
2022-08-12 19:03:55
>
albert3162
's comment

Ok, but did you see my second comment? I made specific suggestions that you’ve not yet responded to. I’m just trying to help.

If they don’t help, I suppose you may feel your hands are tied and you have no choice but to await Adobe’s support. If they fail to help, I’ll say that perhaps I can. That may sound arrogant to some, but it just depends on the problem, who at Adobe may get involved to try to solve this for you, and how they may go about it. I do this troubleshooting daily (as do some on the cf team, of course).

I’ll say that if somehow days pass and you want it solved, I’d like to try–even at no charge. I want to know what causes this error. But in that case, please do start with considering the things I suggested.

Like
()
>
Charlie Arehart
's comment
2022-08-15 13:51:22
2022-08-15 13:51:22
>
Charlie Arehart
's comment

Charlie,

I did go with your second comments, no any errors on log files.

This application very complicate, the first several pages like menu page works, however when code try to work with webservices and use VBScript we gat his message.

Like
()
>
albert3162
's comment
2022-08-26 14:51:13
2022-08-26 14:51:13
>
albert3162
's comment

Albert, my second message had mentioned far more than just to see if there were “any errors on log files”.

Now that you say this happens on a specific page and not others, there’s more you can do to debug where exactly this is failing in that page. Put a cfabort at different places to find what prevents the error.

And you mention web services. Are you saying this happens when cf calls out to a web service? What if you do a cfabort before calling it? (Finally, you mention vbscript, but cf would have nothing to do with that.)

If you can’t solve this on your own, I had proposed in my first reply 2 weeks ago that I could help solve this directly via a remote consulting session such as with zoom. I realize you may not PREFER to do that (or may even think you are not ALLOWED to do that), but how many weeks are your folks willing to wait for you to solve this on your own? If you can’t, why would you not be allowed to get help?

And as I explain on my site, we should not likely need more than an hour for most problems, and you’d not pay for time you did not feel was valuable. Again, carehart.org/consulting. I have slots open even today, as can be seen and selected in the online calendar whose link is also offered there.

Or we can slog on here or in the forum thread you opened also on Wed. I just saw that, and it led me to your reply here, which I’d missed last week.

Like
()
>
Charlie Arehart
's comment
2022-08-29 16:10:45
2022-08-29 16:10:45
>
Charlie Arehart
's comment

Charlie,

I do prefer do that, it the past we used Microsoft team, however I need ask my management work with ZOOM this is a Federal Agency, SSA

Like
()
2021-04-05 22:17:35
2021-04-05 22:17:35

Yes, there is a “fix” for this (at least a workaround).  To be clear, the problem is not in the cfm file you were looking at (Adobe encodes their templates so that they are not readable). Instead, the problem is in the underlying XML file that holds information about your datasource. And it seems to be a bug related to importing settings from an earlier version. Can you confirm if you or someone did that?

Anyway, the “good” news is that this same issue was raised about a month ago as a question in the Community forums (you have asked here instead in the CF portal, which is fine), and the author of that eventually shared a workaround that worked for him, in one of his last comments. (See a follow-on comment I just added there, right after his, which may help you as you parachute into that thread, to try his solution.)

FWIW, he also opened an Adobe Tracker bug report on the issue, but it is as yet not resolved (or even acknowledged by Adobe), so it does NOT seem to be in the CF2021 update 1 that came out a couple of weeks ago.

Let us know if that work-around works for you. It’s a bit fiddly. If you feel unsafe doing it, you can hire someone to help (myself included, at carehart.org).

Like
()
Add Comment