Skip to content

Commit 624f244

Browse files
authored
Merge pull request #1048 from utPLSQL/release/v3.1.10
Release/v3.1.10
2 parents c8dae86 + 9034250 commit 624f244

File tree

75 files changed

+2324
-1254
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+2324
-1254
lines changed

.travis.yml

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ env:
3030
- CURRENT_BRANCH=${TRAVIS_BRANCH}
3131
- UTPLSQL_REPO="utPLSQL/utPLSQL"
3232
- UTPLSQL_BUILD_NO="${TRAVIS_BUILD_NUMBER:-0}"
33-
- UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*"
3433
- UTPLSQL_VERSION=$(. .travis/get_project_version.sh)
3534
- UTPLSQL_BUILD_VERSION=$(. .travis/get_project_build_version.sh)
3635
- UTPLSQL_SOURCES_DIR='source'
@@ -51,10 +50,10 @@ env:
5150
- MAVEN_CFG=$HOME/.m2
5251
matrix:
5352
- ORACLE_VERSION="${DOCKER_TAG_11G:-11g-r2-xe}" CONNECTION_STR='127.0.0.1:1521/XE' DOCKER_OPTIONS='--shm-size=1g'
54-
- ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs"
55-
- ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs"
56-
- ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs"
57-
- ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB' DOCKER_OPTIONS="-v /dev/pdbs:/opt/oracle/oradata/pdbs"
53+
- ORACLE_VERSION="${DOCKER_TAG_12C:-12c-r1-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB'
54+
- ORACLE_VERSION="${DOCKER_TAG_12C2:-12c-r2-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB'
55+
- ORACLE_VERSION="${DOCKER_TAG_18:-18c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB'
56+
- ORACLE_VERSION="${DOCKER_TAG_19:-19c-se2-small}" CONNECTION_STR='127.0.0.1:1521/ORCLCDB'
5857

5958
cache:
6059
pip: true
@@ -81,11 +80,7 @@ before_install:
8180
install:
8281
#- unzip utPLSQL.zip
8382
- unzip utPLSQL-cli.zip && chmod -R u+x utPLSQL-cli
84-
# Get ojdbc via maven
85-
- bash .travis/maven_cfg.sh
8683
- bash .travis/install_sqlcl.sh
87-
- sudo mkdir -p /dev/pdbs
88-
- sudo chmod -R 777 /dev/pdbs
8984
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/start_db.sh; fi
9085

9186
before_script:
@@ -115,16 +110,15 @@ jobs:
115110
- pip install mkdocs
116111
before_script: skip
117112
script:
118-
- if [[ ($TRAVIS_BRANCH == develop) && ($TRAVIS_PULL_REQUEST == false) ]]; then bash .travis/trigger_travis.sh $TRAVIS_ACCESS_TOKEN; fi
119-
- #The update_project_version.sh needs to be done before pushing changes to develop branch
120113
- bash .travis/update_project_version.sh
121114
- git config --global user.email "[email protected]"
122115
- git config --global user.name "${UTPLSQL_BUILD_USER_NAME}"
123116
- git remote rm origin
124117
- git remote add origin https://${github_api_token}@github.com/${UTPLSQL_REPO}
125118
- if [[ ! $TRAVIS_TAG ]]; then bash .travis/push_release_version.sh; fi
119+
- bash .travis/push_docs_to_github_io.sh
126120
- bash .travis/build_docs.sh
127-
- bash .travis/push_docs_to_gh_pages.sh
121+
- if [[ ($TRAVIS_BRANCH == develop) && ($TRAVIS_PULL_REQUEST == false) ]]; then bash .travis/trigger_travis.sh $TRAVIS_ACCESS_TOKEN; fi
128122
before_deploy:
129123
- bash .travis/build_release_archive.sh
130124
deploy:

