gpt4 book ai didi

java - 使用简单的 Java 类连接(登录)到 Alfresco

转载 作者:行者123 更新时间:2023-11-28 22:37:43 24 4
gpt4 key购买 nike

我试图登录部署在 localhost:80/alfresco 的 alfresco

这是我到目前为止所做的:

 public static void main(String[] args) throws Exception {

WebServiceFactory.setEndpointAddress("http://localhost:80/alfresco/api/");

// Start the session
AuthenticationUtils.startSession(USERNAME, PASSWORD);

try {

//Work to do if the login works :S

} finally {
// End the session
AuthenticationUtils.endSession();
}
}

这是我上课时得到的:

WARNING: Unable to find required classes (javax.activation.DataHandler and   javax.mail.internet.MimeMultipart). Attachment support is disabled.
Exception in thread "main" org.alfresco.webservice.util.WebServiceException: Error starting session.
at org.alfresco.webservice.util.AuthenticationUtils.startSession(AuthenticationUtils.java:94)
at com.delta.logic.connect.Query1.main(Query1.java:53)
Caused by: (404)Introuvable
at org.apache.axis.transport.http.HTTPSender.readFromSocket(HTTPSender.java:744)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:144)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at org.alfresco.webservice.authentication.AuthenticationServiceSoapBindingStub.startSession(AuthenticationServiceSoapBindingStub.java:187)
at org.alfresco.webservice.util.AuthenticationUtils.startSession(AuthenticationUtils.java:79)
... 1 more

我真的卡在这里了,救命!

最佳答案

来自 Alfresco Content Management Web Services

Please also note that the endpoint for soap web services was moved for alfresco 4.2.d. To make way for the public api now instead of being http://localhost:8080/alfresco/api the soap services resides at http://localhost:8080/alfresco/soapapi

关于java - 使用简单的 Java 类连接(登录)到 Alfresco,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22452796/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com