ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anovi...@apache.org
Subject [01/18] ignite git commit: ignite-843 Agent initial commit
Date Tue, 13 Oct 2015 03:28:02 GMT
Repository: ignite
Updated Branches:
  refs/heads/ignite-843-rc1 [created] 433160528


http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/AgentSqlTestDrive.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/AgentSqlTestDrive.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/AgentSqlTestDrive.java
new file mode 100644
index 0000000..d920a1b
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/AgentSqlTestDrive.java
@@ -0,0 +1,414 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.LinkedHashMap;
+import java.util.Map;
+import java.util.Random;
+import java.util.concurrent.atomic.AtomicBoolean;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+import org.apache.ignite.Ignite;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.Ignition;
+import org.apache.ignite.agent.AgentConfiguration;
+import org.apache.ignite.agent.testdrive.model.Car;
+import org.apache.ignite.agent.testdrive.model.CarKey;
+import org.apache.ignite.agent.testdrive.model.Country;
+import org.apache.ignite.agent.testdrive.model.CountryKey;
+import org.apache.ignite.agent.testdrive.model.Department;
+import org.apache.ignite.agent.testdrive.model.DepartmentKey;
+import org.apache.ignite.agent.testdrive.model.Employee;
+import org.apache.ignite.agent.testdrive.model.EmployeeKey;
+import org.apache.ignite.agent.testdrive.model.Parking;
+import org.apache.ignite.agent.testdrive.model.ParkingKey;
+import org.apache.ignite.cache.CacheTypeMetadata;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.configuration.IgniteConfiguration;
+import org.apache.ignite.internal.IgniteEx;
+import org.apache.ignite.internal.IgniteNodeAttributes;
+import org.apache.ignite.internal.util.typedef.F;
+import org.apache.ignite.lang.IgniteBiTuple;
+import org.apache.ignite.logger.NullLogger;
+import org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi;
+import org.apache.ignite.spi.discovery.tcp.ipfinder.vm.TcpDiscoveryVmIpFinder;
+
+/**
+ * Test drive for SQL.
+ *
+ * Cache will be created and populated with data to query.
+ */
+public class AgentSqlTestDrive {
+    /** */
+    private static final Logger log = Logger.getLogger(AgentMetadataTestDrive.class.getName());
+
+    /** */
+    private static final AtomicBoolean initLatch = new AtomicBoolean();
+
+    /** */
+    private static final String EMPLOYEE_CACHE_NAME = "test-drive-employee";
+
+    /** */
+    private static final String CAR_CACHE_NAME = "test-drive-car";
+
+    /** */
+    private static final Random rnd = new Random();
+
+    /** Countries count. */
+    private static final int CNTR_CNT = 10;
+
+    /** Departments count */
+    private static final int DEP_CNT = 100;
+
+    /** Employees count. */
+    private static final int EMPL_CNT = 1000;
+
+    /** Countries count. */
+    private static final int CAR_CNT = 100;
+
+    /** Departments count */
+    private static final int PARK_CNT = 10;
+
+    /**
+     * Configure cacheEmployee.
+     *
+     * @param name Cache name.
+     */
+    private static <K, V> CacheConfiguration<K, V> cacheEmployee(String name) {
+        CacheConfiguration<K, V> ccfg = new CacheConfiguration<>(name);
+
+        // Configure cacheEmployee types.
+        Collection<CacheTypeMetadata> meta = new ArrayList<>();
+
+        // COUNTRY.
+        CacheTypeMetadata type = new CacheTypeMetadata();
+
+        meta.add(type);
+
+        type.setKeyType(CountryKey.class.getName());
+        type.setValueType(Country.class.getName());
+
+        // Query fields for COUNTRY.
+        Map<String, Class<?>> qryFlds = new LinkedHashMap<>();
+
+        qryFlds.put("id", int.class);
+        qryFlds.put("countryName", String.class);
+
+        type.setQueryFields(qryFlds);
+
+        // Ascending fields for COUNTRY.
+        Map<String, Class<?>> ascFlds = new LinkedHashMap<>();
+
+        ascFlds.put("id", int.class);
+
+        type.setAscendingFields(ascFlds);
+
+        ccfg.setTypeMetadata(meta);
+
+        // DEPARTMENT.
+        type = new CacheTypeMetadata();
+
+        meta.add(type);
+
+        type.setKeyType(DepartmentKey.class.getName());
+        type.setValueType(Department.class.getName());
+
+        // Query fields for DEPARTMENT.
+        qryFlds = new LinkedHashMap<>();
+
+        qryFlds.put("departmentId", int.class);
+        qryFlds.put("departmentName", String.class);
+        qryFlds.put("countryId", Integer.class);
+        qryFlds.put("managerId", Integer.class);
+
+        type.setQueryFields(qryFlds);
+
+        // Ascending fields for DEPARTMENT.
+        ascFlds = new LinkedHashMap<>();
+
+        ascFlds.put("departmentId", int.class);
+
+        type.setAscendingFields(ascFlds);
+
+        ccfg.setTypeMetadata(meta);
+
+        // EMPLOYEE.
+        type = new CacheTypeMetadata();
+
+        meta.add(type);
+
+        type.setKeyType(EmployeeKey.class.getName());
+        type.setValueType(Employee.class.getName());
+
+        // Query fields for EMPLOYEE.
+        qryFlds = new LinkedHashMap<>();
+
+        qryFlds.put("employeeId", int.class);
+        qryFlds.put("firstName", String.class);
+        qryFlds.put("lastName", String.class);
+        qryFlds.put("email", String.class);
+        qryFlds.put("phoneNumber", String.class);
+        qryFlds.put("hireDate", java.sql.Date.class);
+        qryFlds.put("job", String.class);
+        qryFlds.put("salary", Double.class);
+        qryFlds.put("managerId", Integer.class);
+        qryFlds.put("departmentId", Integer.class);
+
+        type.setQueryFields(qryFlds);
+
+        // Ascending fields for EMPLOYEE.
+        ascFlds = new LinkedHashMap<>();
+
+        ascFlds.put("employeeId", int.class);
+
+        type.setAscendingFields(ascFlds);
+
+        // Desc fields for EMPLOYEE.
+        Map<String, Class<?>> descFlds = new LinkedHashMap<>();
+
+        descFlds.put("salary", Double.class);
+
+        type.setDescendingFields(descFlds);
+
+        // Groups for EMPLOYEE.
+        Map<String, LinkedHashMap<String, IgniteBiTuple<Class<?>, Boolean>>> grps = new LinkedHashMap<>();
+
+        LinkedHashMap<String, IgniteBiTuple<Class<?>, Boolean>> grpItems = new LinkedHashMap<>();
+
+        grpItems.put("firstName", new IgniteBiTuple<Class<?>, Boolean>(String.class, false));
+        grpItems.put("lastName", new IgniteBiTuple<Class<?>, Boolean>(String.class, true));
+
+        grps.put("EMP_NAMES", grpItems);
+
+        type.setGroups(grps);
+
+        ccfg.setTypeMetadata(meta);
+
+        return ccfg;
+    }
+
+    /**
+     * Configure cacheEmployee.
+     *
+     * @param name Cache name.
+     */
+    private static <K, V> CacheConfiguration<K, V> cacheCar(String name) {
+        CacheConfiguration<K, V> ccfg = new CacheConfiguration<>(name);
+
+        // Configure cacheEmployee types.
+        Collection<CacheTypeMetadata> meta = new ArrayList<>();
+
+        // CAR.
+        CacheTypeMetadata type = new CacheTypeMetadata();
+
+        meta.add(type);
+
+        type.setKeyType(CarKey.class.getName());
+        type.setValueType(Car.class.getName());
+
+        // Query fields for CAR.
+        Map<String, Class<?>> qryFlds = new LinkedHashMap<>();
+
+        qryFlds.put("carId", int.class);
+        qryFlds.put("parkingId", int.class);
+        qryFlds.put("carName", String.class);
+
+        type.setQueryFields(qryFlds);
+
+        // Ascending fields for CAR.
+        Map<String, Class<?>> ascFlds = new LinkedHashMap<>();
+
+        ascFlds.put("carId", int.class);
+
+        type.setAscendingFields(ascFlds);
+
+        ccfg.setTypeMetadata(meta);
+
+        // PARKING.
+        type = new CacheTypeMetadata();
+
+        meta.add(type);
+
+        type.setKeyType(ParkingKey.class.getName());
+        type.setValueType(Parking.class.getName());
+
+        // Query fields for PARKING.
+        qryFlds = new LinkedHashMap<>();
+
+        qryFlds.put("parkingId", int.class);
+        qryFlds.put("parkingName", String.class);
+
+        type.setQueryFields(qryFlds);
+
+        // Ascending fields for PARKING.
+        ascFlds = new LinkedHashMap<>();
+
+        ascFlds.put("parkingId", int.class);
+
+        type.setAscendingFields(ascFlds);
+
+        ccfg.setTypeMetadata(meta);
+
+        return ccfg;
+    }
+
+    /**
+     * @param val Value to round.
+     * @param places Numbers after point.
+     * @return Rounded value;
+     */
+    private static double round(double val, int places) {
+        if (places < 0)
+            throw new IllegalArgumentException();
+
+        long factor = (long) Math.pow(10, places);
+
+        val *= factor;
+
+        long tmp = Math.round(val);
+
+        return (double) tmp / factor;
+    }
+
+    /**
+     * @param ignite Ignite.
+     * @param name Cache name.
+     */
+    private static void populateCacheEmployee(Ignite ignite, String name) {
+        log.log(Level.FINE, "TEST-DRIVE-SQL: Start population cache: '" + name + "' with data...");
+
+        IgniteCache<CountryKey, Country> cacheCountry = ignite.cache(name);
+
+        for (int i = 0; i < CNTR_CNT; i++)
+            cacheCountry.put(new CountryKey(i), new Country(i, "State " + (i + 1)));
+
+        IgniteCache<DepartmentKey, Department> cacheDepartment = ignite.cache(name);
+
+        for (int i = 0; i < DEP_CNT; i++) {
+            Integer mgrId = (i == 0 || rnd.nextBoolean()) ? null : rnd.nextInt(i);
+
+            cacheDepartment.put(new DepartmentKey(i),
+                new Department(i, "Department " + (i + 1), rnd.nextInt(CNTR_CNT), mgrId));
+        }
+
+        IgniteCache<EmployeeKey, Employee> cacheEmployee = ignite.cache(name);
+
+        long off = java.sql.Date.valueOf("2007-01-01").getTime();
+
+        long end = java.sql.Date.valueOf("2016-01-01").getTime();
+
+        long diff = end - off + 1;
+
+        for (int i = 0; i < EMPL_CNT; i++) {
+            Integer mgrId = (i == 0 || rnd.nextBoolean()) ? null : rnd.nextInt(i);
+
+            double r = rnd.nextDouble();
+
+            cacheEmployee.put(new EmployeeKey(i),
+                new Employee(i, "first name " + (i + 1), "last name " + (i + 1), "email " + (i + 1),
+                    "phone number " + (i + 1), new java.sql.Date(off + (long)(r * diff)), "job " + (i + 1),
+                    round(r * 5000, 2) , mgrId, rnd.nextInt(DEP_CNT)));
+        }
+
+        log.log(Level.FINE, "TEST-DRIVE-SQL: Finished population cache: '" + name + "' with data.");
+    }
+
+    /**
+     * @param ignite Ignite.
+     * @param name Cache name.
+     */
+    private static void populateCacheCar(Ignite ignite, String name) {
+        log.log(Level.FINE, "TEST-DRIVE-SQL: Start population cache: '" + name + "' with data...");
+
+        IgniteCache<ParkingKey, Parking> cacheParking = ignite.cache(name);
+
+        for (int i = 0; i < PARK_CNT; i++)
+            cacheParking.put(new ParkingKey(i), new Parking(i, "Parking " + (i + 1)));
+
+        IgniteCache<CarKey, Car> cacheDepartment = ignite.cache(name);
+
+        for (int i = 0; i < CAR_CNT; i++)
+            cacheDepartment.put(new CarKey(i), new Car(i, rnd.nextInt(PARK_CNT), "Car " + (i + 1)));
+
+
+        log.log(Level.FINE, "TEST-DRIVE-SQL: Finished population cache: '" + name + "' with data.");
+    }
+
+    /**
+     * Start ignite node with cacheEmployee and populate it with data.
+     */
+    public static void testDrive(AgentConfiguration acfg) {
+        if (initLatch.compareAndSet(false, true)) {
+            log.log(Level.INFO, "TEST-DRIVE-SQL: Starting embedded node for sql test-drive...");
+
+            try {
+                IgniteConfiguration cfg = new IgniteConfiguration();
+
+                cfg.setLocalHost("127.0.0.1");
+
+                cfg.setMetricsLogFrequency(0);
+
+                cfg.setGridLogger(new NullLogger());
+
+                // Configure discovery SPI.
+                TcpDiscoverySpi discoSpi = new TcpDiscoverySpi();
+
+                TcpDiscoveryVmIpFinder ipFinder = new TcpDiscoveryVmIpFinder();
+
+                ipFinder.setAddresses(Collections.singleton("127.0.0.1:47500..47501"));
+
+                discoSpi.setIpFinder(ipFinder);
+
+                cfg.setDiscoverySpi(discoSpi);
+
+                cfg.setCacheConfiguration(cacheEmployee(EMPLOYEE_CACHE_NAME), cacheCar(CAR_CACHE_NAME));
+
+                log.log(Level.FINE, "TEST-DRIVE-SQL: Start embedded node with indexed enabled caches...");
+
+                IgniteEx ignite = (IgniteEx)Ignition.start(cfg);
+
+                String host = ((Collection<String>)
+                    ignite.localNode().attribute(IgniteNodeAttributes.ATTR_REST_JETTY_ADDRS)).iterator().next();
+
+                Integer port = ignite.localNode().attribute(IgniteNodeAttributes.ATTR_REST_JETTY_PORT);
+
+                if (F.isEmpty(host) || port == null) {
+                    log.log(Level.SEVERE, "TEST-DRIVE-SQL: Failed to start embedded node with rest!");
+
+                    return;
+                }
+
+                acfg.nodeUri(String.format("http://%s:%d", "0.0.0.0".equals(host) ? "127.0.0.1" : host, port));
+
+                log.log(Level.INFO, "TEST-DRIVE-SQL: Embedded node for sql test-drive successfully started");
+
+                populateCacheEmployee(ignite, EMPLOYEE_CACHE_NAME);
+
+                populateCacheCar(ignite, CAR_CACHE_NAME);
+            }
+            catch (Exception e) {
+                log.log(Level.SEVERE, "TEST-DRIVE-SQL: Failed to start embedded node for sql test-drive!", e);
+            }
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Car.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Car.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Car.java
new file mode 100644
index 0000000..04e3ee6
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Car.java
@@ -0,0 +1,157 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * Car definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class Car implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for carId. */
+    private int carId;
+
+    /** Value for parkingId. */
+    private int parkingId;
+
+    /** Value for carName. */
+    private String carName;
+
+    /**
+     * Empty constructor.
+     */
+    public Car() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public Car(
+        int carId,
+        int parkingId,
+        String carName
+    ) {
+        this.carId = carId;
+        this.parkingId = parkingId;
+        this.carName = carName;
+    }
+
+    /**
+     * Gets carId.
+     *
+     * @return Value for carId.
+     */
+    public int getCarId() {
+        return carId;
+    }
+
+    /**
+     * Sets carId.
+     *
+     * @param carId New value for carId.
+     */
+    public void setCarId(int carId) {
+        this.carId = carId;
+    }
+
+    /**
+     * Gets parkingId.
+     *
+     * @return Value for parkingId.
+     */
+    public int getParkingId() {
+        return parkingId;
+    }
+
+    /**
+     * Sets parkingId.
+     *
+     * @param parkingId New value for parkingId.
+     */
+    public void setParkingId(int parkingId) {
+        this.parkingId = parkingId;
+    }
+
+    /**
+     * Gets carName.
+     *
+     * @return Value for carName.
+     */
+    public String getCarName() {
+        return carName;
+    }
+
+    /**
+     * Sets carName.
+     *
+     * @param carName New value for carName.
+     */
+    public void setCarName(String carName) {
+        this.carName = carName;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof Car))
+            return false;
+
+        Car that = (Car)o;
+
+        if (carId != that.carId)
+            return false;
+
+        if (parkingId != that.parkingId)
+            return false;
+
+        if (carName != null ? !carName.equals(that.carName) : that.carName != null)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = carId;
+
+        res = 31 * res + parkingId;
+
+        res = 31 * res + (carName != null ? carName.hashCode() : 0);
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "Car [carId=" + carId +
+            ", parkingId=" + parkingId +
+            ", carName=" + carName +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CarKey.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CarKey.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CarKey.java
new file mode 100644
index 0000000..063e6c2
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CarKey.java
@@ -0,0 +1,99 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * CarKey definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class CarKey implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for carId. */
+    private int carId;
+
+    /**
+     * Empty constructor.
+     */
+    public CarKey() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public CarKey(
+        int carId
+    ) {
+        this.carId = carId;
+    }
+
+    /**
+     * Gets carId.
+     *
+     * @return Value for carId.
+     */
+    public int getCarId() {
+        return carId;
+    }
+
+    /**
+     * Sets carId.
+     *
+     * @param carId New value for carId.
+     */
+    public void setCarId(int carId) {
+        this.carId = carId;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof CarKey))
+            return false;
+
+        CarKey that = (CarKey)o;
+
+        if (carId != that.carId)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = carId;
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "CarKey [carId=" + carId +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Country.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Country.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Country.java
new file mode 100644
index 0000000..edead2f
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Country.java
@@ -0,0 +1,128 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * Country definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class Country implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for id. */
+    private int id;
+
+    /** Value for countryName. */
+    private String countryName;
+
+    /**
+     * Empty constructor.
+     */
+    public Country() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public Country(
+        int id,
+        String countryName
+    ) {
+        this.id = id;
+        this.countryName = countryName;
+    }
+
+    /**
+     * Gets id.
+     *
+     * @return Value for id.
+     */
+    public int getId() {
+        return id;
+    }
+
+    /**
+     * Sets id.
+     *
+     * @param id New value for id.
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+
+    /**
+     * Gets countryName.
+     *
+     * @return Value for countryName.
+     */
+    public String getCountryName() {
+        return countryName;
+    }
+
+    /**
+     * Sets countryName.
+     *
+     * @param countryName New value for countryName.
+     */
+    public void setCountryName(String countryName) {
+        this.countryName = countryName;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof Country))
+            return false;
+
+        Country that = (Country)o;
+
+        if (id != that.id)
+            return false;
+
+        if (countryName != null ? !countryName.equals(that.countryName) : that.countryName != null)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = id;
+
+        res = 31 * res + (countryName != null ? countryName.hashCode() : 0);
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "Country [id=" + id +
+            ", countryName=" + countryName +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CountryKey.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CountryKey.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CountryKey.java
new file mode 100644
index 0000000..f3f3761
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/CountryKey.java
@@ -0,0 +1,99 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * CountryKey definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class CountryKey implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for id. */
+    private int id;
+
+    /**
+     * Empty constructor.
+     */
+    public CountryKey() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public CountryKey(
+        int id
+    ) {
+        this.id = id;
+    }
+
+    /**
+     * Gets id.
+     *
+     * @return Value for id.
+     */
+    public int getId() {
+        return id;
+    }
+
+    /**
+     * Sets id.
+     *
+     * @param id New value for id.
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof CountryKey))
+            return false;
+
+        CountryKey that = (CountryKey)o;
+
+        if (id != that.id)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = id;
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "CountryKey [id=" + id +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Department.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Department.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Department.java
new file mode 100644
index 0000000..fb87d72
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Department.java
@@ -0,0 +1,186 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * Department definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class Department implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for departmentId. */
+    private int departmentId;
+
+    /** Value for departmentName. */
+    private String departmentName;
+
+    /** Value for countryId. */
+    private Integer countryId;
+
+    /** Value for managerId. */
+    private Integer managerId;
+
+    /**
+     * Empty constructor.
+     */
+    public Department() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public Department(
+        int departmentId,
+        String departmentName,
+        Integer countryId,
+        Integer managerId
+    ) {
+        this.departmentId = departmentId;
+        this.departmentName = departmentName;
+        this.countryId = countryId;
+        this.managerId = managerId;
+    }
+
+    /**
+     * Gets departmentId.
+     *
+     * @return Value for departmentId.
+     */
+    public int getDepartmentId() {
+        return departmentId;
+    }
+
+    /**
+     * Sets departmentId.
+     *
+     * @param departmentId New value for departmentId.
+     */
+    public void setDepartmentId(int departmentId) {
+        this.departmentId = departmentId;
+    }
+
+    /**
+     * Gets departmentName.
+     *
+     * @return Value for departmentName.
+     */
+    public String getDepartmentName() {
+        return departmentName;
+    }
+
+    /**
+     * Sets departmentName.
+     *
+     * @param departmentName New value for departmentName.
+     */
+    public void setDepartmentName(String departmentName) {
+        this.departmentName = departmentName;
+    }
+
+    /**
+     * Gets countryId.
+     *
+     * @return Value for countryId.
+     */
+    public Integer getCountryId() {
+        return countryId;
+    }
+
+    /**
+     * Sets countryId.
+     *
+     * @param countryId New value for countryId.
+     */
+    public void setCountryId(Integer countryId) {
+        this.countryId = countryId;
+    }
+
+    /**
+     * Gets managerId.
+     *
+     * @return Value for managerId.
+     */
+    public Integer getManagerId() {
+        return managerId;
+    }
+
+    /**
+     * Sets managerId.
+     *
+     * @param managerId New value for managerId.
+     */
+    public void setManagerId(Integer managerId) {
+        this.managerId = managerId;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof Department))
+            return false;
+
+        Department that = (Department)o;
+
+        if (departmentId != that.departmentId)
+            return false;
+
+        if (departmentName != null ? !departmentName.equals(that.departmentName) : that.departmentName != null)
+            return false;
+
+        if (countryId != null ? !countryId.equals(that.countryId) : that.countryId != null)
+            return false;
+
+        if (managerId != null ? !managerId.equals(that.managerId) : that.managerId != null)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = departmentId;
+
+        res = 31 * res + (departmentName != null ? departmentName.hashCode() : 0);
+
+        res = 31 * res + (countryId != null ? countryId.hashCode() : 0);
+
+        res = 31 * res + (managerId != null ? managerId.hashCode() : 0);
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "Department [departmentId=" + departmentId +
+            ", departmentName=" + departmentName +
+            ", countryId=" + countryId +
+            ", managerId=" + managerId +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/DepartmentKey.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/DepartmentKey.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/DepartmentKey.java
new file mode 100644
index 0000000..a2d33a4
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/DepartmentKey.java
@@ -0,0 +1,99 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * DepartmentKey definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class DepartmentKey implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for departmentId. */
+    private int departmentId;
+
+    /**
+     * Empty constructor.
+     */
+    public DepartmentKey() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public DepartmentKey(
+        int departmentId
+    ) {
+        this.departmentId = departmentId;
+    }
+
+    /**
+     * Gets departmentId.
+     *
+     * @return Value for departmentId.
+     */
+    public int getDepartmentId() {
+        return departmentId;
+    }
+
+    /**
+     * Sets departmentId.
+     *
+     * @param departmentId New value for departmentId.
+     */
+    public void setDepartmentId(int departmentId) {
+        this.departmentId = departmentId;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof DepartmentKey))
+            return false;
+
+        DepartmentKey that = (DepartmentKey)o;
+
+        if (departmentId != that.departmentId)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = departmentId;
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "DepartmentKey [departmentId=" + departmentId +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Employee.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Employee.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Employee.java
new file mode 100644
index 0000000..39fc2b3
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Employee.java
@@ -0,0 +1,360 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * Employee definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class Employee implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for employeeId. */
+    private int employeeId;
+
+    /** Value for firstName. */
+    private String firstName;
+
+    /** Value for lastName. */
+    private String lastName;
+
+    /** Value for email. */
+    private String email;
+
+    /** Value for phoneNumber. */
+    private String phoneNumber;
+
+    /** Value for hireDate. */
+    private java.sql.Date hireDate;
+
+    /** Value for job. */
+    private String job;
+
+    /** Value for salary. */
+    private Double salary;
+
+    /** Value for managerId. */
+    private Integer managerId;
+
+    /** Value for departmentId. */
+    private Integer departmentId;
+
+    /**
+     * Empty constructor.
+     */
+    public Employee() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public Employee(
+        int employeeId,
+        String firstName,
+        String lastName,
+        String email,
+        String phoneNumber,
+        java.sql.Date hireDate,
+        String job,
+        Double salary,
+        Integer managerId,
+        Integer departmentId
+    ) {
+        this.employeeId = employeeId;
+        this.firstName = firstName;
+        this.lastName = lastName;
+        this.email = email;
+        this.phoneNumber = phoneNumber;
+        this.hireDate = hireDate;
+        this.job = job;
+        this.salary = salary;
+        this.managerId = managerId;
+        this.departmentId = departmentId;
+    }
+
+    /**
+     * Gets employeeId.
+     *
+     * @return Value for employeeId.
+     */
+    public int getEmployeeId() {
+        return employeeId;
+    }
+
+    /**
+     * Sets employeeId.
+     *
+     * @param employeeId New value for employeeId.
+     */
+    public void setEmployeeId(int employeeId) {
+        this.employeeId = employeeId;
+    }
+
+    /**
+     * Gets firstName.
+     *
+     * @return Value for firstName.
+     */
+    public String getFirstName() {
+        return firstName;
+    }
+
+    /**
+     * Sets firstName.
+     *
+     * @param firstName New value for firstName.
+     */
+    public void setFirstName(String firstName) {
+        this.firstName = firstName;
+    }
+
+    /**
+     * Gets lastName.
+     *
+     * @return Value for lastName.
+     */
+    public String getLastName() {
+        return lastName;
+    }
+
+    /**
+     * Sets lastName.
+     *
+     * @param lastName New value for lastName.
+     */
+    public void setLastName(String lastName) {
+        this.lastName = lastName;
+    }
+
+    /**
+     * Gets email.
+     *
+     * @return Value for email.
+     */
+    public String getEmail() {
+        return email;
+    }
+
+    /**
+     * Sets email.
+     *
+     * @param email New value for email.
+     */
+    public void setEmail(String email) {
+        this.email = email;
+    }
+
+    /**
+     * Gets phoneNumber.
+     *
+     * @return Value for phoneNumber.
+     */
+    public String getPhoneNumber() {
+        return phoneNumber;
+    }
+
+    /**
+     * Sets phoneNumber.
+     *
+     * @param phoneNumber New value for phoneNumber.
+     */
+    public void setPhoneNumber(String phoneNumber) {
+        this.phoneNumber = phoneNumber;
+    }
+
+    /**
+     * Gets hireDate.
+     *
+     * @return Value for hireDate.
+     */
+    public java.sql.Date getHireDate() {
+        return hireDate;
+    }
+
+    /**
+     * Sets hireDate.
+     *
+     * @param hireDate New value for hireDate.
+     */
+    public void setHireDate(java.sql.Date hireDate) {
+        this.hireDate = hireDate;
+    }
+
+    /**
+     * Gets job.
+     *
+     * @return Value for job.
+     */
+    public String getJob() {
+        return job;
+    }
+
+    /**
+     * Sets job.
+     *
+     * @param job New value for job.
+     */
+    public void setJob(String job) {
+        this.job = job;
+    }
+
+    /**
+     * Gets salary.
+     *
+     * @return Value for salary.
+     */
+    public Double getSalary() {
+        return salary;
+    }
+
+    /**
+     * Sets salary.
+     *
+     * @param salary New value for salary.
+     */
+    public void setSalary(Double salary) {
+        this.salary = salary;
+    }
+
+    /**
+     * Gets managerId.
+     *
+     * @return Value for managerId.
+     */
+    public Integer getManagerId() {
+        return managerId;
+    }
+
+    /**
+     * Sets managerId.
+     *
+     * @param managerId New value for managerId.
+     */
+    public void setManagerId(Integer managerId) {
+        this.managerId = managerId;
+    }
+
+    /**
+     * Gets departmentId.
+     *
+     * @return Value for departmentId.
+     */
+    public Integer getDepartmentId() {
+        return departmentId;
+    }
+
+    /**
+     * Sets departmentId.
+     *
+     * @param departmentId New value for departmentId.
+     */
+    public void setDepartmentId(Integer departmentId) {
+        this.departmentId = departmentId;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof Employee))
+            return false;
+
+        Employee that = (Employee)o;
+
+        if (employeeId != that.employeeId)
+            return false;
+
+        if (firstName != null ? !firstName.equals(that.firstName) : that.firstName != null)
+            return false;
+
+        if (lastName != null ? !lastName.equals(that.lastName) : that.lastName != null)
+            return false;
+
+        if (email != null ? !email.equals(that.email) : that.email != null)
+            return false;
+
+        if (phoneNumber != null ? !phoneNumber.equals(that.phoneNumber) : that.phoneNumber != null)
+            return false;
+
+        if (hireDate != null ? !hireDate.equals(that.hireDate) : that.hireDate != null)
+            return false;
+
+        if (job != null ? !job.equals(that.job) : that.job != null)
+            return false;
+
+        if (salary != null ? !salary.equals(that.salary) : that.salary != null)
+            return false;
+
+        if (managerId != null ? !managerId.equals(that.managerId) : that.managerId != null)
+            return false;
+
+        if (departmentId != null ? !departmentId.equals(that.departmentId) : that.departmentId != null)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = employeeId;
+
+        res = 31 * res + (firstName != null ? firstName.hashCode() : 0);
+
+        res = 31 * res + (lastName != null ? lastName.hashCode() : 0);
+
+        res = 31 * res + (email != null ? email.hashCode() : 0);
+
+        res = 31 * res + (phoneNumber != null ? phoneNumber.hashCode() : 0);
+
+        res = 31 * res + (hireDate != null ? hireDate.hashCode() : 0);
+
+        res = 31 * res + (job != null ? job.hashCode() : 0);
+
+        res = 31 * res + (salary != null ? salary.hashCode() : 0);
+
+        res = 31 * res + (managerId != null ? managerId.hashCode() : 0);
+
+        res = 31 * res + (departmentId != null ? departmentId.hashCode() : 0);
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "Employee [employeeId=" + employeeId +
+            ", firstName=" + firstName +
+            ", lastName=" + lastName +
+            ", email=" + email +
+            ", phoneNumber=" + phoneNumber +
+            ", hireDate=" + hireDate +
+            ", job=" + job +
+            ", salary=" + salary +
+            ", managerId=" + managerId +
+            ", departmentId=" + departmentId +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/EmployeeKey.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/EmployeeKey.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/EmployeeKey.java
new file mode 100644
index 0000000..160606a
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/EmployeeKey.java
@@ -0,0 +1,99 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * EmployeeKey definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class EmployeeKey implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for employeeId. */
+    private int employeeId;
+
+    /**
+     * Empty constructor.
+     */
+    public EmployeeKey() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public EmployeeKey(
+        int employeeId
+    ) {
+        this.employeeId = employeeId;
+    }
+
+    /**
+     * Gets employeeId.
+     *
+     * @return Value for employeeId.
+     */
+    public int getEmployeeId() {
+        return employeeId;
+    }
+
+    /**
+     * Sets employeeId.
+     *
+     * @param employeeId New value for employeeId.
+     */
+    public void setEmployeeId(int employeeId) {
+        this.employeeId = employeeId;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof EmployeeKey))
+            return false;
+
+        EmployeeKey that = (EmployeeKey)o;
+
+        if (employeeId != that.employeeId)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = employeeId;
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "EmployeeKey [employeeId=" + employeeId +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Parking.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Parking.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Parking.java
new file mode 100644
index 0000000..145cb6d
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/Parking.java
@@ -0,0 +1,128 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * Parking definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class Parking implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for parkingId. */
+    private int parkingId;
+
+    /** Value for parkingName. */
+    private String parkingName;
+
+    /**
+     * Empty constructor.
+     */
+    public Parking() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public Parking(
+        int parkingId,
+        String parkingName
+    ) {
+        this.parkingId = parkingId;
+        this.parkingName = parkingName;
+    }
+
+    /**
+     * Gets parkingId.
+     *
+     * @return Value for parkingId.
+     */
+    public int getParkingId() {
+        return parkingId;
+    }
+
+    /**
+     * Sets parkingId.
+     *
+     * @param parkingId New value for parkingId.
+     */
+    public void setParkingId(int parkingId) {
+        this.parkingId = parkingId;
+    }
+
+    /**
+     * Gets parkingName.
+     *
+     * @return Value for parkingName.
+     */
+    public String getParkingName() {
+        return parkingName;
+    }
+
+    /**
+     * Sets parkingName.
+     *
+     * @param parkingName New value for parkingName.
+     */
+    public void setParkingName(String parkingName) {
+        this.parkingName = parkingName;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof Parking))
+            return false;
+
+        Parking that = (Parking)o;
+
+        if (parkingId != that.parkingId)
+            return false;
+
+        if (parkingName != null ? !parkingName.equals(that.parkingName) : that.parkingName != null)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = parkingId;
+
+        res = 31 * res + (parkingName != null ? parkingName.hashCode() : 0);
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "Parking [parkingId=" + parkingId +
+            ", parkingName=" + parkingName +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/ParkingKey.java
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/ParkingKey.java b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/ParkingKey.java
new file mode 100644
index 0000000..5875cd1
--- /dev/null
+++ b/modules/control-center-agent/src/main/java/org/apache/ignite/agent/testdrive/model/ParkingKey.java
@@ -0,0 +1,99 @@
+/*
+ *
+ *  * Licensed to the Apache Software Foundation (ASF) under one or more
+ *  * contributor license agreements.  See the NOTICE file distributed with
+ *  * this work for additional information regarding copyright ownership.
+ *  * The ASF licenses this file to You under the Apache License, Version 2.0
+ *  * (the "License"); you may not use this file except in compliance with
+ *  * the License.  You may obtain a copy of the License at
+ *  *
+ *  *      http://www.apache.org/licenses/LICENSE-2.0
+ *  *
+ *  * Unless required by applicable law or agreed to in writing, software
+ *  * distributed under the License is distributed on an "AS IS" BASIS,
+ *  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  * See the License for the specific language governing permissions and
+ *  * limitations under the License.
+ *
+ */
+
+package org.apache.ignite.agent.testdrive.model;
+
+import java.io.Serializable;
+
+/**
+ * ParkingKey definition.
+ *
+ * Code generated by Apache Ignite Schema Import utility: 08/24/2015.
+ */
+public class ParkingKey implements Serializable {
+    /** */
+    private static final long serialVersionUID = 0L;
+
+    /** Value for parkingId. */
+    private int parkingId;
+
+    /**
+     * Empty constructor.
+     */
+    public ParkingKey() {
+        // No-op.
+    }
+
+    /**
+     * Full constructor.
+     */
+    public ParkingKey(
+        int parkingId
+    ) {
+        this.parkingId = parkingId;
+    }
+
+    /**
+     * Gets parkingId.
+     *
+     * @return Value for parkingId.
+     */
+    public int getParkingId() {
+        return parkingId;
+    }
+
+    /**
+     * Sets parkingId.
+     *
+     * @param parkingId New value for parkingId.
+     */
+    public void setParkingId(int parkingId) {
+        this.parkingId = parkingId;
+    }
+
+    /** {@inheritDoc} */
+    @Override public boolean equals(Object o) {
+        if (this == o)
+            return true;
+
+        if (!(o instanceof ParkingKey))
+            return false;
+
+        ParkingKey that = (ParkingKey)o;
+
+        if (parkingId != that.parkingId)
+            return false;
+
+        return true;
+    }
+
+    /** {@inheritDoc} */
+    @Override public int hashCode() {
+        int res = parkingId;
+
+        return res;
+    }
+
+    /** {@inheritDoc} */
+    @Override public String toString() {
+        return "ParkingKey [parkingId=" + parkingId +
+            "]";
+    }
+}
+

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/src/main/resources/logging.properties
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/src/main/resources/logging.properties b/modules/control-center-agent/src/main/resources/logging.properties
new file mode 100644
index 0000000..44115f8
--- /dev/null
+++ b/modules/control-center-agent/src/main/resources/logging.properties
@@ -0,0 +1,24 @@
+#
+# /*
+#  * Licensed to the Apache Software Foundation (ASF) under one or more
+#  * contributor license agreements.  See the NOTICE file distributed with
+#  * this work for additional information regarding copyright ownership.
+#  * The ASF licenses this file to You under the Apache License, Version 2.0
+#  * (the "License"); you may not use this file except in compliance with
+#  * the License.  You may obtain a copy of the License at
+#  *
+#  *      http://www.apache.org/licenses/LICENSE-2.0
+#  *
+#  * Unless required by applicable law or agreed to in writing, software
+#  * distributed under the License is distributed on an "AS IS" BASIS,
+#  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#  * See the License for the specific language governing permissions and
+#  * limitations under the License.
+#  */
+#
+
+handlers =java.util.logging.ConsoleHandler
+.level=FINE
+java.util.logging.ConsoleHandler.level=INFO
+java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
+java.util.logging.SimpleFormatter.format=%1$tl:%1$tM:%1$tS %1$Tp %4$s: %5$s%n

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/test-drive/README.txt
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/test-drive/README.txt b/modules/control-center-agent/test-drive/README.txt
new file mode 100644
index 0000000..723ee3a
--- /dev/null
+++ b/modules/control-center-agent/test-drive/README.txt
@@ -0,0 +1,4 @@
+Ignite Web Agent
+======================================
+
+This is folder for test-drive files.

