cancel
Showing results for 
Search instead for 
Did you mean: 

Problem while configuring cmis_hr ECM adaptor with Alfresco WorkDesk

yogeshpj
Star Contributor
Star Contributor
Hi ALL,

I have set alfresco workdesk with my local alfresco ECM.When I am using CMIS as ECM adaptor (For which i have uncommented the line "<param-value>deploy#WEB-INF/conf/cmis_prof</param-value>" in web.xml) its working fine.Then I have configured it with cmis_hr as ECM adaptor but when I am clicking on "Browse" , I am getting following error.

Any help will be appericated.

2013-07-31 23:34:10,105 [http-apr-9080-exec-6] DEBUG owd.adp.cmis [admin] - OwCMISResourceObjectModel.createType(): Could not initialize a class description! A CMIS error occurred :  Invalid argument! CMIS fault message is : Invalid typeId FSmiley Surprisedwd:dossier
org.oasis_open.docs.ns.cmis.wHi ,

I have set alfresco workdesk with my local alfresco ECM.When I am using CMIS as ECM adaptor (For which i have uncommented the line "<param-value>deploy#WEB-INF/conf/cmis_prof</param-value>" in web.xml) its working fine.Then I have configured it with cmis_hr as ECM adaptor but when I am clicking on "Browse" , I am getting following error.

Any help will be appericated.

2013-07-31 23:34:10,105 [http-apr-9080-exec-6] DEBUG owd.adp.cmis [admin] - OwCMISResourceObjectModel.createType(): Could not initialize a class description! A CMIS error occurred :  Invalid argument! CMIS fault message is : Invalid typeId FSmiley Surprisedwd:dossier
org.oasis_open.docs.ns.cmis.ws._200908.CmisException: Invalid typeId FSmiley Surprisedwd:dossier
   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
   at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
   at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
   at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
   at com.sun.xml.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:141)
   at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:119)
   at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:89)
   at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:130)
   at sun.proxy.$Proxy45.getTypeDefinition(Unknown Source)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISResourceObjectModel.createType(OwCMISResourceObjectModel.java:251)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISResourceObjectModel.getObjectClass(OwCMISResourceObjectModel.java:97)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISResourceObjectModel.getPropertyClass(OwCMISResourceObjectModel.java:208)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISNetwork.getFieldDefinition(OwCMISNetwork.java:1262)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.getFieldDefinitionProviderField(OwStandardSearchTemplate.java:671)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.getPropertyClassInternal(OwStandardSearchTemplate.java:911)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.scanSearchNode(OwStandardSearchTemplate.java:2198)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.scanSearchNode(OwStandardSearchTemplate.java:2133)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.init(OwStandardSearchTemplate.java:1380)
   at com.wewebu.ow.server.plug.owsearch.OwSearchDocument$OwRepositorySearchTemplate.getSearchTemplate(OwSearchDocument.java:82)
   at com.wewebu.ow.server.plug.owsearch.OwSearchDocument.setSearchTemplatName(OwSearchDocument.java:242)
   at com.wewebu.ow.server.plug.owsearch.OwSearchTemplateView.onActivate(OwSearchTemplateView.java:143)
   at com.wewebu.ow.server.ui.OwNavigationView.navigate(OwNavigationView.java:285)
   at com.wewebu.ow.server.ui.OwNavigationView.navigate(OwNavigationView.java:257)
   at com.wewebu.ow.server.plug.owsearch.OwSearchView.init(OwSearchView.java:164)
   at com.wewebu.ow.server.ui.OwEventTarget.attach(OwEventTarget.java:46)
   at com.wewebu.ow.server.ui.OwNavigationView.addView(OwNavigationView.java:90)
   at com.wewebu.ow.server.app.OwMainNavigationView.addPluginView(OwMainNavigationView.java:164)
   at com.wewebu.ow.server.app.OwMainLayout.addMasterPlugins(OwMainLayout.java:132)
   at com.wewebu.ow.server.app.OwMainLayout.init(OwMainLayout.java:197)
   at com.wewebu.ow.server.ui.OwEventTarget.attach(OwEventTarget.java:46)
   at com.wewebu.ow.server.ui.OwWebApplication.handleRequest(OwWebApplication.java:400)
   at org.apache.jsp.default41_jsp._jspService(default41_jsp.java:79)
   at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
   at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
   at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
   at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
   at com.wewebu.ow.server.servlets.OwServletFilter.doFilter(OwServletFilter.java:57)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:225)
   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
   at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
   at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:927)
   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
   at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:999)
   at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:565)
   at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1812)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.js._200908.CmisException: Invalid typeId FSmiley Surprisedwd:dossier
   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
   at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
   at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
   at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
   at com.sun.xml.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:141)
   at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:119)
   at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:89)
   at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:130)
   at sun.proxy.$Proxy45.getTypeDefinition(Unknown Source)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISResourceObjectModel.createType(OwCMISResourceObjectModel.java:251)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISResourceObjectModel.getObjectClass(OwCMISResourceObjectModel.java:97)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISResourceObjectModel.getPropertyClass(OwCMISResourceObjectModel.java:208)
   at com.wewebu.ow.server.ecmimpl.cmis.OwCMISNetwork.getFieldDefinition(OwCMISNetwork.java:1262)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.getFieldDefinitionProviderField(OwStandardSearchTemplate.java:671)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.getPropertyClassInternal(OwStandardSearchTemplate.java:911)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.scanSearchNode(OwStandardSearchTemplate.java:2198)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.scanSearchNode(OwStandardSearchTemplate.java:2133)
   at com.wewebu.ow.server.ecm.OwStandardSearchTemplate.init(OwStandardSearchTemplate.java:1380)
   at com.wewebu.ow.server.plug.owsearch.OwSearchDocument$OwRepositorySearchTemplate.getSearchTemplate(OwSearchDocument.java:82)
   at com.wewebu.ow.server.plug.owsearch.OwSearchDocument.setSearchTemplatName(OwSearchDocument.java:242)
   at com.wewebu.ow.server.plug.owsearch.OwSearchTemplateView.onActivate(OwSearchTemplateView.java:143)
   at com.wewebu.ow.server.ui.OwNavigationView.navigate(OwNavigationView.java:285)
   at com.wewebu.ow.server.ui.OwNavigationView.navigate(OwNavigationView.java:257)
   at com.wewebu.ow.server.plug.owsearch.OwSearchView.init(OwSearchView.java:164)
   at com.wewebu.ow.server.ui.OwEventTarget.attach(OwEventTarget.java:46)
   at com.wewebu.ow.server.ui.OwNavigationView.addView(OwNavigationView.java:90)
   at com.wewebu.ow.server.app.OwMainNavigationView.addPluginView(OwMainNavigationView.java:164)
   at com.wewebu.ow.server.app.OwMainLayout.addMasterPlugins(OwMainLayout.java:132)
   at com.wewebu.ow.server.app.OwMainLayout.init(OwMainLayout.java:197)
   at com.wewebu.ow.server.ui.OwEventTarget.attach(OwEventTarget.java:46)
   at com.wewebu.ow.server.ui.OwWebApplication.handleRequest(OwWebApplication.java:400)
   at org.apache.jsp.default41_jsp._jspService(default41_jsp.java:79)
   at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
   at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
   at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
   at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
   at com.wewebu.ow.server.servlets.OwServletFilter.doFilter(OwServletFilter.java:57)
   at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
   at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
   at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:225)
   at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
   at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
   at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
   at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
   at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:927)
   at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
   at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
   at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:999)
   at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:565)
   at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:1812)
   at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1146)
   at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.j

