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

CompilationFailedException consuming web services on CF10

Guest
Jun 21, 2013 Jun 21, 2013

Copy link to clipboard

Copied

I am trying to consume webservices on my CF 10 environment.  I keep getting a CompilationFailedException error looking for java/utils.  I have uninstalled CF, uninstalled the jdk, used the bundled jdk, reinstalled jdk 17.0_25 but to no avail.  I tried replacing C:\coldfusion10\cfusion\lib\tools.jar with the same file in the latest JDK as recommended on this forum on earlier releases encountering this error.

I have pasted the text from coldfusion-out.log but changed the name of the server with the wsdl.

Any direction is very appreciated.

Thanks

Jun 21, 2013 11:29:09 AM Information [ajp-bio-8012-exec-1] - Starting Web service request.

Jun 21, 2013 11:29:09 AM Information [ajp-bio-8012-exec-1] - Creating Web service proxy {url='https://serverdomain/rpc/soap-axis/confluenceservice-v2?wsdl'}

Jun 21, 2013 11:29:15 AM Information [ajp-bio-8012-exec-1] - Using Axis 1 for consuming the service https://serverdomain/rpc/soap-axis/confluenceservice-v2?wsdl.

Jun 21, 2013 11:29:16 AM Information [ajp-bio-8012-exec-1] - logAdmin Error: Application|coldfusion.jsp.CompilationFailedException: Errors reported by Java compiler:  Found 2 system errors:  *** Error: Could not find package ""java/util"" in:                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\classes                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\cf-bootstrap-for-flex.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\cfmx_bootstrap.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\cfx.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\commons-beanutils-1.8.0.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\commons-collections-2.1.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\cryptojce.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\cryptojcommon.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\jcm.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\jcmFIPS.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\js.jar                 C:\ColdFusion10\cfusion\wwwroot\WEB-INF\lib\portlet-proxy.jar                 C:\ColdFusion10\cfusion....|

Views

2.5K

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 ,
Jun 22, 2013 Jun 22, 2013

Copy link to clipboard

Copied

It remains unclear why you chose to use the external JDK/JVM. Since you are in a position to reinstall, I would suggest that you do so. After that, let ColdFusion use its own built-in JVM.

However, let's assume you wish to use the external JDK. You mentioned copying the file, tools.jar, from the external JDK to ColdFusion's lib directory. However, it is unclear whether you had reconfigured ColdFusion beforehand to use the external JDK. You can either do that in the ColdFusion Administrator or, equivalently, by modifying the java.home option in the jvm.config file to something like

java.home=C:\\Program Files\\Java\\jdk1.7.0_25\\jre

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
Guest
Jun 25, 2013 Jun 25, 2013

Copy link to clipboard

Copied

Thank you.  I was hoping to resolve this without reinstalling.  I have done so several times since first encountering this issue.  updating the tools.jar was following resolution from a thread elsewhere where CompilationFailedException occurred with Error: Could not find package ""java/util"".

I upgraded to a newer JDK because of the recent hotfixes involved going to JDK 1.7 as JDK 1.6 was no longer supported by Oracle.

Here is my java.config.

#

# VM configuration

#

# Where to find JVM, if {java.home}/jre exists then that JVM is used

# if not then it must be the path to the JRE itself

#java.home=C:/ColdFusion10/jre

java.home=C:/ColdFusion10/jdk1.7.0_25/jre

application.home=C:\\ColdFusion10\\cfusion

#

# If no java.home is specified a VM is located by looking in these places in this

# order:

#

#  1) ../runtime/jre

#  2) registry (windows only)

#  3) JAVA_HOME env var plus jre (ie $JAVA_HOME/jre)

#  4) java.exe in path

#

# Arguments to VM

java.args=-server  -Xms512m -Xmx1024m -XX:MaxPermSize=192m -XX:+UseParallelGC -Xbatch -Dcoldfusion.home={application.home} -Dcoldfusion.rootDir={application.home} -Dcoldfusion.libPath={application.home}/lib -Dorg.apache.coyote.USE_CUSTOM_STATUS_MSG_IN_HEADER=true -Dcoldfusion.jsafe.defaultalgo=FIPS186Random -Dcoldfusion.classPath={application.home}/lib/updates,{application.home}/lib,{application.home}/lib/axis2,{application.home}/gateway/lib/,{application.home}/wwwroot/WEB-INF/flex/jars,{application.home}/wwwroot/WEB-INF/cfform/jars

