com.tc.exception.TCClassNotFoundException

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

This might be an issue with the file location in the Spark submit command. Try it with "spark-submit --master spark://master:7077 hello_world_from_pyspark.py {file location}"

tip

Check if you've set a name in Application -> Run. If you didn't, the generated XML is gonna have missing information and then this exception will be thrown.

tip

You might've forgot to add a dependency or it's written wrong. Also, you might be using incompatible versions of Java and Hibernate. More on this here: https://goo.gl/SjSlRA

tip

If you're using Hibernate, this indicates you're missing FasterXML Classmate dependency, which you can add to your dependencies. To add it, the groupId is com.fasterxml and artifactId is Classmate.

tip

Check if you didn't forget to instantiate your topic in the kafka broker.

tip

NoClassDefFoundError means java has failed to find a class you're trying to instantiate, look if you've added the class you're trying to instantiate to the dependencies.

tip

This error means there's a class missing in your classpath during runtime. You need to create a jar with all your dependencies and have it in your classpath. Check Maven Assembly Plugin and how to add your dependencies to a jar: https://goo.gl/U2zr8k

tip

jsp-api and servlet-api jars must NOT be deployed by your web app. They should be marked as provided but not deployed by your app.

tip

You need to add httpcore to your dependencies. Try adding version 4.3 or further.

tip

