cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Need to share some code when posting a question or reply? Make sure to use the "Insert code sample" menu option. Learn more! X

AuthenticationException - Please Help

rosemina
3-Newcomer

AuthenticationException - Please Help

I'm trying to run the following code

public class QueryGroup {
  public static void main(String args[]) throws WTException {
    QuerySpec qs = new QuerySpec(WTGroup.class);
    SearchCondition sc1 = new SearchCondition(WTGroup.class, WTGroup.INTERNAL, SearchCondition.IS_FALSE);
    qs.appendWhere(sc1);
    QueryResult qr = PersistenceHelper.manager.find((StatementSpec) qs);
  }
}

and getting the following error. Please help.

D:\ptc\Windchill>windchill sh.QueryGroup
Exception in thread "main" (wt.fc.fcResource/0) wt.util.WTException: The operation:   "find" failed.
Nested exception is: wt.util.WTRemoteException: Unable to invoke remote method;
nested exception is:
        wt.method.AuthenticationException
        at wt.method.RemoteMethodServer.invoke(RemoteMethodServer.java:810)
        at wt.services.ServiceFactory$ClientInvocationHandler.invoke(ServiceFactory.java:349)
        at com.sun.proxy.$Proxy1.find(Unknown Source)
        at sh.QueryGroup.main(QueryGroup.java:18)
1 REPLY 1
James62
12-Amethyst
(To:rosemina)

Try running the code directly on a method server. The link bellow has all the details for RMI setup.

 

https://www.ptc.com/en/support/article?n=CS254321

Announcements


Top Tags