Solucionado (ver solução)
Solucionado
(ver solução)
1
resposta

[Sugestão] Problemas de Execução

package br.com.alura.jdbc;

import javax.swing.JFrame;

import br.com.alura.jdbc.view.ProdutoCategoriaFrame;

public class TestaOperacaoComView {

    public static void main(String[] args) {
        ProdutoCategoriaFrame produtoCategoriaFrame = new ProdutoCategoriaFrame();
        produtoCategoriaFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    }
}
dez. 13, 2022 5:17:34 PM com.mchange.v2.log.MLog 
INFO: MLog clients using java 1.4+ standard logging.
dez. 13, 2022 5:17:34 PM com.mchange.v2.c3p0.C3P0Registry 
INFO: Initializing c3p0-0.9.5.4 [built 23-March-2019 23:00:48 -0700; debug? true; trace: 10]
dez. 13, 2022 5:17:35 PM com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource 
INFO: Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, contextClassLoaderSource -> caller, dataSourceName -> 1hge161at3n7ff71np4te4|59906517, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> null, extensions -> {}, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, forceSynchronousCheckins -> false, forceUseNamedDriverClass -> false, identityToken -> 1hge161at3n7ff71np4te4|59906517, idleConnectionTestPeriod -> 0, initialPoolSize -> 3, jdbcUrl -> jdbc:mysql://localhost3306/lojavirtual?useTimezone=true&serverTimezone=UTC, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 0, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 15, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 3, numHelperThreads -> 3, preferredTestQuery -> null, privilegeSpawnedThreads -> false, properties -> {password=******, user=******}, propertyCycle -> 0, statementCacheNumDeferredCloseThreads -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, userOverrides -> {}, usesTraditionalReflectiveProxies -> false ]
dez. 13, 2022 5:18:05 PM com.mchange.v2.resourcepool.BasicResourcePool 
WARNING: com.mchange.v2.resourcepool.BasicResourcePool$ScatteredAcquireTask@31038796 -- Acquisition Attempt Failed!!! Clearing pending acquires. While trying to acquire a needed new resource, we failed to succeed more than the maximum number of allowed acquisition attempts (30). Last acquisition attempt exception: 
java.sql.SQLException: No suitable driver
    at java.sql/java.sql.DriverManager.getDriver(DriverManager.java:300)
    at com.mchange.v2.c3p0.DriverManagerDataSource.driver(DriverManagerDataSource.java:285)
    at com.mchange.v2.c3p0.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:175)
    at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:220)
    at com.mchange.v2.c3p0.WrapperConnectionPoolDataSource.getPooledConnection(WrapperConnectionPoolDataSource.java:206)
    at 

Não entendi o motivo do erro e pro que não esta abrindo a View?

1 resposta
solução!

Boa noite Eduardo.

Por favor, verifique se os JARs do curso foram baixados e associados no Build Path conforme exemplos da aula. São estes blocos do curso aqui:

Driver: https://cursos.alura.com.br/course/jdbc-dao-persistencia/task/68924 Pool de Conexão: https://cursos.alura.com.br/course/jdbc-dao-persistencia/task/68949

Caso tenha alguma dúvida, por favor, pode postar aqui.

Bons estudos!!