http://git-wip-us.apache.org/repos/asf/ignite/blob/81962c43/modules/control-center-agent/test-drive/test-drive.sql
----------------------------------------------------------------------
diff --git a/modules/control-center-agent/test-drive/test-drive.sql b/modules/control-center-agent/test-drive/test-drive.sql
new file mode 100644
index 0000000..a7deafa
--- /dev/null
+++ b/modules/control-center-agent/test-drive/test-drive.sql
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+CREATE TABLE COUNTRY (
+    ID           INTEGER NOT NULL PRIMARY KEY,
+    COUNTRY_NAME VARCHAR(100)
+);
+
+CREATE TABLE DEPARTMENT (
+    DEPARTMENT_ID   INTEGER     NOT NULL PRIMARY KEY,
+    DEPARTMENT_NAME VARCHAR(50) NOT NULL,
+    COUNTRY_ID      INTEGER,
+    MANAGER_ID      INTEGER
+);
+
+CREATE TABLE EMPLOYEE (
+    EMPLOYEE_ID   INTEGER     NOT NULL PRIMARY KEY,
+    FIRST_NAME    VARCHAR(20) NOT NULL,
+    LAST_NAME     VARCHAR(30) NOT NULL,
+    EMAIL         VARCHAR(25) NOT NULL,
+    PHONE_NUMBER  VARCHAR(20),
+    HIRE_DATE     DATE        NOT NULL,
+    JOB           VARCHAR(50) NOT NULL,
+    SALARY        DOUBLE,
+    MANAGER_ID    INTEGER,
+    DEPARTMENT_ID INTEGER
+);
+
+CREATE INDEX EMP_SALARY_A ON EMPLOYEE (SALARY ASC);
+CREATE INDEX EMP_SALARY_B ON EMPLOYEE (SALARY DESC);
+CREATE INDEX EMP_NAMES ON EMPLOYEE (FIRST_NAME ASC, LAST_NAME ASC);
+
+CREATE SCHEMA CARS;
+
+CREATE TABLE CARS.PARKING (
+    PARKING_ID   INTEGER     NOT NULL PRIMARY KEY,
+    PARKING_NAME VARCHAR(50) NOT NULL
+);
+
+CREATE TABLE CARS.CAR (
+    CAR_ID     INTEGER     NOT NULL PRIMARY KEY,
+    PARKING_ID INTEGER     NOT NULL,
+    CAR_NAME   VARCHAR(50) NOT NULL
+);


Mime
View raw message