Roy Golan has posted comments on this change.

Change subject: core: Infra for injecting beans in external JARs
......................................................................


Patch Set 2:

(7 comments)

http://gerrit.ovirt.org/#/c/37439/2/backend/manager/dependencies/common/pom.xml
File backend/manager/dependencies/common/pom.xml:

Line 379:       <version>${jackson.version}</version>
Line 380:     </dependency>
Line 381: 
Line 382:     <dependency>
Line 383:       <groupId>org.apache.deltaspike.core</groupId>
please check if we have that delta spike version in brew
Line 384:       <artifactId>deltaspike-core-api</artifactId>
Line 385:       <version>${deltaspike.version}</version>
Line 386:     </dependency>
Line 387: 


http://gerrit.ovirt.org/#/c/37439/2/backend/manager/modules/bll/pom.xml
File backend/manager/modules/bll/pom.xml:

Line 164:         <scope>provided</scope>
Line 165:      </dependency>
Line 166:      <dependency>
Line 167:          <groupId>org.scala-lang</groupId>
Line 168:          <artifactId>scala-library</artifactId>
weird no? 
why is that needed?
Line 169:          <version>2.10.4</version>
Line 170:      </dependency>
Line 171:      <dependency>
Line 172:          <groupId>org.springframework.boot</groupId>


http://gerrit.ovirt.org/#/c/37439/2/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/utils/ModuleConfigurationExtension.java
File 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/utils/ModuleConfigurationExtension.java:

Line 21: import org.reflections.Reflections;
Line 22: import org.slf4j.Logger;
Line 23: import org.slf4j.LoggerFactory;
Line 24: 
Line 25: import com.google.common.base.Strings;
if that's the only use for guava dependency than I'd rather
you drop it
Line 26: 
Line 27: public class ModuleConfigurationExtension implements Extension {
Line 28:     private static final Logger log = 
LoggerFactory.getLogger(ModuleConfigurationExtension.class);
Line 29:     private final Map<String, AnnotatedType<Object>> beans = new 
HashMap<>();


Line 29:     private final Map<String, AnnotatedType<Object>> beans = new 
HashMap<>();
Line 30: 
Line 31:     /**
Line 32:      * This method is automatically activated by CDI, and loads all 
classes in the org.ovirt package that has NAMED or
Line 33:      * SINGLETON annotations.
what about support for other scopes? like ApplicationScope and so on
Line 34:      * @param bdd
Line 35:      */
Line 36:     void readAllConfigurations(final @Observes BeforeBeanDiscovery 
bdd, BeanManager bm) {
Line 37:         log.info("Starting to load beans from modules");


Line 32:      * This method is automatically activated by CDI, and loads all 
classes in the org.ovirt package that has NAMED or
Line 33:      * SINGLETON annotations.
Line 34:      * @param bdd
Line 35:      */
Line 36:     void readAllConfigurations(final @Observes BeforeBeanDiscovery 
bdd, BeanManager bm) {
we need to make sure we remove the beans.xml from dal otherwise we'd have 
problems with EAP
Line 37:         log.info("Starting to load beans from modules");
Line 38:         addBeansFromPackage(bdd, bm, "org.ovirt.engine.core.dal");
Line 39:         addBeansFromPackage(bdd, bm, "org.ovirt.engine.core.dao");
Line 40:     }


Line 57: isNullOrEmpty
you can use apache.StringUtils its already in the dep tree


http://gerrit.ovirt.org/#/c/37439/2/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/utils/SimpleDependecyInjector.java
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/utils/SimpleDependecyInjector.java:

Line 62:      * @param clazz
Line 63:      * @param <T>
Line 64:      * @return
Line 65:      */
Line 66:     @SuppressWarnings("unchecked")
I guess not realated
Line 67:     public <T> T get(Class<T> clazz) {
Line 68:         return (T) map.get(clazz.getName());
Line 69:     }
Line 70: 


-- 
To view, visit http://gerrit.ovirt.org/37439
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I3b3c2c57178b5df4f98b4191ac9a06f9129414d0
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Liran Zelkha <[email protected]>
Gerrit-Reviewer: Liran Zelkha <[email protected]>
Gerrit-Reviewer: Oved Ourfali <[email protected]>
Gerrit-Reviewer: Roy Golan <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to