We hope you'll join us for our 4/23 webinar on using data tables to apply reference ranges and AE codes in OC4. For more information and to register, visit https://register.gotowebinar.com/register/2882170018956684555

Problems installing WEB services in OC 3.5 & 2.6

kristiakkristiak Posts: 1,326 ✭✭✭
I have a problem installing WEB services. The same problem in 3.5 and 3.6. I have attached a log file where it indicates a problem. I have followed the instructions to the letter. I copied the WS WAR file to Tomcat WEBAPS. This resulted in that I can no longer access the Tomcat manager and I cannot close down Tomcat either. Strangely enough the main OC application works normally it seems. I have attached the log file for localhost where there seemed to problems.
«13

Comments

  • kkrumliankkrumlian Posts: 25
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in URL [jar:file:/C:/OC/Tomcat/webapps/OpenClinica-ws/WEB-INF/lib/OpenClinica-core-3.5.jar!/org/akaza/openclinica/applicationContext-core-db.xml]: Invocation of init method failed; nested exception is liquibase.exception.JDBCException: org.apache.commons.dbcp.SQLNestedException: Cannot create PoolableConnectionFactory (FATAL: database "openclinica-ws" does not exist)


    Based on this line it is looking for a DB with the name of openclinica-ws and it is not finding it. Do you have this DB? is your datainfo.properties configured correctly?

    Krikor
  • kristiakkristiak Posts: 1,326 ✭✭✭
    Hi,
    Since I did not change anything in the "main" datainfo.properties, I did not change anything in datainfo.properties for WS either. I have looked through all the entries and I do not see were to modify it. I have not worked with WS since 3.1 and at that time it worked right out of the box without making any changes.
    I'm at loss what to do?
    Best

    Krister
  • lindsay.stevenslindsay.stevens Posts: 404 ✭✭✭
    via Email
    In 3.3 or so the datainfo now goes in Catalina home. There should be a
    couple of folders there after you deploy the apps first time, named like
    openclinica.config, and another for web services. Edit those datainfo
    files, not the ones you used to edit in webinf/classes.

    For webservices, you need to at least edit the db name in datainfo, since
    the default datainfo substitutes the app context name for the database
    name. There won't be a database called OpenClinica-ws, so you must specify
    just OpenClinica for the db name.
  • kristiakkristiak Posts: 1,326 ✭✭✭
    I found a folder called openclinica.ws-config and in this folder I found datainfo.properties. Is this the file where I should change the following section as specified on line 4??
    ############
    dbType=postgres
    dbUser=clinica
    dbPass=clinica
    db=OpenClinica-ws
    dbPort=5432
    dbHost=localhost
  • lindsay.stevenslindsay.stevens Posts: 404 ✭✭✭
    via Email
    Yes that's it. Details should match your main OpenClinica db.
  • kristiakkristiak Posts: 1,326 ✭✭✭
    except for the -WS I assume! To to confirm. do not follow the manual!! I have the feeling that the OC manual is a little out of date as well as some of the install files e.g in the configuration section still refers to Utah 3.1.2.!!
  • kristiakkristiak Posts: 1,326 ✭✭✭
    Hi Lindsay, there must be something that I do wrong. One positive sign is that I can now get into Tomcat Manager. WS is there but it is not running. When I try to start it an error message displays "FAIL - Application at context path OpenClinica-WS could not be started. Could it have anything to do with the fact that te databas contains some data already?
  • kristiakkristiak Posts: 1,326 ✭✭✭
    Is the following correct?
    In the following file:make the changes as listed below:
    C:\oc\tomcat\openclininca-ws.config\datainfo.properties
    1) Change line 17 to read db=openclinica-ws
    2) Change line 112 to read sysURL=http://localhost:8080/OpenClinica-ws/MainMenu
    No changes need to made in C:\oc\tomcat\webapps\openclinica-ws\web-inf\classes\datainfo.properties
  • lindsay.stevenslindsay.stevens Posts: 404 ✭✭✭
    via Email
    For the database settings it should just be a matter of changing the
    openclinica-ws.config/datainfo database name to openclinica (or whatever
    you called it).

    The idea is that webservices needs access to the same data as the main web
    app.

    The unique things that webservices gets is a different URL, logging
    directory, and data directory. Otherwise the settings are the same as the
    main web app.
  • kristiakkristiak Posts: 1,326 ✭✭✭
    Now I'm not sure I understand you. Are you saying that the settings I suggested are wrong? Should I remove the -ws that I added.??? I'm really confused! You have to remember that I'm not an IT expert, purely a Clinical Pharmacologist :)
This discussion has been closed.