3

In a fresh installed Tridion site (2013 SP1) on access it gives following error:

Stacktrace:

java.lang.NoClassDefFoundError: Could not initialize class com.tridion.storage.StorageManagerFactory at com.tridion.webservices.claimprocessor.WritableODataClaimProcessor.checkSessionWrapperAvailability(WritableODataClaimProcessor.java:155) at com.tridion.webservices.claimprocessor.WritableODataClaimProcessor.guaranteeInitialized(WritableODataClaimProcessor.java:141) at com.tridion.webservices.claimprocessor.WritableODataClaimProcessor.onRequestStart(WritableODataClaimProcessor.java:55) at com.tridion.ambientdata.Engine.onRequestStart(Engine.java:147)
at Codemesh.JuggerNET.JavaClass.ThrowException(Exception ex) at Codemesh.JuggerNET.NTypeValue.Throw(Int64 inst) at Codemesh.JuggerNET.JavaClass.ThrowTypedException(Int64 inst) at Codemesh.JuggerNET.JavaMethod.CallVoid(JavaProxy jpo, JavaMethodArguments args) at Com.Tridion.Ambientdata.Engine.OnRequestStart(ClaimStore claimStore)
at Tridion.ContentDelivery.AmbientData.Runtime.AmbientRuntime.OnRequestStart(HttpApplication application, HttpContext context, ClaimStore claimStore, Set templateReadOnlyClaims, Set templateImmutableClaims, Set templateSessionScopeClaims)

Please find the snippet from the storage.config below:

        <Bundle src="preview_dao_bundle.xml"/>
            <!-- <Bundle src="TrackingRequestDAOBundle.xml"/> -->
        </StorageBindings>

  <Wrappers>
    <Wrapper Name="SessionWrapper">

      <Storage Id="sessionDB" Class="com.tridion.storage.persistence.JPADAOFactory" Type="persistence" dialect="MSSQL">
        <Pool Type="jdbc" Size="5" MonitorInterval="60" IdleTimeout="120" CheckoutTimeout="120" />
        <DataSource Class="com.microsoft.sqlserver.jdbc.SQLServerDataSource">
          <Property Name="serverName" Value="127.0.0.1"/>
          <Property Name="portNumber" Value="1433" />
          <Property Name="databaseName" Value="Tridion_Session_Preview" />
          <Property Name="user" Value="TridionBrokerUserStage"/>
                  <Property Name="password" Value="Pass@123"/>
        </DataSource>
      </Storage>
    </Wrapper>
  </Wrappers>   
             <Storage Type="persistence" Id="defaultdb" dialect="MSSQL" Class="com.tridion.storage.persistence.JPADAOFactory"> 
                <Pool Type="jdbc" Size="10" MonitorInterval="60" IdleTimeout="120" CheckoutTimeout="120"/>
                <DataSource Class="com.microsoft.sqlserver.jdbc.SQLServerDataSource">
                  <Property Name="serverName" Value="127.0.0.1"/>
                  <Property Name="portNumber" Value="1433"/>
                  <Property Name="databaseName" Value="Tridion_Broker"/>
                  <Property Name="user" Value="TridionBrokerUser"/>
                  <Property Name="password" Value="Pass@123"/>
                </DataSource>
              </Storage>

Thanks in advance.

4 Answers 4

3

java.lang.NoClassDefFoundError

This would seem to indicate that Java cannot find a required class. Have you checked that you have all of the Tridion Content Delivery JARs and their dependencies in your lib folder.

I'd also check your Content Delivery licence file and its location.

if you're using the DXA, review the steps in the documentation titled, "Creating the Web application".

3

Storage factory initialization fails mainly due to following errors

  • No JDBC/database drivers JAR installed (sqljdbc4.jar)

  • Format of cd_storage is not proper

1

I got above error when I was installing CD_preview_webservices. My issue was resolved after I corrected cd_ambient_conf.xml so try to add correct publication ID and the IP and port number. Also as RAJ KUMAR mentiond (sqljdbc4.jar) is also an important. cd_storage I copied from other working application so I was sure that It was correct.

0

The checkSessionWrapperAvailabilty method is inside of the cd_preview_ambient.jar.

You might want to check that you have that jar file (and the other necessary jar files) in your lib folder (or available to the application).

There is a nice 'Jar file reference' page in the SDL Tridion online documentation here.

You may also want to confirm that your other config files are correct - in particular the cd_ambient_conf.xml. Nuno's Kickstart project is invaluable for this type of checking: https://github.com/NunoLinhares/kickstart-tridion-environment/tree/master/CreateAnEnvironmentForMe/CreateAnEnvironmentForMe/ConfigSamples/preview-web

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.