Thanks,
Yogesh Prajapati
6 REPLIES 6

deko
Star Contributor
Star Contributor
Hello Yogesh,

The configuration set cmis_hr is using a set of preconfigured plugins, that will only work if the corresponding HR data model and the HR sample application was installed.

Please install the hr-installer that can be found in the downloaded Workdesk Community zip file under bin/Human Resource Application.

By the way, are you really using cmis_hr or are you using opencmis_prof and opencmis_hr? As with latest Workdesk 4.1.1.0 the OpenCMIS adapter was released and it is really recommended to go on with this one.

Best regards,
Dennis

yogeshpj
Star Contributor
Star Contributor
Hi Dennis,

Thanks for the reply,Actually I was using alfresco workdesk trial version  and I was tryinng to use cmis_hr.
Let me try with community edition.But still what is the use of cmis_hr in enterprise edition ? How can I use it ?

Thanks,
Yogesh Prajapati

deko
Star Contributor
Star Contributor
Hi Yogesh,

It seems that Workdesk Trial 4.1.1.0 (including OpenCMIS) was not yet published to the web page, but will be published asap. Finalizing Trial package takes more time than Community, as there is extended Trial documentation, which was not yet finalized for 4.1.1.0 and which must be included in the Trial zip file.

So you have Workdesk 4.1.0.0 (including old CMIS adapter) and this should also work fine. You could download Workdesk Community zip file and just run the hr-installer from that file. Then you can go back to Workdesk Trial and can use cmis_hr configuration set without any error messages. I am not sure now, but I think the hr-installer is also included in the Trial package, at least I am sure that it is included for Workdesk Trial 4.1.1.0. 

Regards,
Dennis

deko
Star Contributor
Star Contributor
I was just told that the current Workdesk Trial download already points to version 4.1.1.0. When did you download yours?

yogeshpj
Star Contributor
Star Contributor
Hi Dennis,

I run the installer for local alfresco and it is working fine in trial version.I am able to see sample HR application successfully in alfresco workdesk.But I am not able to configure security roles in sample application.How can I configure different permissions to different users ?

Thanks,
Yogesh Prajapati

deko
Star Contributor
Star Contributor
Hi Yogesh,

The feature you want to use is called DB Role Manager (see also the corresponding sections in Installation guide and Configuration guide).

To use this feature you should stop Tomcat and follow these steps:

