Package org.rhq.server.metrics.migrator.datasources

Examples of org.rhq.server.metrics.migrator.datasources.ExistingPostgresDataBulkExportSource


                return new ScrollableDataSource(config.getEntityManager(), config.getDatabaseType(), query);
            } else {
                if (!config.isExperimentalDataSource()) {
                    return new ScrollableDataSource(config.getEntityManager(), config.getDatabaseType(), query);
                } else {
                    return new ExistingPostgresDataBulkExportSource(config.getEntityManager(), query);
                }
            }
        } else if (Task.Estimate.equals(task)) {
            int limit = CallableMigrationWorker.MAX_RECORDS_TO_LOAD_FROM_SQL
                * (CallableMigrationWorker.NUMBER_OF_BATCHES_FOR_ESTIMATION + 1);

            if (DatabaseType.Oracle.equals(config.getDatabaseType())) {
                return new ScrollableDataSource(config.getEntityManager(), config.getDatabaseType(), query, limit);
            } else {
                if (!config.isExperimentalDataSource()) {
                    return new ScrollableDataSource(config.getEntityManager(), config.getDatabaseType(), query, limit);
                } else {
                    return new ExistingPostgresDataBulkExportSource(config.getEntityManager(), query, limit);
                }
            }
        }

        return new ScrollableDataSource(config.getEntityManager(), config.getDatabaseType(), query);
View Full Code Here


        EntityManager entityManager = null;
        ExistingDataBulkExportSource source = null;
        try {
            entityManagerFactory = createEntityManager();
            entityManager = entityManagerFactory.createEntityManager();
            source = new ExistingPostgresDataBulkExportSource(entityManager,
                "SELECT  schedule_id, time_stamp, value, minvalue, maxvalue FROM RHQ_MEASUREMENT_DATA_NUM_1D");
            StopWatch stopWatch = new StopWatch();
            stopWatch.start();
            source.initialize();
            int rowIndex = 0;
View Full Code Here

        EntityManager entityManager = null;
        ExistingDataBulkExportSource source = null;
        try {
            entityManagerFactory = createEntityManager();
            entityManager = entityManagerFactory.createEntityManager();
            source = new ExistingPostgresDataBulkExportSource(entityManager,
                "SELECT  schedule_id, time_stamp, value, minvalue, maxvalue FROM RHQ_MEASUREMENT_DATA_NUM_1D");
            StopWatch stopWatch = new StopWatch();
            stopWatch.start();
            source.initialize();
            int rowIndex = 0;
View Full Code Here

TOP

Related Classes of org.rhq.server.metrics.migrator.datasources.ExistingPostgresDataBulkExportSource

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.