.travis/install.sh

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,6 @@ PROMPT Creating $UT3_TESTER - Power-user for testing internal framework code
7474
create user $UT3_TESTER identified by "$UT3_TESTER_PASSWORD" default tablespace $UT3_TABLESPACE quota unlimited on $UT3_TABLESPACE;
7575
grant create session, create procedure, create type, create table to $UT3_TESTER;
7676
77-
PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present
78-
79-
grant alter any trigger to $UT3_TESTER;
80-
grant administer database trigger to $UT3_TESTER;
8177
grant execute on dbms_lock to $UT3_TESTER;
8278
8379
PROMPT Granting $UT3_OWNER code to $UT3_TESTER
@@ -98,7 +94,7 @@ end;
9894
PROMPT Granting $UT3_OWNER tables to $UT3_TESTER
9995
10096
begin
101-
for i in ( select table_name from all_tables t where owner = 'UT3' and nested = 'NO' and IOT_NAME is NULL)
97+
for i in ( select table_name from all_tables t where owner = 'UT3' and nested = 'NO' and iot_name is null)
10298
loop
10399
execute immediate 'grant select on UT3.'||i.table_name||' to UT3_TESTER';
104100
end loop;
@@ -124,8 +120,33 @@ grant create public database link to $UT3_TESTER_HELPER;
124120
grant drop public database link to $UT3_TESTER_HELPER;
125121
126122
PROMPT Grants for testing coverage outside of main UT3 schema.
127-
grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type, select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table, select any dictionary, create any synonym, drop any synonym to $UT3_TESTER_HELPER;
123+
grant create any procedure, drop any procedure, execute any procedure, create any type, drop any type, execute any type, under any type,
124+
select any table, update any table, insert any table, delete any table, create any table, drop any table, alter any table,
125+
select any dictionary, create any synonym, drop any synonym,
126+
grant any object privilege, grant any privilege
127+
to $UT3_TESTER_HELPER;
128+
128129
grant create job to $UT3_TESTER_HELPER;
129130
131+
PROMPT Additional grants for disabling DDL trigger and testing parser without trigger enabled/present
132+
133+
grant alter any trigger to $UT3_TESTER_HELPER;
134+
grant administer database trigger to $UT3_TESTER_HELPER;
135+
grant execute on dbms_lock to $UT3_TESTER_HELPER;
136+
137+
create user ut3_cache_test_owner identified by ut3;
138+
grant create session, create procedure to ut3_cache_test_owner;
139+
140+
create user ut3_no_extra_priv_user identified by ut3;
141+
grant create session, create procedure to ut3_no_extra_priv_user;
142+
143+
create user ut3_select_catalog_user identified by ut3;
144+
grant create session, create procedure, select_catalog_role to ut3_select_catalog_user;
145+
146+
create user ut3_select_any_table_user identified by ut3;
147+
grant create session, create procedure, select any table to ut3_select_any_table_user;
148+
149+
create user ut3_execute_any_proc_user identified by ut3;
150+
grant create session, create procedure, execute any procedure to ut3_execute_any_proc_user;
130151
exit
131152
SQL

.travis/maven_cfg.sh

Lines changed: 0 additions & 18 deletions
This file was deleted.

.travis/pom.xml

Lines changed: 0 additions & 62 deletions
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# Many aspects of this came from https://gist.github.com/domenic/ec8b0fc8ab45f39403dd
3+
# Based on `push_docs_to_gh_pages.sh`
44
# Significant alterations
55
# - Support for multiple copies of documentation,
66
# - only clearing out develop
@@ -13,59 +13,55 @@
1313
# - File: "docs/index.md" with that contains develop docs
1414

1515
# Required ENV Variables
16-
PAGES_TARGET_BRANCH="gh-pages"
1716
LATEST_DOCS_BRANCH="develop"
17+
GITHUB_IO_REPO='utPLSQL/utPLSQL.github.io'
18+
GITHUB_IO_BRANCH='master'
19+
1820
# TRAVIS_* variables are set by travis directly and only need to be if testing externally
1921

20-
# We don't want a pull request automatically updating the repository
22+
# We deploy only when building on develop branch or on TAG (release)
2123
if [ "$TRAVIS_PULL_REQUEST" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST_DOCS_BRANCH}" ] || [ -n "${TRAVIS_TAG}" ]; }; then
2224

2325
# ENV Variable checks are to help with configuration troubleshooting, they silently exit with unique message.
2426
# Anyone one of them not set can be used to turn off this functionality.
2527

2628
# If a version of the project is not defined
27-
[[ -n "${UTPLSQL_VERSION}" ]] || { echo "variable UTPLSQL_VERSION is not defines or missing value"; exit 0; }
29+
[[ -n "${UTPLSQL_VERSION}" ]] || { echo "variable UTPLSQL_VERSION is not defines or missing value"; exit 1; }
2830
# Fail if the markdown documentation is not present.
2931
[[ -f ./docs/index.md ]] || { echo "file docs/index.md not found"; exit 1; }
3032

31-
# Save some useful information
33+
# Store latest commit SHA to be used when committing and pushing to github.io repo
3234
SHA=`git rev-parse --verify HEAD`
3335

34-
# clone the repository and switch to PAGES_TARGET_BRANCH branch
36+
# clone the repository and switch to GITHUB_IO_BRANCH branch
3537
mkdir pages
36-
cd pages
37-
git clone https://${github_api_token}@github.com/${UTPLSQL_REPO} .
38-
39-
PAGES_BRANCH_EXISTS=$(git ls-remote --heads origin ${PAGES_TARGET_BRANCH})
38+
cd ./pages
39+
git clone --depth 1 https://${github_api_token}@github.com/${GITHUB_IO_REPO} -b ${GITHUB_IO_BRANCH} .
4040

