Search in sources :

Example 1 with PitJoinController

use of io.hops.hopsworks.common.featurestore.query.pit.PitJoinController in project hopsworks by logicalclocks.

the class TestPitJoinController method setup.

@Before
public void setup() {
    fs = new Featurestore();
    fs.setHiveDbId(1l);
    fs.setProject(new Project("test_proj"));
    cachedFeaturegroup = new CachedFeaturegroup();
    cachedFeaturegroup.setTimeTravelFormat(TimeTravelFormat.NONE);
    fgLeft = new Featuregroup(1);
    fgLeft.setEventTime("ts");
    fgLeft.setName("fg0");
    fgLeft.setVersion(1);
    fgLeft.setCachedFeaturegroup(cachedFeaturegroup);
    fgLeft.setFeaturestore(fs);
    fgRight = new Featuregroup(2);
    fgRight.setEventTime("ts");
    fgRight.setName("fg1");
    fgRight.setVersion(1);
    fgRight.setCachedFeaturegroup(cachedFeaturegroup);
    fgRight.setFeaturestore(fs);
    fgRight1 = new Featuregroup(3);
    fgRight1.setEventTime("ts");
    fgRight1.setName("fg2");
    fgRight1.setVersion(1);
    fgRight1.setCachedFeaturegroup(cachedFeaturegroup);
    fgRight1.setFeaturestore(fs);
    FeaturegroupController featuregroupController = Mockito.mock(FeaturegroupController.class);
    FeaturegroupFacade featuregroupFacade = Mockito.mock(FeaturegroupFacade.class);
    FeaturestoreFacade featurestoreFacade = Mockito.mock(FeaturestoreFacade.class);
    OnlineFeaturestoreController onlineFeaturestoreController = Mockito.mock(OnlineFeaturestoreController.class);
    CachedFeaturegroupController cachedFeaturegroupController = Mockito.mock(CachedFeaturegroupController.class);
    FilterController filterController = new FilterController(new ConstructorController());
    JoinController joinController = new JoinController(new ConstructorController());
    ConstructorController constructorController = new ConstructorController(featuregroupController, featurestoreFacade, featuregroupFacade, onlineFeaturestoreController, cachedFeaturegroupController, filterController, joinController);
    pitJoinController = new PitJoinController(constructorController, filterController, joinController);
}
Also used : FeaturegroupFacade(io.hops.hopsworks.common.featurestore.featuregroup.FeaturegroupFacade) Featuregroup(io.hops.hopsworks.persistence.entity.featurestore.featuregroup.Featuregroup) CachedFeaturegroup(io.hops.hopsworks.persistence.entity.featurestore.featuregroup.cached.CachedFeaturegroup) CachedFeaturegroupController(io.hops.hopsworks.common.featurestore.featuregroup.cached.CachedFeaturegroupController) FeaturestoreFacade(io.hops.hopsworks.common.featurestore.FeaturestoreFacade) ConstructorController(io.hops.hopsworks.common.featurestore.query.ConstructorController) Project(io.hops.hopsworks.persistence.entity.project.Project) PitJoinController(io.hops.hopsworks.common.featurestore.query.pit.PitJoinController) Featurestore(io.hops.hopsworks.persistence.entity.featurestore.Featurestore) FilterController(io.hops.hopsworks.common.featurestore.query.filter.FilterController) JoinController(io.hops.hopsworks.common.featurestore.query.join.JoinController) PitJoinController(io.hops.hopsworks.common.featurestore.query.pit.PitJoinController) OnlineFeaturestoreController(io.hops.hopsworks.common.featurestore.online.OnlineFeaturestoreController) CachedFeaturegroupController(io.hops.hopsworks.common.featurestore.featuregroup.cached.CachedFeaturegroupController) FeaturegroupController(io.hops.hopsworks.common.featurestore.featuregroup.FeaturegroupController) CachedFeaturegroup(io.hops.hopsworks.persistence.entity.featurestore.featuregroup.cached.CachedFeaturegroup) Before(org.junit.Before)

Aggregations

FeaturestoreFacade (io.hops.hopsworks.common.featurestore.FeaturestoreFacade)1 FeaturegroupController (io.hops.hopsworks.common.featurestore.featuregroup.FeaturegroupController)1 FeaturegroupFacade (io.hops.hopsworks.common.featurestore.featuregroup.FeaturegroupFacade)1 CachedFeaturegroupController (io.hops.hopsworks.common.featurestore.featuregroup.cached.CachedFeaturegroupController)1 OnlineFeaturestoreController (io.hops.hopsworks.common.featurestore.online.OnlineFeaturestoreController)1 ConstructorController (io.hops.hopsworks.common.featurestore.query.ConstructorController)1 FilterController (io.hops.hopsworks.common.featurestore.query.filter.FilterController)1 JoinController (io.hops.hopsworks.common.featurestore.query.join.JoinController)1 PitJoinController (io.hops.hopsworks.common.featurestore.query.pit.PitJoinController)1 Featurestore (io.hops.hopsworks.persistence.entity.featurestore.Featurestore)1 Featuregroup (io.hops.hopsworks.persistence.entity.featurestore.featuregroup.Featuregroup)1 CachedFeaturegroup (io.hops.hopsworks.persistence.entity.featurestore.featuregroup.cached.CachedFeaturegroup)1 Project (io.hops.hopsworks.persistence.entity.project.Project)1 Before (org.junit.Before)1