Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Hibernate configuration file
    • Location: $JETTY_BASE/resources/joc/hibernate.cfg.xml
    • The hibernate configuration should look like this:

      Code Block
      titleHibernate configuration file for Oracle® database
      <?xml version="1.0" encoding="UTF-8" standalone="no"?>
      <hibernate-configuration>
       <session-factory>
        <property name="hibernate.connection.driver_class">oracle.jdbc.OracleDriver</property>
        <property name="hibernate.connection.password"></property>
        <property name="hibernate.connection.url">jdbc:oracle:thin:@//oraclesrv:1521/xe</property>
        <property name="hibernate.connection.username"></property>
        <property name="hibernate.dialect">org.hibernate.dialect.Oracle12cDialect</property>
        <property name="hibernate.show_sql">false</property>
        <property name="hibernate.connection.autocommit">false</property>
        <property name="hibernate.format_sql">true</property>
        <property name="hibernate.temp.use_jdbc_metadata_defaults">false</property>
        <property name="hibernate.connection.provider_class">org.hibernate.hikaricp.internal.HikariCPConnectionProvider</property>
        <property name="hibernate.hikari.maximumPoolSize">10</property>
       </session-factory>
      </hibernate-configuration>
    • Consider the empty elements that are used for the account and password. Do not delete the respective elements from the hibernate configuration file.
    • The example makes use of the Oracle® database listener running for hostname oraclesrv and port 1521. The database Service Name is xe.
    • Should you want to use a Service ID instead of a Service Name, then use this URL syntax: jdbc:oracle:thin:@oraclesrv:1521:xe
    • Should you want to directly specify additional settings as typically used from tnsnames.ora, then use this URL syntax: jdbc:oracle:thin:@(DESCRIPTION =(ADDRESS_LIST =(ADDRESS =(PROTOCOL=TCP)(HOST=oraclesrv)(PORT=1521)))(CONNECT_DATA=(SID=XE)(GLOBAL_NAME=XE.WORLD)(SERVER=DEDICATED))). 
  • Configure the location of the Oracle Wallet® by use of a Java define like this: 
    -Doracle.net.wallet_location=/home/js7/wallet. This setting should point to the directory where the wallet files of the JOC Cockpit run-time account are stored. As the database configuration for JS7 is added to the JOC Cockpit so the setting for the Oracle wallet is to be added in the JOC:
    • specify the Java define with the jettyOptions the setting of the installer response file joc_install_xml like this:
      <entry key="jettyOptions" value="-Doracle.net.wallet_location=/home/js7/wallet"/>
    • alternatively specify the JAVA_OPTIONS environment variable before running the JOC Cockpit jetty.sh start script.
    • alternatively, for Unix, create/modify and make executable the /etc/default/joc file to include the JAVA_OPTIONS environment variable like this:
      export JAVA_OPTIONS="-Doracle.net.wallet_location=/home/js7/wallet"

    • alternatively, for Unix, add the JAVA_OPTIONS environment variable to the systemd service file, see JS7 - systemd Service Files for automated Startup / Shutdown with Unix Systems

...