14:02:50,173 INFO org.hibernate.cfg.annotations.Version:43 - Hibernate Annotations 3.5.4-Final 14:02:50,184 INFO org.hibernate.cfg.Environment:570 - Hibernate 3.5.4-Final 14:02:50,185 INFO org.hibernate.cfg.Environment:603 - hibernate.properties not found 14:02:50,189 INFO org.hibernate.cfg.Environment:781 - Bytecode provider name : javassist 14:02:50,191 INFO org.hibernate.cfg.Environment:662 - using JDK 1.4 java.sql.Timestamp handling 14:02:50,247 INFO org.hibernate.annotations.common.Version:37 - Hibernate Commons Annotations 3.2.0.Final 14:02:50,254 INFO org.hibernate.cfg.Configuration:1518 - configuring from resource: /hibernate.cfg.xml 14:02:50,254 INFO org.hibernate.cfg.Configuration:1495 - Configuration resource: /hibernate.cfg.xml 14:02:50,303 INFO org.hibernate.cfg.Configuration:1633 - Configured SessionFactory: null 14:02:50,309 INFO org.hibernate.cfg.search.HibernateSearchEventListenerRegister:75 - Unable to find org.hibernate.search.event.FullTextIndexEventListener on the classpath. Hibernate Search is not enabled. 14:02:50,343 INFO org.hibernate.cfg.AnnotationBinder:529 - Binding entity from annotated class: EntityA 14:02:50,367 INFO org.hibernate.cfg.annotations.EntityBinder:501 - Bind entity EntityA on table EntityA 14:02:50,423 INFO org.hibernate.cfg.AnnotationBinder:529 - Binding entity from annotated class: EntityB 14:02:50,423 INFO org.hibernate.cfg.annotations.EntityBinder:501 - Bind entity EntityB on table EntityB 14:02:50,427 INFO org.hibernate.cfg.AnnotationBinder:529 - Binding entity from annotated class: EntityC 14:02:50,427 INFO org.hibernate.cfg.annotations.EntityBinder:501 - Bind entity EntityC on table EntityC 14:02:50,469 INFO org.hibernate.cfg.annotations.CollectionBinder:729 - Mapping collection: EntityA.entityCs -> EntityC 14:02:50,470 INFO org.hibernate.cfg.AnnotationConfiguration:450 - Hibernate Validator not found: ignoring 14:02:50,474 INFO org.hibernate.connection.DriverManagerConnectionProvider:64 - Using Hibernate built-in connection pool (not for production use!) 14:02:50,474 INFO org.hibernate.connection.DriverManagerConnectionProvider:65 - Hibernate connection pool size: 1 14:02:50,475 INFO org.hibernate.connection.DriverManagerConnectionProvider:68 - autocommit mode: false 14:02:50,484 INFO org.hibernate.connection.DriverManagerConnectionProvider:103 - using driver: org.postgresql.Driver at URL: jdbc:postgresql://localhost/hlfjec 14:02:50,484 INFO org.hibernate.connection.DriverManagerConnectionProvider:109 - connection properties: {user=hlfjec, password=****} 14:02:50,527 INFO org.hibernate.cfg.SettingsFactory:117 - RDBMS: PostgreSQL, version: 8.4.4 14:02:50,527 INFO org.hibernate.cfg.SettingsFactory:118 - JDBC driver: PostgreSQL Native Driver, version: PostgreSQL 8.4 JDBC3 (build 701) 14:02:50,541 INFO org.hibernate.dialect.Dialect:206 - Using dialect: org.hibernate.dialect.PostgreSQLDialect 14:02:50,545 INFO org.hibernate.engine.jdbc.JdbcSupportLoader:79 - Disabling contextual LOB creation as JDBC driver reported JDBC version [3] less than 4 14:02:50,546 INFO org.hibernate.transaction.TransactionFactoryFactory:59 - Using default transaction strategy (direct JDBC transactions) 14:02:50,547 INFO org.hibernate.transaction.TransactionManagerLookupFactory:80 - No TransactionManagerLookup configured (in JTA environment, use of read-write or transactional second-level cache is not recommended) 14:02:50,547 INFO org.hibernate.cfg.SettingsFactory:169 - Automatic flush during beforeCompletion(): disabled 14:02:50,547 INFO org.hibernate.cfg.SettingsFactory:173 - Automatic session close at end of transaction: disabled 14:02:50,548 INFO org.hibernate.cfg.SettingsFactory:180 - JDBC batch size: 15 14:02:50,548 INFO org.hibernate.cfg.SettingsFactory:183 - JDBC batch updates for versioned data: disabled 14:02:50,548 INFO org.hibernate.cfg.SettingsFactory:188 - Scrollable result sets: enabled 14:02:50,548 INFO org.hibernate.cfg.SettingsFactory:196 - JDBC3 getGeneratedKeys(): enabled 14:02:50,548 INFO org.hibernate.cfg.SettingsFactory:204 - Connection release mode: auto 14:02:50,548 INFO org.hibernate.cfg.SettingsFactory:231 - Default batch fetch size: 1 14:02:50,549 INFO org.hibernate.cfg.SettingsFactory:235 - Generate SQL with comments: disabled 14:02:50,549 INFO org.hibernate.cfg.SettingsFactory:239 - Order SQL updates by primary key: disabled 14:02:50,549 INFO org.hibernate.cfg.SettingsFactory:243 - Order SQL inserts for batching: disabled 14:02:50,549 INFO org.hibernate.cfg.SettingsFactory:410 - Query translator: org.hibernate.hql.ast.ASTQueryTranslatorFactory 14:02:50,550 INFO org.hibernate.hql.ast.ASTQueryTranslatorFactory:47 - Using ASTQueryTranslatorFactory 14:02:50,550 INFO org.hibernate.cfg.SettingsFactory:251 - Query language substitutions: {} 14:02:50,550 INFO org.hibernate.cfg.SettingsFactory:256 - JPA-QL strict compliance: disabled 14:02:50,550 INFO org.hibernate.cfg.SettingsFactory:261 - Second-level cache: enabled 14:02:50,550 INFO org.hibernate.cfg.SettingsFactory:265 - Query cache: disabled 14:02:50,552 INFO org.hibernate.cfg.SettingsFactory:395 - Cache region factory : org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge 14:02:50,552 INFO org.hibernate.cache.impl.bridge.RegionFactoryCacheProviderBridge:61 - Cache provider: org.hibernate.cache.NoCacheProvider 14:02:50,552 INFO org.hibernate.cfg.SettingsFactory:275 - Optimize cache for minimal puts: disabled 14:02:50,553 INFO org.hibernate.cfg.SettingsFactory:284 - Structured second-level cache entries: disabled 14:02:50,555 INFO org.hibernate.cfg.SettingsFactory:304 - Echoing all SQL to stdout 14:02:50,555 INFO org.hibernate.cfg.SettingsFactory:313 - Statistics: disabled 14:02:50,555 INFO org.hibernate.cfg.SettingsFactory:317 - Deleted entity synthetic identifier rollback: disabled 14:02:50,555 INFO org.hibernate.cfg.SettingsFactory:332 - Default entity-mode: pojo 14:02:50,556 INFO org.hibernate.cfg.SettingsFactory:336 - Named query checking : enabled 14:02:50,556 INFO org.hibernate.cfg.SettingsFactory:340 - Check Nullability in Core (should be disabled when Bean Validation is on): enabled 14:02:50,576 INFO org.hibernate.impl.SessionFactoryImpl:199 - building session factory 14:02:50,693 INFO org.hibernate.impl.SessionFactoryObjectFactory:105 - Not binding factory to JNDI, no JNDI name configured 14:02:50,696 INFO org.hibernate.tool.hbm2ddl.SchemaUpdate:155 - Running hbm2ddl schema update 14:02:50,696 INFO org.hibernate.tool.hbm2ddl.SchemaUpdate:167 - fetching database metadata 14:02:50,711 INFO org.hibernate.tool.hbm2ddl.SchemaUpdate:179 - updating schema 14:02:50,744 INFO org.hibernate.tool.hbm2ddl.TableMetadata:65 - table found: public.entitya 14:02:50,744 INFO org.hibernate.tool.hbm2ddl.TableMetadata:66 - columns: [id, entityb_id] 14:02:50,744 INFO org.hibernate.tool.hbm2ddl.TableMetadata:68 - foreign keys: [fk457309e516d3b55] 14:02:50,744 INFO org.hibernate.tool.hbm2ddl.TableMetadata:69 - indexes: [entitya_pkey] 14:02:50,772 INFO org.hibernate.tool.hbm2ddl.TableMetadata:65 - table found: public.entityb 14:02:50,773 INFO org.hibernate.tool.hbm2ddl.TableMetadata:66 - columns: [id, entityb_id] 14:02:50,773 INFO org.hibernate.tool.hbm2ddl.TableMetadata:68 - foreign keys: [fk457309f516d3b55] 14:02:50,773 INFO org.hibernate.tool.hbm2ddl.TableMetadata:69 - indexes: [entityb_pkey] 14:02:50,807 INFO org.hibernate.tool.hbm2ddl.TableMetadata:65 - table found: public.entityb_items 14:02:50,807 INFO org.hibernate.tool.hbm2ddl.TableMetadata:66 - columns: [entityb_id, items] 14:02:50,807 INFO org.hibernate.tool.hbm2ddl.TableMetadata:68 - foreign keys: [fkd54c4820516d3b55] 14:02:50,807 INFO org.hibernate.tool.hbm2ddl.TableMetadata:69 - indexes: [] 14:02:50,829 INFO org.hibernate.tool.hbm2ddl.TableMetadata:65 - table found: public.entityc 14:02:50,829 INFO org.hibernate.tool.hbm2ddl.TableMetadata:66 - columns: [id, entitya, entityb_id] 14:02:50,829 INFO org.hibernate.tool.hbm2ddl.TableMetadata:68 - foreign keys: [fk45730a04aea9bb7, fk45730a0516d3b56] 14:02:50,830 INFO org.hibernate.tool.hbm2ddl.TableMetadata:69 - indexes: [entityc_pkey] 14:02:50,850 INFO org.hibernate.tool.hbm2ddl.TableMetadata:65 - table found: public.entityc_items 14:02:50,851 INFO org.hibernate.tool.hbm2ddl.TableMetadata:66 - columns: [items, entityc_id] 14:02:50,851 INFO org.hibernate.tool.hbm2ddl.TableMetadata:68 - foreign keys: [fka328361516dafb5] 14:02:50,851 INFO org.hibernate.tool.hbm2ddl.TableMetadata:69 - indexes: [] 14:02:50,852 INFO org.hibernate.tool.hbm2ddl.SchemaUpdate:217 - schema update complete Hibernate: select entityb0_.id as id1_, entityb0_.entityB_id as entityB2_1_, items1_.EntityB_id as EntityB1_1_0__, items1_.items as items0__ from EntityB entityb0_ left outer join EntityB_items items1_ on entityb0_.id=items1_.EntityB_id Hibernate: select entitya0_.id as id0_0_, entityb1_.id as id1_1_, entitya0_.entityB_id as entityB2_0_0_, entityb1_.entityB_id as entityB2_1_1_ from EntityA entitya0_ left outer join EntityB entityb1_ on entitya0_.entityB_id=entityb1_.id Hibernate: select entitya0_.id as id0_, entitya0_.entityB_id as entityB2_0_, items2_.EntityB_id as EntityB1_1_0__, items2_.items as items0__ from EntityA entitya0_ left outer join EntityB entityb1_ on entitya0_.entityB_id=entityb1_.id left outer join Entit yB_items items2_ on entityb1_.id=items2_.EntityB_id Hibernate: select entitya0_.id as id0_0_, entitycs1_.id as id2_1_, entitya0_.entityB_id as entityB2_0_0_, items2_.EntityC_id as EntityC1_2_1__, items2_.items as items1__, entitycs1_.entityB_id as entityB2_2_1_, entitycs1_.entitya as entitya0_0__, entitycs1 _.id as id0__, items2_.EntityC_id as EntityC1_2_1__, items2_.items as items1__ from EntityA entitya0_ left outer join EntityC entitycs1_ on entitya0_.id=entitycs1_.entitya left outer join EntityC_items items2_ on entitycs1_.id=items2_.EntityC_id Exception in thread "main" java.lang.NullPointerException at org.hibernate.loader.BasicLoader.isBag(BasicLoader.java:99) at org.hibernate.loader.BasicLoader.postInstantiate(BasicLoader.java:78) at org.hibernate.loader.hql.QueryLoader.(QueryLoader.java:123) at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:206) at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:136) at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:101) at org.hibernate.engine.query.HQLQueryPlan.(HQLQueryPlan.java:80) at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:98) at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:156) at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:135) at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1760) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:616) at org.hibernate.context.ThreadLocalSessionContext$TransactionProtectionWrapper.invoke(ThreadLocalSessionContext.java:344) at $Proxy9.createQuery(Unknown Source) at Main.main(Main.java:27)