Package com.linkedin.databus.bootstrap.common

Examples of com.linkedin.databus.bootstrap.common.BootstrapConn


  public BootstrapProcessor(BootstrapServerStaticConfig config,
                            DbusEventsStatisticsCollector curStatsCollector)
      throws InstantiationException, IllegalAccessException, ClassNotFoundException, SQLException, DatabusException
  {
    _curStatsCollector = curStatsCollector;
    BootstrapConn dbConn = new BootstrapConn();
    this.config = config;
    final boolean autoCommit = true;
    dbConn.initBootstrapConn(autoCommit,
                              config.getDb().getBootstrapDBUsername(),
                              config.getDb().getBootstrapDBPassword(),
                              config.getDb().getBootstrapDBHostname(),
                              config.getDb().getBootstrapDBName());
    _dbDao = new BootstrapDBMetaDataDAO(dbConn,
View Full Code Here


    Connection conn = null;

    if (_bootstrapConn == null)
    {
      LOG.info("<<<< Creating Bootstrap Connection!! >>>>");
      _bootstrapConn = new BootstrapConn();
      try
      {
        _bootstrapConn.initBootstrapConn(false,
                                         _bsStaticConfig.getBootstrap().getBootstrapDBUsername(),
                                         _bsStaticConfig.getBootstrap().getBootstrapDBPassword(),
View Full Code Here

    Connection conn = null;

    if (_dbDao == null)
    {
      LOG.info("<<<< Creating Bootstrap Connection!! >>>>");
      BootstrapConn dbConn = new BootstrapConn();
      try
      {
        dbConn.initBootstrapConn(false,
            _config.getBootstrapDBUsername(),
            _config.getBootstrapDBPassword(),
            _config.getBootstrapDBHostname(),
            _config.getBootstrapDBName());
        _dbDao = new BootstrapDBMetaDataDAO(dbConn,
View Full Code Here

    ConfigLoader<BootstrapReadOnlyConfig> configLoad =
        new ConfigLoader<BootstrapReadOnlyConfig>("databus.bootstrap.", cfgBuilder);
    configLoad.loadConfig(cfgProps);

    BootstrapReadOnlyConfig cfg = cfgBuilder.build();
    BootstrapConn conn = new BootstrapConn();
    try
    {
      conn.initBootstrapConn(true, cfg.getBootstrapDBUsername(), cfg.getBootstrapDBPassword(),
                             cfg.getBootstrapDBHostname(), cfg.getBootstrapDBName());
      BootstrapDBMetaDataDAO dao = new BootstrapDBMetaDataDAO(conn,           
                      cfg.getBootstrapDBHostname(),
                      cfg.getBootstrapDBUsername(),
                      cfg.getBootstrapDBPassword(),
                      cfg.getBootstrapDBName(),
                      false);
      switch (cli.getAction())
      {
      case CREATE_LOG_TABLE: dao.createNewLogTable(cli.getSrcId()); break;
      case CREATE_TAB_TABLE: dao.createNewSrcTable(cli.getSrcId()); break;
      default: throw new RuntimeException("unknown action: " + cli.getAction());
      }
    }
    finally
    {
      conn.close();
    }
  }
View Full Code Here

      Connection conn = null;

      if (_dbDao == null)
      {
        LOG.info("<<<< Creating Bootstrap Connection!! >>>>");
        BootstrapConn dbConn = new BootstrapConn();
        try
        {
           dbConn.initBootstrapConn(false,
                                            _config.getBootstrapDBUsername(),
                                            _config.getBootstrapDBPassword(),
                                            _config.getBootstrapDBHostname(),
                                            _config.getBootstrapDBName());
           _dbDao = new BootstrapDBMetaDataDAO(dbConn,           
View Full Code Here

  private BootstrapConn createBstConnection()
          throws InstantiationException, IllegalAccessException, ClassNotFoundException,
                 SQLException
  {
    _log.info("<<<< Creating Bootstrap Connection >>>>");
    BootstrapConn bstConn = new BootstrapConn();
    bstConn.initBootstrapConn(true,
                               _bstConfig.getBootstrapDBUsername(),
                               _bstConfig.getBootstrapDBPassword(),
                               _bstConfig.getBootstrapDBHostname(),
                               _bstConfig.getBootstrapDBName());
    return bstConn;
View Full Code Here

      BootstrapProcessor processor = new BootstrapProcessor(staticServerConfig, null);
      String sourceName = "TestBootstrap.testBootstrapProcessor.events";

      // Create the tables for all the sources before starting up the threads

      BootstrapConn _bootstrapConn = new BootstrapConn();
      boolean autoCommit = true;
      _bootstrapConn.initBootstrapConn(autoCommit,
          staticConfig.getBootstrapDBUsername(),
          staticConfig.getBootstrapDBPassword(),
          staticConfig.getBootstrapDBHostname(),
          staticConfig.getBootstrapDBName());
View Full Code Here

      sources[1] = "TestBootstrap.testBootstrapService.event1";
      sources[2] = "TestBootstrap.testBootstrapService.event2";
      sources[3] = "TestBootstrap.testBootstrapService.event3";

      // Create the tables for all the sources before starting up the threads
      BootstrapConn _bootstrapConn = new BootstrapConn();
      final boolean autoCommit = true;
      _bootstrapConn.initBootstrapConn(autoCommit,
          staticConfig.getBootstrapDBUsername(),
          staticConfig.getBootstrapDBPassword(),
          staticConfig.getBootstrapDBHostname(),
          staticConfig.getBootstrapDBName());
View Full Code Here

    Connection conn = null;

    if (_bootstrapDao == null)
    {
      LOG.info("<<<< Creating Bootstrap Connection!! >>>>");
      BootstrapConn dbConn = new BootstrapConn();
      try
      {
        dbConn.initBootstrapConn(false,
                                 java.sql.Connection.TRANSACTION_READ_UNCOMMITTED,
                                 _config.getBootstrapDBUsername(),
                                 _config.getBootstrapDBPassword(),
                                 _config.getBootstrapDBHostname(),
                                 _config.getBootstrapDBName());
View Full Code Here

      String bootstrapPassword = cmdLineArgs.getOptionValue("dbpassword",
          DEFAULT_BOOTSTRAP_PASSWORD);
      String bootstrapUser = cmdLineArgs.getOptionValue("dbuser",
          DEFAULT_BOOTSTRAP_USER);

      _bsConn = new BootstrapConn();
      _bsConn.initBootstrapConn(false, bootstrapUser, bootstrapPassword,
          bootstrapHost, bootstrapDbName);
      _dbao = new BootstrapDBMetaDataDAO(_bsConn, bootstrapHost, bootstrapUser,
          bootstrapPassword, bootstrapDbName, false);
View Full Code Here

TOP

Related Classes of com.linkedin.databus.bootstrap.common.BootstrapConn

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.