해결된 질문
작성
·
2K
·
수정됨
1
학습하는 분들께 도움이 되고, 더 좋은 답변을 드릴 수 있도록 질문전에 다음을 꼭 확인해주세요.
1. 강의 내용과 관련된 질문을 남겨주세요.
2. 인프런의 질문 게시판과 자주 하는 질문(링크)을 먼저 확인해주세요.
(자주 하는 질문 링크: https://bit.ly/3fX6ygx)
3. 질문 잘하기 메뉴얼(링크)을 먼저 읽어주세요.
(질문 잘하기 메뉴얼 링크: https://bit.ly/2UfeqCG)
질문 시에는 위 내용은 삭제하고 다음 내용을 남겨주세요.
=========================================
[질문 템플릿]
1. 강의 내용과 관련된 질문인가요? 네
2. 인프런의 질문 게시판과 자주 하는 질문에 없는 내용인가요? 네
3. 질문 잘하기 메뉴얼을 읽어보셨나요? 네
[질문 내용]
HHH000511: The 2.2.0 version for [org.hibernate.dialect.OracleDialect] is no longer supported, hence certain features may not work properly. The minimum supported version is 19.0.0. Check the community dialects project for available legacy versions.
HHH90000025: OracleDialect does not need to be specified explicitly using 'hibernate.dialect' (remove the property setting and it will be selected by default)
HHH10001008: Cleaning up connection pool [jdbc:h2:tcp://localhost/~/test]
Exception in thread "main" jakarta.persistence.PersistenceException: [PersistenceUnit: hello] Unable to build Hibernate SessionFactory
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.persistenceException(EntityManagerFactoryBuilderImpl.java:1591)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:1512)
at org.hibernate.jpa.HibernatePersistenceProvider.createEntityManagerFactory(HibernatePersistenceProvider.java:55)
at jakarta.persistence.Persistence.createEntityManagerFactory(Persistence.java:80)
at jakarta.persistence.Persistence.createEntityManagerFactory(Persistence.java:55)
at jpql.JpaMain.main(JpaMain.java:14)
Caused by: org.hibernate.MappingException: Could not instantiate id generator [entity-name=jpql.Product]
at org.hibernate.id.factory.internal.StandardIdentifierGeneratorFactory.createIdentifierGenerator(StandardIdentifierGeneratorFactory.java:230)
at org.hibernate.id.factory.internal.IdentifierGeneratorUtil.createLegacyIdentifierGenerator(IdentifierGeneratorUtil.java:127)
at org.hibernate.mapping.SimpleValue.createGenerator(SimpleValue.java:415)
at org.hibernate.internal.SessionFactoryImpl.lambda$createGenerators$1(SessionFactoryImpl.java:457)
at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.accept(ForEachOps.java:183)
at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:179)
at java.base/java.util.HashMap$ValueSpliterator.forEachRemaining(HashMap.java:1779)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
at java.base/java.util.stream.ForEachOps$ForEachOp.evaluateSequential(ForEachOps.java:150)
at java.base/java.util.stream.ForEachOps$ForEachOp$OfRef.evaluateSequential(ForEachOps.java:173)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.forEach(ReferencePipeline.java:596)
at org.hibernate.internal.SessionFactoryImpl.createGenerators(SessionFactoryImpl.java:456)
at org.hibernate.internal.SessionFactoryImpl.<init>(SessionFactoryImpl.java:271)
at org.hibernate.boot.internal.SessionFactoryBuilderImpl.build(SessionFactoryBuilderImpl.java:450)
at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:1507)
... 4 more
Caused by: org.hibernate.HibernateException: Could not fetch the SequenceInformation from the database
at org.hibernate.engine.jdbc.env.internal.ExtractedDatabaseMetaDataImpl.sequenceInformationList(ExtractedDatabaseMetaDataImpl.java:307)
at org.hibernate.engine.jdbc.env.internal.ExtractedDatabaseMetaDataImpl.getSequenceInformationList(ExtractedDatabaseMetaDataImpl.java:151)
at org.hibernate.id.enhanced.SequenceStyleGenerator.getSequenceIncrementValue(SequenceStyleGenerator.java:581)
at org.hibernate.id.enhanced.SequenceStyleGenerator.adjustIncrementSize(SequenceStyleGenerator.java:259)
at org.hibernate.id.enhanced.SequenceStyleGenerator.configure(SequenceStyleGenerator.java:207)
at org.hibernate.id.factory.internal.StandardIdentifierGeneratorFactory.createIdentifierGenerator(StandardIdentifierGeneratorFactory.java:224)
... 20 more
Caused by: org.h2.jdbc.JdbcSQLSyntaxErrorException: Table "ALL_SEQUENCES" not found; SQL statement:
select * from all_sequences [42102-224]
at org.h2.message.DbException.getJdbcSQLException(DbException.java:514)
at org.h2.message.DbException.getJdbcSQLException(DbException.java:489)
at org.h2.message.DbException.get(DbException.java:223)
at org.h2.message.DbException.get(DbException.java:199)
at org.h2.command.Parser.getTableOrViewNotFoundDbException(Parser.java:8064)
at org.h2.command.Parser.getTableOrViewNotFoundDbException(Parser.java:8035)
at org.h2.command.Parser.readTableOrView(Parser.java:8024)
at org.h2.command.Parser.readTablePrimary(Parser.java:1788)
at org.h2.command.Parser.readTableReference(Parser.java:2268)
at org.h2.command.Parser.parseSelectFromPart(Parser.java:2718)
at org.h2.command.Parser.parseSelect(Parser.java:2824)
at org.h2.command.Parser.parseQueryPrimary(Parser.java:2708)
at org.h2.command.Parser.parseQueryTerm(Parser.java:2564)
at org.h2.command.Parser.parseQueryExpressionBody(Parser.java:2543)
at org.h2.command.Parser.parseQueryExpressionBodyAndEndOfQuery(Parser.java:2536)
at org.h2.command.Parser.parseQueryExpression(Parser.java:2529)
at org.h2.command.Parser.parseQuery(Parser.java:2498)
at org.h2.command.Parser.parsePrepared(Parser.java:627)
at org.h2.command.Parser.parse(Parser.java:592)
at org.h2.command.Parser.parse(Parser.java:564)
at org.h2.command.Parser.prepareCommand(Parser.java:483)
at org.h2.engine.SessionLocal.prepareLocal(SessionLocal.java:639)
at org.h2.server.TcpServerThread.process(TcpServerThread.java:289)
at org.h2.server.TcpServerThread.run(TcpServerThread.java:191)
at java.base/java.lang.Thread.run(Thread.java:842)
at org.h2.message.DbException.getJdbcSQLException(DbException.java:514)
at org.h2.engine.SessionRemote.readException(SessionRemote.java:650)
at org.h2.engine.SessionRemote.done(SessionRemote.java:619)
at org.h2.command.CommandRemote.prepare(CommandRemote.java:78)
at org.h2.command.CommandRemote.<init>(CommandRemote.java:50)
at org.h2.engine.SessionRemote.prepareCommand(SessionRemote.java:487)
at org.h2.jdbc.JdbcConnection.prepareCommand(JdbcConnection.java:1166)
at org.h2.jdbc.JdbcPreparedStatement.<init>(JdbcPreparedStatement.java:93)
at org.h2.jdbc.JdbcConnection.prepareStatement(JdbcConnection.java:316)
at org.hibernate.tool.schema.extract.spi.ExtractionContext.getQueryResults(ExtractionContext.java:43)
at org.hibernate.tool.schema.extract.internal.SequenceInformationExtractorLegacyImpl.extractMetadata(SequenceInformationExtractorLegacyImpl.java:39)
at org.hibernate.engine.jdbc.env.internal.ExtractedDatabaseMetaDataImpl.sequenceInformationList(ExtractedDatabaseMetaDataImpl.java:291)
... 25 more
[해결]
mysql 방언은 url 뒤에 ;MODE=MySql 을 추가하니 해결되었습니다.
HHH000511: The 2.2.0 version for [org.hibernate.dialect.MySQLDialect] is no longer supported, hence certain features may not work properly. The minimum supported version is 8.0.0. Check the community dialects project for available legacy versions.
HHH90000025: MySQLDialect does not need to be specified explicitly using 'hibernate.dialect' (remove the property setting and it will be selected by default)
HHH000489: No JTA platform available (set 'hibernate.transaction.jta.platform' to enable JTA platform integration)
답변 2
2
버전을 변경하거나 업데이트를 최대한 안하고 해결 해보려고 하다 실패했는데 낮추거나 업데이트를 해야하는군요 ㅠㅠ 늦은 시간에 답변 너무 감사합니다!