Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for setting use_real_oids=on for hypopg extension #57

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/dexter/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ def parse_args(args)
o.boolean "--analyze", "analyze tables that haven't been analyzed in the past hour", default: false
o.boolean "--create", "create indexes", default: false
o.boolean "--enable-hypopg", "enable the HypoPG extension", default: false
o.boolean "--enable-hypopg-use-real-oids", "enable the HypoPG hypopg.use_real_oids -configuration", default: false
o.array "--exclude", "prevent specific tables from being indexed"
o.string "--include", "only include specific tables"
o.integer "--min-cost-savings-pct", default: 50, help: false
Expand Down
4 changes: 4 additions & 0 deletions lib/dexter/indexer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ def initialize(options)
check_extension

execute("SET lock_timeout = '5s'")

if @options[:enable_hypopg_use_real_oids]
execute("SET hypopg.use_real_oids=on")
end
end

def process_stat_statements
Expand Down