Yedidyah Bar David has posted comments on this change.

Change subject: db: cleanup: psql usage
......................................................................


Patch Set 5:

(3 comments)

http://gerrit.ovirt.org/#/c/24885/5/packaging/dbscripts/create_schema.sh
File packaging/dbscripts/create_schema.sh:

Line 22
Line 23
Line 24
Line 25
Line 26
def. ${DBFUNC_MD5DIR}


Line 40: done
Line 41: 
Line 42: echo "user name is: '${DBFUNC_DB_USER}'"
Line 43: 
Line 44: dbfunc_psql_statement "create language 'plpgsql';" > /dev/null
Perhaps not '> /dev/null' (also in tens of other places, nvm for now)? Perhaps 
create only if not exists? Why not just keep the call to createlang?
Line 45: 
Line 46: #set database min error level
Line 47: dbfunc_psql_statement_die "ALTER DATABASE \"${DBFUNC_DB_DATABASE}\" 
SET client_min_messages=ERROR;" > /dev/null
Line 48: 


http://gerrit.ovirt.org/#/c/24885/5/packaging/dbscripts/dbfunc-base.sh
File packaging/dbscripts/dbfunc-base.sh:

Line 52:     dbfunc_psql "$@" || die "Cannot execute sql command: $*"
Line 53: }
Line 54: 
Line 55: #
Line 56: # TODO: figure out why we cannot use --command=
Probably just to avoid quoting issues. Can also use '<<' instead of temp file.
Line 57: #
Line 58: dbfunc_psql_statement() {
Line 59:     local statement="$1"
Line 60: 


-- 
To view, visit http://gerrit.ovirt.org/24885
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ib93ad2ca4d35fe3f44e3f8915182778a9fe6ed66
Gerrit-PatchSet: 5
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Alon Bar-Lev <[email protected]>
Gerrit-Reviewer: Eli Mesika <[email protected]>
Gerrit-Reviewer: Sandro Bonazzola <[email protected]>
Gerrit-Reviewer: Yaniv Dary <[email protected]>
Gerrit-Reviewer: Yedidyah Bar David <[email protected]>
Gerrit-Reviewer: [email protected]
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to