1) DB Role Manager works only with Workdesk Enterprise and is not working with Workdesk Community. As you are using trial (which is in fact a 30 day trial Workdesk Enterprise) you should be fine here.

2) You must have a database prepared with the OW_ROLE table. Scripts to create this Workdesk table for different databases can be found in the downloaded trial zip file in the db folder.

3) In owbootstrap.xml of your used configuration set (currently cmis_hr?, use opencmis_hr of Workdesk 4.1.1.0 please) you must have configured a datasource to connect Workdesk against your DB. There are already commented examples there.

Example:


<DefaultDataSource>
        <JNDIName>java:/PostgreSQLDS</JNDIName>
</DefaultDataSource>


Additionally, the datasource must be configured for the Workdesk application in general. If you are using Tomcat, the file to do this is located here:
TOMCAT_ROOT/webapps/workdesk/META-INF/context.xml

Example datasource in context.xml:

    <Resource name="java:/PostgreSQLDS"
       auth="Container"
        type="javax.sql.DataSource"
        factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory" 
        driverClassName="org.postgresql.Driver"
        url="jdbc:postgresql://localhost:5432/owd"
        username="your-user"
        password="your-password"
        removeAbandoned="true"
        maxActive="30"
        maxIdle="10"
   maxWait="1000"
   removeAbandonedTimeout="60"
        logAbandoned="true"/>


4) You must have the JDBC driver for your database provided for the Workdesk application.
Example: If you are using Tomcat server and PostgreSQL, you should copy the corresponding JDBC driver postgresql-9.1-902.jdbc4.jar to TOMCAT_ROOT/lib

5) You must configure the authentication mode in owbootstrap.xml, so that Workdesk is able to pull user and group information from somewhere. With Workdesk 4.1.0.0 you MUST use an LDAP/Active Directory system. With Workdesk 4.1.1.0 (really recommended that you use this version), the possibility was introduced to work directly on Alfresco groups. There are commented examples also here. Recommended is the following:


  <Authentication mode="ALFRESCO">
    <BaseURL>http://localhost:8080/alfresco</BaseURL>
  </Authentication>


Be aware that there is already a authentication node, which might be configured with NONE. Comment this one.

6)  You must configure the DB Role Manager in owbootstrap.xml. There should also be examples commented. Example:


   <RoleManager>

      <ClassName>com.wewebu.ow.server.roleimpl.dbrole.OwDBRoleManager</ClassName>
      
      <Version>4.1.1</Version>

      <DbTableName>OW_ROLE</DbTableName>

      <DesignName>default41</DesignName>
      
        <AvailableDesigns>
            <Design displayName="Alfresco Workdesk 4.1 Design">default41</Design>
        </AvailableDesigns>

        <SchemeVersion>3</SchemeVersion>
      
      <SecurityAdmin pluginid="com.wewebu.ow.Admin">
             <User>Administrator</User>
             <User>admin</User>
      </SecurityAdmin>

      <MasterRoles enable="false">
         
         <MasterRoleGroup name="???" memberOfAll="true">
            <Role>???</Role>
            <Role>???</Role>
         </MasterRoleGroup>

      </MasterRoles>
      
      <ConfigCategories>ROLE_CATEGORY_PLUGIN,
                        ROLE_CATEGORY_SEARCH_TEMPLATE,
                        ROLE_CATEGORY_STANDARD_FUNCTION
      </ConfigCategories>
      
   </RoleManager>


- Be aware that there must be already a <RoleManager> node configured using the so called Simple Role Manager. You must deactivate that one by commenting it out!
- In node SecurityAdmin you must configure your admin user, which will be able to configure permissions in Workdesk then
- In ConfigCategories you must configure, what can be configured for users. Please see also owbootstrap.xml inline documentation.

7) To configure permissions with DB Role Manager in Workdesk, you need to have the so called Administration master plugin in owplugins.xml. You should use Workdesk Configurator to add this plugin, if it is not already there. When looking into owplugins.xml with an editor, there should be a node like the following:

 
  <PlugIn type="ow_master">
    <Name>Administration</Name>
    <id>com.wewebu.ow.Admin</id>
    <Description>Administrative tools</Description>
    <Vendor>Alfresco Business Solutions</Vendor>
    <Version>4.1.1</Version>
    <ClassName>com.wewebu.ow.server.plug.owconfig.OwConfigurationDocument</ClassName>
    <ViewClassName>com.wewebu.ow.server.plug.owconfig.OwConfigurationView</ViewClassName>
    <helppath>owconfig/default.jsp</helppath>
    <RoleView enable="true" />
  </PlugIn>


😎 Restart Tomcat, login with admin user, and go to Administration master plugin tab. There you can find the DB Role Manager. Select an user/group, and configure the permissions depending on your ConfigCategories.
Take care when using the ConfigCategory ROLE_CATEGORY_PLUGIN, you must enable at least the ow_app plugin (id com.wewebu.ow.Workdesk) for any user.


If you have further questions, please have a look into the documentation (PDFs, Configurator help, inline documentation), as almost everything is listed there.

Best Regards,
Dennis