Tuesday, September 13, 2011

Exceptions While Using RIDC API @ Webcenter


1) Unable to locate authentication handler for Content Server response: HTTP/1.1 502 Bad Gateway
Source breakpoint occurred at line 54 of MyManagedBean.java.
oracle.stellent.ridc.protocol.ProtocolException: java.io.IOException: Input terminated before being able to read line.
at oracle.stellent.ridc.protocol.ServiceResponse.getResponseAsBinder(ServiceResponse.java:142)
at oracle.stellent.ridc.protocol.ServiceResponse.getResponseAsBinder(ServiceResponse.java:107)
at MyManagedBean.RIDC_CreateFolder(MyManagedBean.java:54)

The code i was using to initialize the connection was:

IdcClientManager manager = new IdcClientManager();
IdcClient idcClient = manager.createClient("http://localhost:4444/idc/idcplg");

The problem resolved by changing the code to:


IdcClientManager manager = new IdcClientManager();
IdcClient idcClient = manager.createClient("idc://localhost:4444");

2) oracle.stellent.ridc.protocol.ServiceException: No service defined for null.
at oracle.stellent.ridc.protocol.ServiceResponse.getResponseAsBinder(ServiceResponse.java:135)
at oracle.stellent.ridc.protocol.ServiceResponse.getResponseAsBinder(ServiceResponse.java:107)
at MyManagedBean.RIDC_CreateFolder(MyManagedBean.java:54)

Reason: Ohhh....Very silly mistake. Following is the code with error:

dataBinder.putLocal("idcService", "COLLECTION_ADD");

Correct Code:

dataBinder.putLocal("IdcService", "COLLECTION_ADD");


3) oracle.stellent.ridc.protocol.ServiceException: Unable to display virtual folder information. Unable to open folder.
at oracle.stellent.ridc.protocol.ServiceResponse.getResponseAsBinder(ServiceResponse.java:135)
at oracle.stellent.ridc.protocol.ServiceResponse.getResponseAsBinder(ServiceResponse.java:107)
at MyManagedBean.getFolderIDFromPath(MyManagedBean.java:165)

Reason: I was specifying only the folder name instead of complete path :)... Ex: RIDCFolder instead of /Contribution Folder/RIDCFolder.... in binder.putLocal ("dCollectionPath", path);


4) This time i was not getting any exception. But there was something wrong. I was trying to upload document, the code was working fine but the document was not uploading. The point to be noted is that there was error in code but i was not getting any exception. Actually, i was not using following code to get the document id of the document i was uploading:

DataBinder serverBinder = res.getResposeAsBinder();
S.O.P(serverBinder.getLocal("dDID"));

I re ran my code with above lines and i got my exception at res.getResposeAsBinder(); So it is important to use above line to ensure that the operation was successful and to save some time.

5) java.lang.RuntimeException: oracle.security.jps.service.idstore.IdentityStoreException: JPS-01520: Cannot initialize identity store.
This exception is is not related to RIDC but i got it suddenly while working. This cause my navigation model to stop working properly. In the logs of UCM managed server i found below exception:


javax.naming.CommunicationException [Root exception is java.net.ConnectException: t3://[2001:0:4137:9e76:2c71:1810:854e:e6a5]:9001: Destination unreachable; nested exception is: 
java.net.ConnectException: Connection refused: connect; No available router to destination]


Not sure, resolved it self in next run.

6) File size is to large and can't be uploaded: When using RIDC the default size of document that can be uploaded is 2 MB. In order to increase this limit, we need to make an entry in web.xml file. Under the Application option in Overview tab, expand Context Initialization Parameter and add following parameter:

Name : org.apache.myfaces.trinidad.UPLOAD_MAX_DISK_SPACE
Value: The maximum file size in bytes

7) Invalid JCR Name or Path: I am still working on this exception.

1 comment:

  1. Hi,

    I get following exception while m trying to upload a document

    oracle.stellent.ridc.protocol.ProtocolException: java.io.IOException: Read error
    at oracle.stellent.ridc.protocol.http.IdcHttpProtocol.sendRequest(IdcHttpProtocol.java:345)
    at oracle.stellent.ridc.protocol.http.auth.FormAuthHandler.sendAuthenticatedRequest(FormAuthHandler.java:134)
    at oracle.stellent.ridc.protocol.http.IdcHttpProtocol.writeRequest(IdcHttpProtocol.java:204)
    at oracle.stellent.ridc.IdcClient.sendRequest(IdcClient.java:181)
    at view.UCM_API.uploadDocument(UCM_API.java:43)
    at view.backing.DocUpload.uploadListener(DocUpload.java:51)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at com.sun.el.parser.AstValue.invoke(Unknown Source)
    at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)
    at org.apache.myfaces.trinidad.component.UIXComponentBase.broadcastToMethodExpression(UIXComponentBase.java:1300)
    at oracle.adf.view.rich.component.UIXDialog.broadcast(UIXDialog.java:97)
    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.broadcastEvents(LifecycleImpl.java:1018)
    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:386)
    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:194)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
    at weblogic.servlet.internal.StubSecurityHelper$ServletSe


    Can u plz tell me the reason ?

    ReplyDelete