41-
if [ -n "$PAGES_BRANCH_EXISTS" ] ; then
42-
echo "Pages Branch Found"
43-
git checkout ${PAGES_TARGET_BRANCH}
44-
else
45-
echo "Creating Pages Branch"
46-
git checkout --orphan ${PAGES_TARGET_BRANCH}
47-
git rm -rf .
48-
fi
41+
mkdir -p utPLSQL
42+
cd ./utPLSQL
4943
#clear out develop documentation directory and copy docs contents to it.
50-
echo "updating 'develop' directory"
51-
mkdir -p develop
52-
rm -rf develop/**./* || exit 0
53-
cp -a ../docs/. ./develop
44+
echo "updating 'develop' documentation directory"
45+
mkdir -p ./develop
46+
rm -rf ./develop/**./* || exit 0
47+
cp -a ../../docs/. ./develop
48+
5449
# If a Tagged Build then copy to it's own directory as well and to the 'latest' release directory
5550
if [ -n "$TRAVIS_TAG" ]; then
56-
echo "Creating ${UTPLSQL_VERSION}"
57-
mkdir -p ${UTPLSQL_VERSION}
58-
rm -rf ${UTPLSQL_VERSION}/**./* || exit 0
59-
cp -a ../docs/. ${UTPLSQL_VERSION}
60-
echo "Populating 'latest' directory"
61-
mkdir -p latest
62-
rm -rf latest/**./* || exit 0
63-
cp -a ../docs/. latest
51+
echo "Creating directory ./${UTPLSQL_VERSION}"
52+
mkdir -p ./${UTPLSQL_VERSION}
53+
rm -rf ./${UTPLSQL_VERSION}/**./* || exit 0
54+
cp -a ../../docs/. ./${UTPLSQL_VERSION}
55+
echo "Populating 'latest' directory"
56+
mkdir -p ./latest
57+
rm -rf ./latest/**./* || exit 0
58+
cp -a ../../docs/. ./latest
6459
fi
6560
# Stage changes for commit
6661
git add .
62+
6763
#Check if there are doc changes, if none exit the script
68-
if [[ -z `git diff HEAD --exit-code` ]] && [ -n "${PAGES_BRANCH_EXISTS}" ] ; then
64+
if [[ -z `git diff HEAD --exit-code` ]]; then
6965
echo "No changes to docs detected."
7066
exit 0
7167
fi
@@ -75,7 +71,7 @@ if [ "$TRAVIS_PULL_REQUEST" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST
7571
echo "---" >>index.md
7672
echo "layout: default" >>index.md
7773
echo "---" >>index.md
78-
echo "<!-- Auto generated from .travis/push_docs_to_gh_pages.sh -->" >>index.md
74+
echo "<!-- Auto generated from .travis/push_docs_to_github_io.sh -->" >>index.md
7975
echo "# Documentation versions" >>index.md
8076
echo "" >>index.md
8177
echo "" >>index.md #- 7th line - placeholder for latest release doc
@@ -96,6 +92,6 @@ if [ "$TRAVIS_PULL_REQUEST" == "false" ] && { [ "${CURRENT_BRANCH}" == "${LATEST
9692
git add .
9793
git commit -m "Deploy to gh-pages branch: base commit ${SHA}"
9894
# Now that we're all set up, we can push.
99-
git push --quiet origin HEAD:${PAGES_TARGET_BRANCH}
95+
git push --quiet origin HEAD:${GITHUB_IO_BRANCH}
10096
fi
10197

.travis/settings.xml

Lines changed: 0 additions & 51 deletions
This file was deleted.

.travis/update_project_version.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
#!/usr/bin/env bash
22

3+
UTPLSQL_VERSION_PATTERN="v?([0-9]+\.){3}[0-9]+[^']*"
4+
35
echo Current branch is "${CURRENT_BRANCH}"
46

57
echo Update version in project source files

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v3.1.9
1+
v3.1.10

development/cleanup.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,11 @@ drop user ${UT3_RELEASE_VERSION_SCHEMA} cascade;
2323
drop user ${UT3_TESTER} cascade;
2424
drop user ${UT3_TESTER_HELPER} cascade;
2525
drop user ${UT3_USER} cascade;
26+
drop user ut3_cache_test_owner cascade;
27+
drop user ut3_no_extra_priv_user cascade;
28+
drop user ut3_select_catalog_user cascade;
29+
drop user ut3_select_any_table_user cascade;
30+
drop user ut3_execute_any_proc_user cascade;
2631
2732
begin
2833
for i in (

development/releasing.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
The release process is semi-automated.
1+
## Release process
22

33
With every build, the build process on Travis updates files with an appropriate version number before deployment into the database.
44
This step is performed, to confirm that the update of versions works properly.
55

6-
To create a release:
6+
## To create a release
7+
78
- create release branch from development branch and make sure to name the release branch: `release/vX.Y.Z`
89
- update, commit and push at least one file change in the release branch, to kickoff a Travis build
910
- wait for th build to complete successfully

0 commit comments

Comments
 (0)