title: java.lang.NoClassDefFoundError: com/mongodb/ServerAddress
body: <p>i have an jee6 application with eclipselink and mongodb.
  i use the nosql-extension org.eclipse.persistence.nosql</p>
  
  <p>when i deploy my application on a local glassfish instance everything works fine.</p>
  
  <p>when i deply the application on remote glassfish i get the error below</p>
  
  <p>glassfish version are the same on both locations
  the mongodb driver jar is in WEB-INF/lib</p>
  
  <p>but on the remote-server i get an <code>"java.lang.NoClassDefFoundError: com/mongodb/ServerAddress"</code></p>
  
  <p>where is the problem ???</p>
  
  <pre><code>[#|2012-12-03T19:19:36.281+0000|CONFIG|glassfish3.1.2|org.eclipse.persistence.session.file:/usr/glassfish3/glassfish3/glassfish/domains/domain1/applications/ForecastWebApp-0.0.1-SNAPSHOT/WEB-INF/classes/_forecastMongoDB.connection|_ThreadID=1306;_ThreadName=Thread-2;|connecting(EISLogin(
          platform=&gt; MongoPlatform
          user name=&gt; ""
          MongoConnectionSpec()
  ))|#]
  
  [#|2012-12-03T19:19:36.288+0000|SEVERE|glassfish3.1.2|org.eclipse.persistence.session.file:/usr/glassfish3/glassfish3/glassfish/domains/domain1/applications/ForecastWebApp-0.0.1-SNAPSHOT/WEB-INF/classes/_forecastMongoDB.ejb|_ThreadID=1306;_ThreadName=Thread-2;|java.lang.NoClassDefFoundError: com/mongodb/ServerAddress
          at org.eclipse.persistence.internal.nosql.adapters.mongo.MongoConnectionFactory.getConnection(MongoConnectionFactory.java:74)
          at org.eclipse.persistence.eis.EISConnectionSpec.connectToDataSource(EISConnectionSpec.java:150)
          at org.eclipse.persistence.nosql.adapters.mongo.MongoConnectionSpec.connectToDataSource(MongoConnectionSpec.java:150)
          at org.eclipse.persistence.eis.EISLogin.connectToDatasource(EISLogin.java:73)
          at org.eclipse.persistence.internal.databaseaccess.DatasourceAccessor.connectInternal(DatasourceAccessor.java:330)
          at org.eclipse.persistence.internal.databaseaccess.DatasourceAccessor.connect(DatasourceAccessor.java:418)
          at org.eclipse.persistence.sessions.server.ConnectionPool.buildConnection(ConnectionPool.java:216)
          at org.eclipse.persistence.sessions.server.ConnectionPool.startUp(ConnectionPool.java:504)
          at org.eclipse.persistence.sessions.server.ServerSession.connect(ServerSession.java:484)
          at org.eclipse.persistence.internal.sessions.DatabaseSessionImpl.login(DatabaseSessionImpl.java:734)
          at org.eclipse.persistence.internal.jpa.EntityManagerFactoryProvider.login(EntityManagerFactoryProvider.java:217)
          at org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.deploy(EntityManagerSetupImpl.java:542)
          at org.eclipse.persistence.internal.jpa.EntityManagerFactoryDelegate.getDatabaseSession(EntityManagerFactoryDelegate.java:186)
          at org.eclipse.persistence.internal.jpa.EntityManagerFactoryDelegate.createEntityManagerImpl(EntityManagerFactoryDelegate.java:278)
          at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManagerImpl(EntityManagerFactoryImpl.java:304)
          at org.eclipse.persistence.internal.jpa.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:282)
          at org.glassfish.persistence.jpa.PersistenceUnitLoader.loadPU(PersistenceUnitLoader.java:211)
          at org.glassfish.persistence.jpa.PersistenceUnitLoader.&lt;init&gt;(PersistenceUnitLoader.java:120)
  </code></pre>