Package org.jitterbit.integration.database.driver

Examples of org.jitterbit.integration.database.driver.ConnectionParams


    }

    @Override
    protected void runImpl() throws InterruptedException {
        setMessage("Asking the server for column information");
        ConnectionParams connectionParams = dbLocation.getConnectionParams();
        DatabaseInfoProvider provider = DatabaseInfoProviderFactory.createProvider(connectionParams);
        provider.getTableInfo(connectionParams, sourceId, targetId, emptyObjects, callback);
    }
View Full Code Here


    private void submitJob() {
        String sql = sqlSupplier.get();
        if (StringUtils.isEmpty(sql)) {
            Alert.error("Please enter a SQL statement to test.", "No SQL Statement");
        } else {
            ConnectionParams params = dbLocation.getConnectionParams();
            GetManualSqlStatementDetailsJob job = new GetManualSqlStatementDetailsJob(sql, params, sourceId);
            job.setReceiver(new Callback());
            job.submit(waitService, 0);
        }
    }
View Full Code Here

    private ManualSqlStatement downloadStatementDetails() {
        String sql = getSqlStatement();
        if (sql.isEmpty()) {
            return null;
        }
        ConnectionParams params = dbLocation.getConnectionParams();
        GetManualSqlStatementDetailsJob job = new GetManualSqlStatementDetailsJob(sql, params, sourceId);
        job.submit(getWaitService(), 0);
        return job.getDetails();
    }
View Full Code Here

    }

    private String getConnectionStringFromDriver() {
        DriverDescriptor driver = getDriver();
        if (driver != null) {
            ConnectionParams params = getConnectionParams();
            StringBuilder sb = new StringBuilder(driver.getConnectionString(params));
            appendOptionalParameters(sb);
            return sb.toString();
        }
        return null;
View Full Code Here

    /**
     * Creates a <code>ConnectionParams</code> object from this <code>DatabaseLocation</code>.
     */
    public ConnectionParams getConnectionParams() {
        synchronized (getDataLock()) {
            ConnectionParams params = new ConnectionParams();
            params.setServer(getServer())
                  .setPort(getPort())
                  .setDatabase(getDatabase())
                  .setDriverName(getDriverName())
                  .setDriver(getDriver())
                  .setUser(getLogin())
                  .setPassword(getPassword())
                  .setAdditionalParams(getAdditionalConnectionParameters())
                  .setBeginEndQuotes(getBeginEndQuote())
                  .setTransactionIsolationLevel(getTransactionIsolationLevel());
            if (isManualMode()) {
                params.setManualConnectionString(getManualConnectionString());
            }
            return params;
        }
    }
View Full Code Here

        loc.setServer(server);
        loc.setDatabase(db);
        loc.setLogin(user);
        loc.setPassword(password);
        loc.setPort(port);
        ConnectionParams params = loc.getConnectionParams();
        assertEquals(server, params.getServer());
        assertEquals(db, params.getDatabase());
        assertEquals(user, params.getUser());
        assertEquals(password, params.getPassword());
        assertEquals(port, params.getPort());
    }
View Full Code Here

    private boolean shouldRowIdsBeRemovedFromInformixTables(DatabaseStructure dbStruct) {
        return isInformix(dbStruct) && !dbStruct.hasManualSqlStatement() && !dbStruct.getIncludeRowIdInInformixTables();
    }

    private boolean isInformix(DatabaseStructure dbStruct) {
        ConnectionParams params = dbStruct.getConnectionParameters();
        DriverDescriptor driver = params.getDriver();
        return InformixUtils.isInformix(driver);
    }
View Full Code Here

    private boolean checkAutomaticMode(SourceTarget st) {
        try {
            DriverDescriptor driver = dbLocation.getDriver();
            assert (driver != null);
            ConnectionParams params = dbLocation.getConnectionParams();
            driver.checkConnectionParams(params);
            return true;
        } catch (InvalidConnectionParamsException ex) {
            handlePreConnectionError(st, ex);
            return false;
View Full Code Here

        }

        @Override
        protected void runImpl() throws InterruptedException {
            DbObjectsModel model = view.getModel();
            ConnectionParams params = model.getDatabase().getConnectionParams();
            infoProvider.getDatabaseObjects(params, model.getSourceId(), model.getTargetId(), filter, callback);
        }
View Full Code Here

                SourcesTabRow row = getDefinition();
                if (row == null) {
                    throw new ServerDbException("Could not find the deployed definition of the Source with GUID "
                                    + sourceId);
                }
                ConnectionParams params = new ConnectionParams();
                params.setServer(row.get_locator())
                      .setDatabase(row.get_dbname())
                      .setUser(row.get_login())
                      .setPassword(decryptPassword(row.get_password()))
                      .setPort(Port.valueOf(row.get_port()))
                      .setDriverName(row.get_driver())
View Full Code Here

TOP

Related Classes of org.jitterbit.integration.database.driver.ConnectionParams

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.