Search code examples
railolucee

Does server.railo exist on a Lucee instance or not?


I have this code:

<cfdump eval=server>

And it outputs top-level keys for coldfusion, java, lucee, os, separator, servlet. Note that railo is not listed there.

However if I do this:

<cfdump eval=server.railo>

It then outputs the usual struct one might expect when running a Railo server (as opposed to a Lucee server).

What's up with that?


Solution

  • see: https://groups.google.com/d/msg/lucee/1asgCDwC_tE/-gtE06lkjuEJ

    "server.railo" is supported as an alias for "server.lucee", we did this to make sure code like the following still work if(server.railo.version>"4.0.0.000");

    We saw this as an hidden feature for backward compatibility, because of that it is not shown with the dump or structKeyList, but structKeyExists should also return false, we will change this for the next patch release... best use "server.coldfusion.productName" instead.