1. 01 5月, 2019 7 次提交
  2. 30 4月, 2019 3 次提交
    • P
      Fix flaky gpcloud S3KeyReaderTest unit test (#7576) · 4ff071cf
      Peifeng Qiu 提交于
      S3KeyReaderTest.MTReadWithUnexpectedFetchDataAtSecondRound is a
      flaky case, related to multithread timing.
      
      The case setup S3KeyReader and try to download in parallel with 2
      chunks(threads). When any of them encounters an error, all thread
      will abort with the shared error.
      
      The case assumed that the first created thread will call fetchData()
      twice before another thread fetch with error. But if the first
      thread is never scheduled to run, the second thread will call
      fetchData() first and sets the shared error. Then the first thread
      continues and will exit at the first call to fetchData(), reporting
      shared error.
      
      Modify the second call to fetchData() to be at most once.
      4ff071cf
    • P
      Recursively create tablespace directories if they do not exist but we need... · 7a09e80d
      Paul Guo 提交于
      Recursively create tablespace directories if they do not exist but we need them when re-redoing some tablespace related xlogs (e.g. database create with a tablespace) on mirror.
      
      It is observed many time that gp_replica_check test fails because some mirror nodes
      can not be brought up before testing recently. The related log looks like this:
      
      2019-04-17 14:52:14.951 CST [23030] FATAL:  could not create directory "pg_tblspc/65546/PG_12_201904072/65547": No such file or directory
      2019-04-17 14:52:14.951 CST [23030] CONTEXT:  WAL redo at 0/3011650 for Database/CREATE: copy dir 1663/1 to 65546/65547
      
      That is because some mirror nodes can not be recovered after previous testing,
      not due to gp_replica_check itself. The root cause is that tablespace recovery
      related. Pengzhou Tang and Hao Wu digged that intially and kindly found a mini
      repro as below.
      
      run on shell:
        rm -rf /tmp/some_isolation2_pg_basebackup_tablespace
        mkdir -p /tmp/some_isolation2_pg_basebackup_tablespace
      
      copy and run the below sql on psql client:
        drop tablespace if exists some_isolation2_pg_basebackup_tablespace;
        create tablespace some_isolation2_pg_basebackup_tablespace location '/tmp/some_isolation2_pg_basebackup_tablespace';
        \!gpstop -ra -M fast;
        drop database if exists some_database_with_tablespace;
        create database some_database_with_tablespace tablespace some_isolation2_pg_basebackup_tablespace;
        drop database some_database_with_tablespace;
        drop tablespace some_isolation2_pg_basebackup_tablespace;
        \!gpstop -ra -M immediate;
      
      The root cause is on mirror after drop database & drop tablespace, 'immediate'
      stop causes the pg_control file not up-to-date with latest redo start lsn (this
      is allowed), when the node restarts, it re-redoes 'create database
      some_database_with_tablespace tablespace
      some_isolation2_pg_basebackup_tablespace' but the tablespace directories have
      been deleted in previous redoing.
      
      The 'could not create directory' error could happen on re-redoing create table
      in a tablespace also. We've seen this case on the ci environment, but that is
      because missing of a get_parent_directory() call in the 'create two parents'
      code block in TablespaceCreateDbspace(). Changing it to a simpler call
      pg_mkdir_p() instead.
      
      Also it seems that the src_path could be missing also in dbase_redo() for the
      example below. For example re-redoing at the alter step since tbs1 directory is
      deleted in later 'drop tablespace tbs1'.
        alter database db1 set tablespace tbs2;
        drop tablespace tbs1;
      
      There is discussion on upstream about this,
        https://www.postgresql.org/message-id/flat/CAEET0ZGx9AvioViLf7nbR_8tH9-%3D27DN5xWJ2P9-ROH16e4JUA%40mail.gmail.com
      
      In this patch I recreate those directories to avoid this error. Other solutions
      include ignoring the directory-not-existing error or forcing a flush when
      redoing those kind of checkpoint xlogs which are added normally in drop
      database, etc.
      
      Let's revert or update the code change after the solution is finalized on
      upstream.
      7a09e80d
    • L
      docs - pxf init/sync support to master standby (#7540) · 433a6ebb
      Lisa Owen 提交于
      * docs - pxf init/sync support to master standby
      
      * edits requested by david
      
      * edits requested by francisco and oliver
      
      * pxf sync from master TO standby or seg host
      
      * identify sync run on master in pxf sync option description
      433a6ebb
  3. 29 4月, 2019 8 次提交
  4. 28 4月, 2019 3 次提交
  5. 27 4月, 2019 2 次提交
  6. 26 4月, 2019 6 次提交
  7. 25 4月, 2019 11 次提交
    • P
      Add README for building client tools on Windows · 24ea1af7
      Peifeng Qiu 提交于
      24ea1af7
    • P
      Fix windows client package script · a2571325
      Peifeng Qiu 提交于
      Connectivity and loaders are no longer vendored. Loaders will be
      merged into clients. Add script to create msi package.
      a2571325
    • P
      Compile pygresql with CMake · defab9ed
      Peifeng Qiu 提交于
      Requires a working libpq.dll. Set CMAKE_PREFIX_PATH to a successful
      client build.
      defab9ed
    • P
      Fix gpfdist pipe failure with latest windows build · f044d844
      Peifeng Qiu 提交于
      Behavior of stat() is not stable across C Runtime versions.
      Implementation of msvcrt.dll calls FindFirstFile(), while in normal
      CRT that omes with Visual Studio or Redistribute packages, it calls
      CreateFile().
      CreateFile() is problematic here, if path is a pipe, it will open
      the pipe once then close, causing the other side to connect to the
      wrong pipe. Skip stat() if the name is pipe and pretend there is one.
      f044d844
    • P
      Compile gpfdist on windows with CMake · 4a4e4bbf
      Peifeng Qiu 提交于
      - Don't include strings.h when build with MSVC
      - C99 Syntax fix for struct initializer.
      - Call event_set to initialize event struct. Later libevent version
      expect this behavior.
      - Use recv instead of read. Latest CRT implementation of read only
      works on files, not sockets.
      4a4e4bbf
    • P
      Fix 64-bit kerberos lib path · 6b4621ec
      Peifeng Qiu 提交于
      6b4621ec
    • P
      Fix msvc build for client tools · 8a5ad4bf
      Peifeng Qiu 提交于
      - Fix upstream build system for MSVC, add option to build.pl to
      only build client tools.
      - Add detection for MSVC SDK version. If this field is missing,
      8.1 is assumed. The latest compiler will complain about this.
      - Various small fixes
      8a5ad4bf
    • C
      Add a list of SQL keywords to the ref guide (#7449) · 052bdb22
      Chuck Litzell 提交于
      * Add a list of SQL keywords to the ref guide
      
      * Fix error from review
      
      * Update from review comment
      052bdb22
    • T
      Add the gpdb clients release candidates (#7531) · 48bdaf2a
      Tingfang Bao 提交于
      Story: https://www.pivotaltracker.com/story/show/164917628
      
         The gp-integration-testing pipeline needs the gp-clients RC
         package as a input, and then create the clients RPM base on it.
         The custom installer patch also need it to build client bin installer.
      Co-authored-by: NXiaoran Wang <xiwang@pivotal.io>
      Co-authored-by: NShaoqi Bai <sbai@pivotal.io>
      Co-authored-by: NBob Bao <bbao@pivotal.io>
      48bdaf2a
    • C
      Rename instances of "PQO" to "Pivotal Optimizer (GPORCA)" (#7511) · 5212dba1
      Chris Hajas 提交于
      ORCA Explain plans will now contain:
      `Optimizer: Pivotal Optimizer (GPORCA) version 3.35.0`
      
      instead of:
      `Optimizer: PQO version 3.35.0`
      
      Authored-by: Chris Hajas chajas@pivotal.io
      5212dba1
    • J
      behave: install patchelf to get around RPATH problems · e5e91bdc
      Jacob Champion 提交于
      Follow-up to the previous commit, which worked fine for CentOS6 but fell
      apart with CentOS7.
      
      Because our vendored Python doesn't contain an RPATH/RUNPATH pointer to
      the location of its libpython, trying to execute it directly will result
      in failures at link time. The previous commit took the approach that
      greenplum_path.sh takes, which is to hardcode an LD_LIBRARY_PATH that
      makes up for this bug. This approach works for CentOS6, which is running
      Python 2.6 as its system version. On CentOS7, which has Python 2.7, the
      LD_LIBRARY_PATH causes the system Python to use the vendored
      libpython.so.2.7, and virtualenv fails.
      
      Instead of forcing a cross-linking situation with LD_LIBRARY_PATH, fix
      the problem in the vendored Python binary, by using patchelf to set up a
      proper RUNPATH. (We originally tried to build our vendored Python with
      an RPATH set at compile time, but the only way to do that without
      knowing the eventual installation prefix is by setting a relative RPATH
      using the `$ORIGIN` construct, and virtualenv is unfortunately
      incompatible with that.) We do this on any platforms that provide a
      patchelf binary, and do our best to limp along on all others.
      
      Along the way, get rid of the run_behave.yml task, which has been
      confusing us for the entirety of this work. CCP jobs now use
      run_behave_on_ccp_cluster.yml consistently.
      Co-authored-by: NKalen Krempely <kkrempely@pivotal.io>
      e5e91bdc