Your browser was unable to load all of the resources. They may have been blocked by your firewall, proxy or browser configuration.
Press Ctrl+F5 or Ctrl+Shift+R to have your browser try again.

Getting HessianProtocolException: unknown code:C #2046

qbuser ·
I am attempting to automate QuickBuild configuration changes using the com.pmease.quickbuild Java API. We are now running QuickBuild version 4.0.61. The only Java automation we have written in the past was for QuickBuild 1. I am using class com.pmease.quickbuild.RemoteService, method getConfigurationByHierarchyName to obtain a configuration from our new QuickBuild 4 instance. When I ran the program, I get a HessianProtocolException. Line 40 of the following code snippet throws the exception:


34
35 RemoteService remote = (RemoteService) factory.create(RemoteService.class, url);
36
37 // get the configuration to be copied
38
39 try {
40 ConfigurationFacade configurationToCopy = remote.getConfigurationByHierarchyName(config);
41 if (configurationToCopy == null)
42 throw new RuntimeException("Cannot find configuration" + config);
43 } catch (Exception e) {
44 System.out.println("Can't get configuration: " + config + " from url: " + url + "\n" );
45 e.printStackTrace();
46 System.exit(1);
47 }


Here is the error message and stacktrace I see when I run the program:


Can't get configuration: root.appname from url: http://ourhostname.dev.orgname.org:8810 ... ce=hessian

com.caucho.hessian.io.HessianProtocolException: unknown code:C
at com.caucho.hessian.io.HessianInput.error(HessianInput.java:1633)
at com.caucho.hessian.io.HessianInput.readObject(HessianInput.java:1137)
at com.caucho.hessian.io.JavaDeserializer.readMap(JavaDeserializer.java:123)
at com.caucho.hessian.io.JavaDeserializer.readMap(JavaDeserializer.java:105)
at com.caucho.hessian.io.AbstractMapDeserializer.readObject(AbstractMapDeserializer.java:75)
at com.caucho.hessian.io.HessianInput.readObject(HessianInput.java:1038)
at com.caucho.hessian.io.HessianInput.readReply(HessianInput.java:279)
at com.caucho.hessian.client.HessianProxy.invoke(HessianProxy.java:181)
at $Proxy0.getConfigurationByHierarchyName(Unknown Source)
at qbUtils.GetConfigurationId.main(GetConfigurationId.java:40)

Any ideas why this isn't working?

thanks much for your assistance!
  • replies 4
  • views 4579
  • stars 0
qbuser ·
Looking into this a little further, I found the new sample java api programs in our QB4 install. The task I'm currently working on is to automate the cloning of a configuration. I've been able to use the CopyConfiguration.java sample to create a 'one-level' copy of a configuration. The CopyConfiguration.java sample in our QuickBuild 1 install does a recursive copy. Is there no longer a method available for a recursive copy?
robinshen ADMIN ·
This will be provided in next patch release of QB4 which should be available in one or two days.
qbuser ·
That is great news! Thank you!
robinshen ADMIN ·
Please upgrade to QB 4.0.72 and follow "copy configuration" section below to copy existing configuration recursively:
http://wiki.pmease.com/display/QB40/Int ... igurations