Skip to main content
May 24, 2022 6:03 AM UTC
Question

RemoteMethodServer.invoke() called on default method server from within method server

Error message "RemoteMethodServer.invoke() called on default method server from within method server! Bad loopback code!" is displayed in MethodServer.log during part creation.

Need a suggestion, to fix this Error message.
I've attached the code snippet below for the reference, so pelase check it.

 

Code Snippet:

java.util.Iterator<CustomClassificationBean> iterator = getBean.iterator();
while(iterator.hasNext()){
CustomClassificationBean partBean = (CustomClassificationBean)iterator.next();
userName = partBean.getUserName();

}catch(Exception e){
e.printStackTrace();
}

RemoteMethodServer remoteMethodServer = null;
GatewayAuthenticator auth = null;
Class[] argTypes = new Class[]{java.util.Vector.class};
Object[] argList = new Object[]{getBean};

auth= new GatewayAuthenticator();
remoteMethodServer = RemoteMethodServer.getDefault();
auth.setRemoteUser(userName);
remoteMethodServer.setAuthenticator(auth);
remoteMethodServer.setUserName(userName);
responseData =(String) remoteMethodServer.invoke("createPart", "com.test.customService", null, argTypes, argList);

2 replies

May 24, 2022 11:50 AM UTC

 Hi,

 

Read the following article - "Error message "RemoteMethodServer.invoke() called on default method server from within method server! Bad loopback code!" is displayed in MethodServer.log during Upgrade process : Windchill PDMLink 10.1": https://www.ptc.com/en/support/article/CS184974

May 24, 2022 12:05 PM UTC

Thanks for your suggestion.

I've already reviewed this article, but i didn't get more information.

is there any way to avoid this issue in the custom code ?

kindly share your suggestion.