Skip to content

Commit

Permalink
Add DataSourceModule to QuerydslGenerator
Browse files Browse the repository at this point in the history
  • Loading branch information
amanteaux committed Dec 6, 2024
1 parent aa3d9b1 commit 85ab858
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/main/java/com/coreoz/db/QuerydslGenerator.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

import com.coreoz.plume.admin.db.generated.AdminUser;
import com.coreoz.plume.conf.guice.GuiceConfModule;
import com.coreoz.plume.db.guice.DataSourceModule;
import com.coreoz.plume.db.querydsl.generation.IdBeanSerializer;
import com.coreoz.plume.db.transaction.TransactionManager;
import com.coreoz.plume.file.db.beans.FileDataQueryDsl;
Expand Down Expand Up @@ -74,7 +75,7 @@ public String getDefaultVariableName(EntityType entityType) {
exporter.setColumnAnnotations(true);
exporter.setConfiguration(configuration);

Injector injector = Guice.createInjector(new GuiceConfModule());
Injector injector = Guice.createInjector(new GuiceConfModule(), new DataSourceModule());
injector.getInstance(TransactionManager.class).execute(connection -> {
try {
exporter.export(connection.getMetaData());
Expand Down

0 comments on commit 85ab858

Please sign in to comment.