The server rejects all jars that already belong to the server runtime (such as tomcat-**.jar, servlet**.jar). Consider substituting the CORS filter you're using for this one: https://goo.gl/ctQ7Fs

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Tomcat and TCClassNotFoundException
    via by dimensional,
  • How to run a jar file in hadoop?
    via Stack Overflow by Arihant
    ,
  • module base url problems
    via by andy,
  • module base url problems
    via by andy,
  • I've pointed pom.xml to the preinstalled V3 b74b. I've configured appserver with mysql and created correspondent resources in appserver. In pom.xml was useed dbVendorName=mssql and createTables=true. I've tried to deploy cmpcustomer sample. But I saw SQL exceptions during the deployment: java.lang.ClassNotFoundException: com.mysql.jdbc.jdbc2.optional.MysqlDataSource See all messages bellow. To reproduce the issue. 1) Install appserver, create S1AS_HOME 2) cvs co appserver-sqe/bootstrap.xml, create SPS_HOME 3) ant -f bootstrap.xml co-ejb 4) cd to appserver-sqe/pe/ejb/ejb30/persistence/datatypes 5) ant mysql-setup (it will setup appserver with mysql) 6) In buildJava2DB.xml replace resources names with your names. For cmpcusomer.ear: cmpcustomer-pool/jdbc/cmpcustomer. I've attached buildJava2DB.xml with these names. 7) ant -f buildJava2DB.xml setup (it will create jdbc resources in appserver) 8) execute through maven cmpcustomer.ear deployment with dbVendorName=mssql and createTables=true, pointing to preinstalled appserver. I've attached an archive INFO: Instantiated an instance of org.hibernate.validator.engine.resolver.JPATraversableResolver. Dec 16, 2009 1:59:13 PM com.sun.gjc.common.DataSourceObjectBuilder getDataSourceObject SEVERE: jdbc.exc_cnfe_ds java.lang.ClassNotFoundException: com.mysql.jdbc.jdbc2.optional.MysqlDataSource at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:303) at java.lang.ClassLoader.loadClass(ClassLoader.java:248) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:316) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:247) at com.sun.gjc.common.DataSourceObjectBuilder.getDataSourceObject(DataSourceObjectBuilder.java:279) at com.sun.gjc.common.DataSourceObjectBuilder.constructDataSourceObject(DataSourceObjectBuilder.java:108) at com.sun.gjc.spi.ManagedConnectionFactory.getDataSource(ManagedConnectionFactory.java:1167) at com.sun.gjc.spi.DSManagedConnectionFactory.getDataSource(DSManagedConnectionFactory.java:135) at com.sun.gjc.spi.DSManagedConnectionFactory.createManagedConnection(DSManagedConnectionFactory.java:90) at com.sun.enterprise.resource.allocator.LocalTxConnectorAllocator.createResource(LocalTxConnectorAllocator.java:72) at com.sun.enterprise.resource.pool.ConnectionPool.createSingleResource(ConnectionPool.java:834) at com.sun.enterprise.resource.pool.ConnectionPool.createResource(ConnectionPool.java:1087) at com.sun.enterprise.resource.pool.datastructure.ListDataStructure.addResource(ListDataStructure.java:121) at com.sun.enterprise.resource.pool.ConnectionPool.addResource(ConnectionPool.java:268) at com.sun.enterprise.resource.pool.ConnectionPool.createResourceAndAddToPool(ConnectionPool.java:1381) at com.sun.enterprise.resource.pool.ConnectionPool.createResources(ConnectionPool.java:862) at com.sun.enterprise.resource.pool.ConnectionPool.initPool(ConnectionPool.java:220) at com.sun.enterprise.resource.pool.ConnectionPool.internalGetResource(ConnectionPool.java:446) at com.sun.enterprise.resource.pool.ConnectionPool.getResource(ConnectionPool.java:360) at com.sun.enterprise.resource.pool.PoolManagerImpl.getResourceFromPool(PoolManagerImpl.java:227) at com.sun.enterprise.resource.pool.PoolManagerImpl.getResource(PoolManagerImpl.java:151) at com.sun.enterprise.connectors.ConnectionManagerImpl.getResource(ConnectionManagerImpl.java:321) at com.sun.enterprise.connectors.ConnectionManagerImpl.internalGetConnection(ConnectionManagerImpl.java:280) at com.sun.enterprise.connectors.ConnectionManagerImpl.allocateConnection(ConnectionManagerImpl.java:172) at com.sun.enterprise.connectors.ConnectionManagerImpl.allocateConnection(ConnectionManagerImpl.java:149) at com.sun.enterprise.connectors.ConnectionManagerImpl.allocateConnection(ConnectionManagerImpl.java:144) at com.sun.gjc.spi.base.DataSource.getConnection(DataSource.java:105) at org.glassfish.persistence.common.Java2DBProcessorHelper.getConnection(Java2DBProcessorHelper.java:636) at org.glassfish.persistence.common.Java2DBProcessorHelper.executeDDLStatement(Java2DBProcessorHelper.java:572) at org.glassfish.persistence.common.Java2DBProcessorHelper.createOrDropTablesInDB(Java2DBProcessorHelper.java:267) at com.sun.jdo.spi.persistence.support.ejb.ejbc.CMPProcessor.process(CMPProcessor.java:128) at com.sun.jdo.spi.persistence.support.ejb.codegen.CMPDeployerImpl.deploy(CMPDeployerImpl.java:225) at org.glassfish.ejb.startup.EjbDeployer.generateArtifacts(EjbDeployer.java:321) at org.glassfish.javaee.core.deployment.JavaEEDeployer.prepare(JavaEEDeployer.java:209) at com.sun.enterprise.v3.server.ApplicationLifecycle.prepareModule(ApplicationLifecycle.java:644) at org.glassfish.javaee.full.deployment.EarDeployer.prepareBundle(EarDeployer.java:269) at org.glassfish.javaee.full.deployment.EarDeployer.access$200(EarDeployer.java:79) at org.glassfish.javaee.full.deployment.EarDeployer$1.doBundle(EarDeployer.java:131) at org.glassfish.javaee.full.deployment.EarDeployer$1.doBundle(EarDeployer.java:129) at org.glassfish.javaee.full.deployment.EarDeployer.doOnBundles(EarDeployer.java:197) at org.glassfish.javaee.full.deployment.EarDeployer.doOnAllTypedBundles(EarDeployer.java:206) at org.glassfish.javaee.full.deployment.EarDeployer.doOnAllBundles(EarDeployer.java:232) at org.glassfish.javaee.full.deployment.EarDeployer.prepare(EarDeployer.java:129) at com.sun.enterprise.v3.server.ApplicationLifecycle.prepareModule(ApplicationLifecycle.java:644) at com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:296) at org.glassfish.kernel.embedded.EmbeddedDeployerImpl.deploy(EmbeddedDeployerImpl.java:214) at org.glassfish.kernel.embedded.EmbeddedDeployerImpl.deploy(EmbeddedDeployerImpl.java:144) at org.glassfish.maven.DeployMojo.execute(DeployMojo.java:75) at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:453) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:500) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:479) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:331) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:292) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:142) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:336) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:129) at org.apache.maven.cli.MavenCli.main(MavenCli.java:301) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315) at org.codehaus.classworlds.Launcher.launch(Launcher.java:255) at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430) at org.codehaus.classworlds.Launcher.main(Launcher.java:375) Dec 16, 2009 1:59:13 PM com.sun.enterprise.resource.allocator.LocalTxConnectorAllocator createResource WARNING: poolmgr.create_resource_error Dec 16, 2009 1:59:13 PM com.sun.enterprise.connectors.ConnectionManagerImpl internalGetConnection WARNING: poolmgr.get_connection_failure Dec 16, 2009 1:59:13 PM com.sun.gjc.spi.base.DataSource getConnection WARNING: jdbc.exc_get_conn Dec 16, 2009 1:59:13 PM org.glassfish.persistence.common.Java2DBProcessorHelper logI18NWarnMessage WARNING: Cannot connect to database via JNDI name 'jdbc/cmpcustomer': java.sql.SQLException: Error in allocating a connection. Cause: Class name is wrong or classpath is not set for : com.mysql.jdbc.jdbc2.optional.MysqlDataSource.
    via by easarina,
  • 1. Downloaded build 35 from http://dlc.sun.com.edgesuite.net/glassfish/3.1/promoted/glassfish-3.1-b35.zip 2. Unzipped and installed it. 3. Ran the following shell script: # Start the server $GLASSFISH_HOME/bin/asadmin start-domain # Copy MySQL drivers to extension directory for domain1 cp -f $CONNECTOR_J_HOME/*.jar $GLASSFISH_HOME/glassfish/domains/domain1/lib/ext # Create JDBC connection pool $GLASSFISH_HOME/bin/asadmin create-jdbc-connection-pool --datasourceclassname=com.mysql.jdbc.jdbc2.optional.MysqlDataSource --restype=javax.sql.DataSource --description "A JDBC connection pool providing access to the LEAD database." --property User=lead:Password=lead:DatabaseName=LEAD:Port=3306:ServerName=localhost "LEADConnectionPool" # Create the corresponding JDBC resource $GLASSFISH_HOME/bin/asadmin create-jdbc-resource --connectionpoolid "LEADConnectionPool" --description "A JDBC resource providing access to the LEAD connection pool" jdbc/LEAD 4. Ping the connection pool: asadmin ping-connection-pool LEADConnectionPool 5. Observe the following error: remote failure: Ping Connection Pool for LEADConnectionPool is Failed. Ping failed Exception - Class name is wrong or classpath is not set for : com.mysql.jdbc.jdbc2.optional.MysqlDataSource Please check the server.log for more details. Ping failed Exception - Class name is wrong or classpath is not set for : com.mysql.jdbc.jdbc2.optional.MysqlDataSource Please check the server.log for more details. Command ping-connection-pool failed. 6. Perform the same steps on b33 and observe no error.
    via by ljnelson,
    • com.tc.exception.TCClassNotFoundException: java.lang.ClassNotFoundException: org.terracotta.modules.concurrent.collections.ConcurrentStringMap at com.tc.object.ClientObjectManagerImpl.lookupOrCreateRoot(ClientObjectManagerImpl.java:644) at com.tc.object.bytecode.ManagerImpl.lookupOrCreateRoot(ManagerImpl.java:321) at com.tc.object.bytecode.ManagerImpl.lookupOrCreateRoot(ManagerImpl.java:300) at com.tc.object.bytecode.ManagerUtil.lookupOrCreateRoot(ManagerUtil.java:96) at com.delta5.db.simple.model.SimpleStores.__tc_setstores(SimpleStores.java) at com.delta5.db.simple.model.SimpleStores.<clinit>(SimpleStores.java:24) at com.delta5.db.simple.SimpleEntityStore.<init>(SimpleEntityStore.java:49) at com.delta5.db.Dbs.makeStore(Dbs.java:48) at com.delta5.model.Entity.store(Entity.java:237) at com.delta5.db.Dbs.query(Dbs.java:118) at com.delta5.model.View.query(View.java:1709) at com.delta5.model.visitor.ListTupleVisitor.tuples(ListTupleVisitor.java:48) at com.delta5.model.Entity.tuples(Entity.java:662) at com.delta5.module.place.Place.load3(Place.java:848) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.delta5.engine.Engine.invoke(Engine.java:172) at com.delta5.engine.Engine.runTo(Engine.java:201) at com.delta5.engine.Engine.load(Engine.java:309) at com.delta5.ui.servlet.delta5.init(delta5.java:47) at com.delta5.ui.servlet.Go.init(Go.java:39) at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1173) at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:993) at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4149) at org.apache.catalina.core.StandardContext.start(StandardContext.java:4458) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:526) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:630) at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:556) at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:491) at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1206) at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:314) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053) at org.apache.catalina.core.StandardHost.start(StandardHost.java:722) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) at org.apache.catalina.core.StandardService.start(StandardService.java:516) at org.apache.catalina.core.StandardServer.start(StandardServer.java:710) at org.apache.catalina.startup.Catalina.start(Catalina.java:583) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:288) at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:413) Caused by: java.lang.ClassNotFoundException: org.terracotta.modules.concurrent.collections.ConcurrentStringMap at java.net.URLClassLoader$1.run(URLClassLoader.java:200) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at sun.misc.Launcher$AppClassLoader.findClass(Launcher.java) at java.lang.ClassLoader.loadClass(ClassLoader.java:319) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:330) at java.lang.ClassLoader.loadClass(ClassLoader.java:254) at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:402) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:247) at com.tc.object.loaders.StandardClassProvider.getClassFor(StandardClassProvider.java:86) at com.tc.object.ClientObjectManagerImpl.lookup(ClientObjectManagerImpl.java:529) at com.tc.object.ClientObjectManagerImpl.lookupObject(ClientObjectManagerImpl.java:432)

    Users with the same issue

    zsamboki
    1 times, last one,
    Pilleo
    2 times, last one,
    kimihanif
    1 times, last one,
    Unknown visitor1 times, last one,
    SteVio1989
    2 times, last one,
    1376 more bugmates