Skip to content

Commit

Permalink
fix(oracle): add support for Oracle Database 23ai (#17345)
Browse files Browse the repository at this point in the history
  • Loading branch information
hjamil-24 authored May 27, 2024
1 parent 6aba382 commit b9e71a7
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 11 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
strategy:
fail-fast: false
matrix:
oracle-version: [18, 21]
oracle-version: [18, 23]
node-version: [10, 18]
name: Oracle DB ${{ matrix.oracle-version }} (Node ${{ matrix.node-version }})
runs-on: ubuntu-latest
Expand All @@ -77,8 +77,8 @@ jobs:
- if: matrix.oracle-version == '18'
name: Install Local Oracle DB 18
run: yarn start-oracle-oldest
- if: matrix.oracle-version == '21'
name: Install Local Oracle DB 21
- if: matrix.oracle-version == '23'
name: Install Local Oracle DB 23
run: yarn start-oracle-latest
- name: Unit Tests
run: yarn test-unit
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
# Copyright (c) 2022, Oracle and/or its affiliates. All rights reserved
# Copyright (c) 2022, 2024 Oracle and/or its affiliates. All rights reserved

services:
oraclexedb:
container_name: oraclexedb
image: gvenzl/oracle-xe:21-slim
image: gvenzl/oracle-free:23.4-slim
environment:
ORACLE_PASSWORD: password
ORACLE_DATABASE: XEPDB1

ports:
- 1521:1521
healthcheck:
test: ["CMD-SHELL", "sqlplus", "system/password@XEPDB1"]
test: ["CMD-SHELL", "sqlplus", "system/password@localhost:1521/XEPDB1"]
retries: 10

networks:
Expand Down
4 changes: 2 additions & 2 deletions dev/oracle/21-slim/start.sh → dev/oracle/23-slim/start.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2022, Oracle and/or its affiliates. All rights reserved
# Copyright (c) 2022, 2024 Oracle and/or its affiliates. All rights reserved

#!/usr/bin/env bash
set -Eeuxo pipefail # https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/
Expand All @@ -17,7 +17,7 @@ docker-compose -p oraclexedb up -d
docker cp ../privileges.sql oraclexedb:/opt/oracle/.

# Granting all the needed privileges to sequelizetest user
docker exec -t oraclexedb sqlplus system/password@XEPDB1 @privileges.sql
docker exec -t oraclexedb sqlplus system/password@localhost:1521/XEPDB1 @privileges.sql

SEQ_WORKSPACE="$PWD"/../../../

Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -248,15 +248,15 @@
"start-mssql": "bash dev/mssql/2019/start.sh",
"start-db2": "bash dev/db2/11.5/start.sh",
"start-oracle-oldest": "bash dev/oracle/18-slim/start.sh",
"start-oracle-latest": "bash dev/oracle/21-slim/start.sh",
"start-oracle-latest": "bash dev/oracle/23-slim/start.sh",
"stop-mariadb": "bash dev/mariadb/10.3/stop.sh",
"stop-mysql": "bash dev/mysql/5.7/stop.sh",
"stop-mysql-8": "bash dev/mysql/8.0/stop.sh",
"stop-postgres": "bash dev/postgres/10/stop.sh",
"stop-mssql": "bash dev/mssql/2019/stop.sh",
"stop-db2": "bash dev/db2/11.5/stop.sh",
"stop-oracle-oldest": "bash dev/oracle/18-slim/stop.sh",
"stop-oracle-latest": "bash dev/oracle/21-slim/stop.sh",
"stop-oracle-latest": "bash dev/oracle/23-slim/stop.sh",
"restart-mariadb": "npm run start-mariadb",
"restart-mysql": "npm run start-mysql",
"restart-postgres": "npm run start-postgres",
Expand Down
2 changes: 1 addition & 1 deletion test/integration/model.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -2407,7 +2407,7 @@ describe(Support.getTestDialectTeaser('Model'), () => {
} else if (dialect === 'db2') {
expect(err.message).to.match(/ is an undefined name/);
} else if (dialect === 'oracle') {
expect(err.message).to.match(/ORA-00942: table or view does not exist/);
expect(err.message).to.match(/^ORA-00942:/);
} else {
throw new Error('Undefined dialect!');
}
Expand Down

0 comments on commit b9e71a7

Please sign in to comment.