Google Java API conflicted with ColdFusion CFHTTP?

前端 未结 1 1331
遥遥无期
遥遥无期 2020-12-21 14:13

I tried copying all those JAR\'s found in the google-api-client-assembly-1.20.0-1.20.01.zip (downloaded from https://developers.google.com/api-client-library/ja

相关标签:
1条回答
  • 2020-12-21 15:07

    (From comments)

    Sounds like the jar that is conflicting is httpclient-4.0.1.jar. Removing it should resolve that specific error. However, it probably will not be the only conflict/error. A lot of the jars are pretty common, and could be used by CF as well, for example commons-logging-1.1.1.jar.

    Since you are using CF10, have you tried loading the jars in your Application.cfc using the new feature this.javaSettings? It is basically a rip of Mark Mandel's JavaLoader.cfc. Just specify the paths of the jars you wish to load, or the directories to check for jars, ie

    THIS.javaSettings = {LoadPaths = [".\folder\",".\folder\someLib.jar"] };

    Obviously when using this feature, do not put the jars in {cf_root}\lib, or anywhere else in the CF class path, as it defeats the purpose of dynamic class loading.

    0 讨论(0)
提交回复
热议问题