# Comma separated list of shared library path

java.library.path={application.home}/lib,{application.home}/jintegra/bin,{application.home}/jintegra/bin/international,{application.home}/lib/oosdk/classes/win

java.class.path={application.home}/lib/oosdk/lib,{application.home}/lib/oosdk/classes

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 ,
Jun 25, 2013 Jun 25, 2013

Copy link to clipboard

Copied

Your JVM configuration file looks fine. The error message might be quite literal. If so, then it is telling you that compilation of a source file, very likely one of yours, failed. It tells you more. The source may be referring to "java/util" as a package, rather than to "java.util".

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
Guest
Jun 26, 2013 Jun 26, 2013

Copy link to clipboard

Copied

Thanks again.  Unfortunately, there is no compilation of a file.  It is a call to a web service on another CF site using CF 9.  When I had CF 9 running on my dev box, the call works fine.  Now that I am on CF 10 on the dev box, when I call the same web service, I get this message.

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 ,
Jun 26, 2013 Jun 26, 2013

Copy link to clipboard

Copied

Then, my, does that error message really suck. I saw an old fix for this on the web, that says you should add the lib directory to the classpath, for example, like this:

application.home=C:/ColdFusion10/cfusion

java.class.path={application.home}/lib,{application.home}/lib/oosdk/lib,{application.home}/lib/oosdk/classes

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
Guest
Jun 26, 2013 Jun 26, 2013

Copy link to clipboard

Copied

That message sure does.  ""java/util"" must be a place holder.  I added lib to the class.path and there is no difference.  I am going to punt.  Uninstall CX, reinstall, apply hotfixes, rebuild sites in IIS and see if results are different.  This is just crazy.

Are you on CF 10 and consuming Web Services successfully?

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 ,
Jun 27, 2013 Jun 27, 2013

Copy link to clipboard

Copied

Perhaps incompatibility issues between Axis 1 and Axis 2 web services? What happens when you put the following at the beginning of your Application.cfc, testing them in turn:

<cfset this.wssettings.version.consume = "2">

<!--- <cfset this.wssettings.version.consume = "1"> --->

To answer your question, I consume web services successfully. My version is 10.0.10.284825.

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
Guest
Jun 27, 2013 Jun 27, 2013

Copy link to clipboard

Copied

I went ahead and did the uninstall route, got rid of all java, even ran CCleaner to get rid of any java related entries in the registry.  Now after applying the keystore, the error is back.  When I toggle to the <cfset this.wssettings.version.consume = "2"> I get an error message "Cannot generate stub objects for web service"  I enter the wsdl url in a browser and see WSDL created by Apache Axis version: 1.2.1, so I switch back to <cfset this.wssettings.version.consume = "1">.  As for version, I am a fresh install with the manditory update applied only.  I was fine before reinstalling and now I cannot apply hotfixes through CFAdmin. 

I really appreciate you sticking with me on this but I am definitely at my wits end.  It just keeps getting worse.  Thankfully this is my local dev install.  I sure hope it goes goes better on the prod server install.

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 ,
Jun 29, 2013 Jun 29, 2013

Copy link to clipboard

Copied

There is something not quite right happening on your development server. Could you follow a clean procedure right from the start?

By this I mean, install ColdFusion, letting it use the JVM that ships with it. No keystore, no extra Java, just ColdFusion 10. Then open the ColdFusion Administrator and apply the updates.

Next, do a test. Set up a basic CFC containing one function that returns the string "Hello World". Then use that as the basis for consuming a web service locally.

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 ,
Aug 20, 2014 Aug 20, 2014

Copy link to clipboard

Copied

LATEST

It must have been something specific to the Dev server and some patch or setting.  I got a new box, installed CF10 and was able to consume web services.  I unfortunately have no idea what it 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
Resources
Documentation