These are chat archives for ManageIQ/manageiq/performance

1st
Dec 2015
Keenan Brock
@kbrock
Dec 01 2015 01:55
@matthewd what is ext_options again?
Keenan Brock
@kbrock
Dec 01 2015 15:40
@fryguy looking at http://x.com/vm_infra/explorer - and there are a number of optimizations introduced [7/1/2014] (manageiq/manageiq@d21575f)
what is vandt - is that the left hand side?
Keenan Brock
@kbrock
Dec 01 2015 15:52
@matthewd is there a way to modify the preloader to not populate/run if the values are already loaded? Seems we preload a bunch of stuff that is already loaded
Also, is there a way to ask if the data (sql) exists in the cache and just use that instead of preloading?
Matthew Draper
@matthewd
Dec 01 2015 15:54
Direct use of the preloader isn't supported at all, so I doubt there's any existing mechanism to check whether something's already been preloaded
The SQL cache? I'm not sure I understand how that would work
Alex Krzos
@akrzos
Dec 01 2015 15:57
@kbrock there is a lot of history with vm_infra/explorer page
@kbrock might be worth it to look at this previous bz https://bugzilla.redhat.com/show_bug.cgi?id=1086015
Keenan Brock
@kbrock
Dec 01 2015 16:00
@akrzos yea, I must be missing something - because looking at these queries - it looks like there is no way this improved performance - so when that is the case, it requires looking closer
Alex Krzos
@akrzos
Dec 01 2015 16:01
The shear number of queries when I looked into that seemed to be the problem
the ui process would peg to 100% too
Keenan Brock
@kbrock
Dec 01 2015 16:02
the sheer number of duplicate queries is a problem
and the fact that these queries could bring back every row doesn't help
Matthew Draper
@matthewd
Dec 01 2015 16:02
Duplicate queries that aren't hitting the SQL cache? :confused:
Keenan Brock
@kbrock
Dec 01 2015 16:02
well
Alex Krzos
@akrzos
Dec 01 2015 16:02
even with the cache
Keenan Brock
@kbrock
Dec 01 2015 16:02
one has order by lower(name)
Alex Krzos
@akrzos
Dec 01 2015 16:02
debug log shows the cache
Keenan Brock
@kbrock
Dec 01 2015 16:02
the other includes extra tables
they queries are slightly different
sometimes we hit the db to get just the first row, then the count, then all the records
probably ok from a network / ruby point of view - but is taxing the db
Alex Krzos
@akrzos
Dec 01 2015 16:04
@kbrock a good db to analyze would simply be the 10k vms in the db
Keenan Brock
@kbrock
Dec 01 2015 16:05
yea - think I'll convert over there to make sure the queries I think are slow (on the 10 vm) are actually slow in the 10k
thanks
Alex Krzos
@akrzos
Dec 01 2015 16:05
so after a refresh of my x-large env, you have 10k vms in the db and the vm_infra usually takes on the order of 60s to load
Keenan Brock
@kbrock
Dec 01 2015 16:06
vcsim-large.perf... (I have everything but the hostname)
vcsim-x-large ?
Jason Frey
@Fryguy
Dec 01 2015 16:06
:point_up: December 1, 2015 10:40 AM vandt == "vms and templates", specifically the vandt tree in the explorer
Keenan Brock
@kbrock
Dec 01 2015 16:06
thanks
that is what I guessed
Alex Krzos
@akrzos
Dec 01 2015 16:06
vcsim-xlarge.perf...
Keenan Brock
@kbrock
Dec 01 2015 16:06
perfect
Jason Frey
@Fryguy
Dec 01 2015 16:07
the preloader is smart enough to know if the data has already been loaded or not
so preloading something already preloaded is a noop
Daniel Berger
@djberg96
Dec 01 2015 16:07
@kbrock would a view be an option?
Keenan Brock
@kbrock
Dec 01 2015 16:07
@djberg96 did you say db view / materialized or otherwise?
Daniel Berger
@djberg96
Dec 01 2015 16:07
maybe...do i get in trouble if i did
Keenan Brock
@kbrock
Dec 01 2015 16:08
lol
Daniel Berger
@djberg96
Dec 01 2015 16:08
because if i do, then no
Keenan Brock
@kbrock
Dec 01 2015 16:08
wait - that uses sql-fu - yes, you'll get in trouble
Daniel Berger
@djberg96
Dec 01 2015 16:09
i thought rails had some facility for generating one on the fly
Keenan Brock
@kbrock
Dec 01 2015 16:17
@akrzos anything special I need to do to access vcsim-xlarge.perf.lab.eng.rdu.redhat.com - when loading authentications - it is hanging - something about https being unreachable
Matthew Draper
@matthewd
Dec 01 2015 16:19

because looking at these queries - it looks like there is no way this improved performance

@kbrock keep in mind that anything from pre-rails4 could have behaved Very Differently Indeed when it was written

Keenan Brock
@kbrock
Dec 01 2015 16:20
yes - agreed
and the fact that I say "there is no way"...
that makes me KNOW I'm missing something
Alex Krzos
@akrzos
Dec 01 2015 16:20
@kbrock shouldn't be anything special
Keenan Brock
@kbrock
Dec 01 2015 16:20
because multiple people verified that it was faster
Alex Krzos
@akrzos
Dec 01 2015 16:20
@kbrock Let me see if i can get into it
Keenan Brock
@kbrock
Dec 01 2015 16:20
nope
Jason Frey
@Fryguy
Dec 01 2015 16:20

these queries

which queries?

Keenan Brock
@kbrock
Dec 01 2015 16:20
stay away
the sheer number of duplicate queries that look like they are doing generally the same thing
I'll write them down
hmm
sheer number = only 7
that was over stated -sorry
Jason Frey
@Fryguy
Dec 01 2015 16:21
was just curious if this was the vandt thing or a different thing
ETOOMANYCONVERSATIONS
Keenan Brock
@kbrock
Dec 01 2015 16:21
you know - that may be it
vandt
Alex Krzos
@akrzos
Dec 01 2015 16:22
@kbrock I was able to get into the vsphere client so it should be gtg
Jason Frey
@Fryguy
Dec 01 2015 16:22
vandt is faster because it didn't walk the tree
Keenan Brock
@kbrock
Dec 01 2015 16:22
yes
Jason Frey
@Fryguy
Dec 01 2015 16:22
it queried the whole tree at once
Keenan Brock
@kbrock
Dec 01 2015 16:22
I noticed that we are making 4 different queries, one for templates, one for orphans, one for archived
Jason Frey
@Fryguy
Dec 01 2015 16:22
you wouldn't really notice it though unless you pre-opened a bunch of the folders
yeah, they are 3 different trees
Keenan Brock
@kbrock
Dec 01 2015 16:22
the grand total brings back every record - but did it in 4 passes
Jason Frey
@Fryguy
Dec 01 2015 16:23
(part of the issue is that the trees are built even if you don't see them in the UI)
Keenan Brock
@kbrock
Dec 01 2015 16:23
and sometimes it brings the records back in normal sort, and other times in lower(name) sort (has no index)
aah
Jason Frey
@Fryguy
Dec 01 2015 16:23
interesting
Keenan Brock
@kbrock
Dec 01 2015 16:23
guessing that is the main view vs vandt view
Jason Frey
@Fryguy
Dec 01 2015 16:24
the accordions load all the content even if they are collapsed
Keenan Brock
@kbrock
Dec 01 2015 16:24
nice. vandt's auto correct is vendetta
Jason Frey
@Fryguy
Dec 01 2015 16:24
if you want a performance boost fixing that would be huge
Keenan Brock
@kbrock
Dec 01 2015 16:24
I'm curious about the main view
and rbac
we pull back all records - with a little preload
then we go into rbac
convert to ids
then pull back all records
then convert to ids
then pull back all records - with a big preload
then with a super big preload
Jason Frey
@Fryguy
Dec 01 2015 16:25
I'd have to see that, but I wouldn't doubt most of that :D
Keenan Brock
@kbrock
Dec 01 2015 16:25
I may be getting confused
and I'm mixing up the count(*)'s vs real queries - so artifically inflating the numbers
Jason Frey
@Fryguy
Dec 01 2015 16:25
we definitely get ids + some basic info / filter the ids / then get all the info for those ids that are left
Keenan Brock
@kbrock
Dec 01 2015 16:25
so, please add :salt: to my comments
Jason Frey
@Fryguy
Dec 01 2015 16:26
incidentally, the "accordions load everything" is part of the reason we need VmdbDatabase seeded...the diagnostics page (even though it's not shown) is written expecting as least one record
Keenan Brock
@kbrock
Dec 01 2015 16:26
omg - so simulate_workers doesn't work in production mode
so I ran a refresh in dev mode
2-3 seconds per host x 200 for storages alone
:(
yea, xlarge was a mistake - I'm throwin this away and running against something more reasonable
I only need a page that takes > 15seconds to know what is slow
Keenan Brock
@kbrock
Dec 01 2015 16:31
@akrzos do you have a browser hack to auto populate this stuff? ruboforms or something?
Alex Krzos
@akrzos
Dec 01 2015 16:33
@kbrock I might have an appliance with it loaded already, but refresh on 5.5 with xlarge should be somewhere ~700s
definitely not 2-3 s per object
Keenan Brock
@kbrock
Dec 01 2015 16:34
yea - I just enabled simulate_queue_workers for production mode
Alex Krzos
@akrzos
Dec 01 2015 16:34
I have never used that nor do I know what it is
Jason Frey
@Fryguy
Dec 01 2015 16:35
@kbrock I don't understand the prod mode thing...are you testing something specific to prod mode?
Keenan Brock
@kbrock
Dec 01 2015 16:36
production mode is more performant - with reloading classes and disk caches - no?
@Fryguy got it - I was looking at the first page (which looked up left AND right) as a single page - should have been thinking of it as 2 pages. this thing is performing great
Jason Frey
@Fryguy
Dec 01 2015 16:40
maybe a little...the biggest benefit might be the UI asset compilation
but for models and stuff it shouldn't affect too much
Keenan Brock
@kbrock
Dec 01 2015 16:41
k
Is there a reason we need to do this every page hit? - tenancy is calling it
lib/vmdb/config.rb:166:in `config_mtime_from_db'
lib/vmdb/config.rb:310:in `cached_config_valid?'
SELECT  "configurations"."updated_on" FROM "configurations" WHERE "configurations"."miq_server_id" = $1 AND "configurations"."typ" = $2  ORDER BY "configurations"."id" ASC LIMIT 1
looks like we lookup the mtime from db every time we create a vmdb config object
aah - it is reading the settings values for the 'default tenant'
but do we need to lookup the mtime?
(tangent - this is only 0.2ms - but on every page hit)
Keenan Brock
@kbrock
Dec 01 2015 16:48
@Fryguy is there a reason why we need to count these records at all? ref1 ref2
because we are doing a distinct and a few joins here - so the count is not trivial at all. and much of the time we're just bringing back all records anyway
in mysql - this is quick, in postgres, count is as expensive or more compared with a large table and using limit/offset
Jason Frey
@Fryguy
Dec 01 2015 16:49
I believe it's for the paging controls
@gtanzillo might remember best
Keenan Brock
@kbrock
Dec 01 2015 16:50
aah
I think it is fun when the paging on a web page takes more time than the content
Jason Frey
@Fryguy
Dec 01 2015 16:50
lol
Keenan Brock
@kbrock
Dec 01 2015 16:51
SELECT COUNT(DISTINCT "vms"."id")
FROM "vms"
LEFT OUTER JOIN "hosts" ON "hosts"."id" = "vms"."host_id"
LEFT OUTER JOIN "storages" ON "storages"."id" = "vms"."storage_id"
LEFT OUTER JOIN "ext_management_systems" ON "ext_management_systems"."id" = "vms"."ems_id"
LEFT OUTER JOIN "snapshots" ON "snapshots"."vm_or_template_id" = "vms"."id"
LEFT OUTER JOIN "compliances" ON "compliances"."resource_id" = "vms"."id" AND "compliances"."resource_type" = $1
LEFT OUTER JOIN "operating_systems" ON "operating_systems"."vm_or_template_id" = "vms"."id"
LEFT OUTER JOIN "hardwares" ON "hardwares"."vm_or_template_id" = "vms"."id"
LEFT OUTER JOIN "taggings" ON "taggings"."taggable_id" = "vms"."id" AND "taggings"."taggable_type" = $2
LEFT OUTER JOIN "tags" ON "tags"."id" = "taggings"."tag_id"
WHERE "vms"."type" IN ('ManageIQ::Providers::InfraManager::Vm', 'ManageIQ::Providers::Microsoft::InfraManager::Vm', 'ManageIQ::Providers::Redhat::InfraManager::Vm', 'ManageIQ::Providers::Vmware::InfraManager::Vm', 'VmXen')
AND "vms"."template" = $3
hmm
Gregg Tanzillo
@gtanzillo
Dec 01 2015 16:51
lol, without reading backwards I’ll say that I recall that we always needed counts for paging so that it can say something like "1-20 of non” on the bottom of th epage.
Keenan Brock
@kbrock
Dec 01 2015 16:52
well, the alternative there is:
SELECT COUNT(*)
FROM "vms"
WHERE "vms"."type" IN ('ManageIQ::Providers::InfraManager::Vm', 'ManageIQ::Providers::Microsoft::InfraManager::Vm', 'ManageIQ::Providers::Redhat::InfraManager::Vm', 'ManageIQ::Providers::Vmware::InfraManager::Vm', 'VmXen')
AND "vms"."template" = $3
these darn type in clauses are 'fun'
anyway
Matthew Draper
@matthewd
Dec 01 2015 16:54
Why fun?
Keenan Brock
@kbrock
Dec 01 2015 16:54
do you want me to measure the difference between those 2 queries?
or should I just look into implementing this
@matthewd I like select count(*) from "vms" where template = $3
s/fun/verbose/
cool - thanks for letting me gab all
pretty sure I have the solution now
at least for the right hand side
@gtanzillo is there a reason for counting authorized vs counting total?
offhand - don't research
Matthew Draper
@matthewd
Dec 01 2015 16:58
@kbrock aren't both numbers shown?
Greg Blomquist
@blomquisg
Dec 01 2015 16:58
Keenan Brock
@kbrock
Dec 01 2015 16:58
@matthewd thanks - good enough for me
@blomquisg I ran top and it said "this process is a pig"
sorry - snark / pork / spam
next question: [select count(*) from vms where id in (?), $filtered_ids] (shortened) - is there a reason we don't just $filtered_ids.size?
Jason Frey
@Fryguy
Dec 01 2015 17:03
that's a good question... @gtanzillo ?
Keenan Brock
@kbrock
Dec 01 2015 17:03
thanks
this building of queries is impressive. just wish we had done that after active record were more powerful and we could have used the newer active record hash syntax
@matthewd have you rewritten miq expression and rbac in hash form yet?
Gregg Tanzillo
@gtanzillo
Dec 01 2015 17:04
@kbrock @Fryguy From my recollection, there was some messaging on the page that indicatated how may items you were authorized to see vs. the total number of items available. I’m not sure it that still exists or not. @dclarizio may know.
Matthew Draper
@matthewd
Dec 01 2015 17:04
@kbrock nope.. go ahead :grin:
Keenan Brock
@kbrock
Dec 01 2015 17:04
lol
@gtanzillo $filtered_ids - is that the ids that re displayed on the page, or the possible ids to display on that page (and we need to add rbac AFTER)?
sorry - too in depth. I'll figure out on my own
Gregg Tanzillo
@gtanzillo
Dec 01 2015 17:06
lol, yeah, I think I’ll need to do the same to answer that.
Keenan Brock
@kbrock
Dec 01 2015 17:06
yea - skip it
Keenan Brock
@kbrock
Dec 01 2015 17:12

@matthewd compare and contrast:

klass.ancestors.include?(OwnershipMixin)
klass < OwnershipMixin

are these the same thing?

Matthew Draper
@matthewd
Dec 01 2015 17:15
Yes (modulus an allocation)
Keenan Brock
@kbrock
Dec 01 2015 17:16
ok, so refactoring to !(klass < OwhershipMixin) - thanks
Alex Krzos
@akrzos
Dec 01 2015 17:29
Anyone have the ruby code I need to create a provider on 5.4 and before , I know with 5.5 I can use:
ManageIQ::Providers::InfraManager.create(...
Matthew Draper
@matthewd
Dec 01 2015 17:54
@akrzos EmsVmware.create(… might be what you're looking for?
Keenan Brock
@kbrock
Dec 01 2015 18:12
@matthewd @Fryguy When I run rails console, sql goes to stdout
when running rails server - is there a way to get these queries into development.log (or anywhere really)
Joe Rafaniello
@jrafanie
Dec 01 2015 18:13
Rails.logger.level = 0 ?
Keenan Brock
@kbrock
Dec 01 2015 18:13
thanks lj
Joe Rafaniello
@jrafanie
Dec 01 2015 18:13
I think you can put that in config/environments/development.rb config.logger.level = 0 or something
;-)
Keenan Brock
@kbrock
Dec 01 2015 18:13
+1 thanks
Joe Rafaniello
@jrafanie
Dec 01 2015 18:14
You're welcome... just don't forget to unset it
Keenan Brock
@kbrock
Dec 01 2015 18:14
lol
I'm on explorer, and click "next page"
the logs says spent 20ms in sql
rack-mini-profiler says '17 queries'
but dev log is still empty
... need params being passed into sql so I can properly explain it in psql
Joe Rafaniello
@jrafanie
Dec 01 2015 18:17
oh, duh, sorry
I think we take the level_rails in the vmdb.yml and probably overwrite your setting
Keenan Brock
@kbrock
Dec 01 2015 18:17
perfect - thanks
Joe Rafaniello
@jrafanie
Dec 01 2015 18:17
so, either change it in the database through the UI or make your change after we load our stuff
Keenan Brock
@kbrock
Dec 01 2015 18:18
perfect - thanks
Matthew Draper
@matthewd
Dec 01 2015 18:19

need params being passed into sql so I can properly explain it in psql

You know you need to do a PREPARE, right?

Keenan Brock
@kbrock
Dec 01 2015 18:20
@matthewd are you saying explain analyze won't properly explain the query from psql?
since we are using prepared statements?
Matthew Draper
@matthewd
Dec 01 2015 18:20
It will, as long as you do a prepare, then explain the execute
If you're manually interpolating the parameters, that's not the same thing
Keenan Brock
@kbrock
Dec 01 2015 18:20
select * from vms where id in (1,2,3)
how do I do that in psql?
Matthew Draper
@matthewd
Dec 01 2015 18:21
That one wouldn't've been parameterized in the first place, would it?
Keenan Brock
@kbrock
Dec 01 2015 18:21
ok
select vms.* from vms where id in ($1), [1,2,3]
Matthew Draper
@matthewd
Dec 01 2015 18:21
Now you're just making things up
Keenan Brock
@kbrock
Dec 01 2015 18:22
yes
SELECT COUNT(DISTINCT "vms"."id")
FROM "vms"
LEFT OUTER JOIN "hosts" ON "hosts"."id" = "vms"."host_id"
LEFT OUTER JOIN "storages" ON "storages"."id" = "vms"."storage_id"
LEFT OUTER JOIN "ext_management_systems" ON "ext_management_systems"."id" = "vms"."ems_id"
LEFT OUTER JOIN "snapshots" ON "snapshots"."vm_or_template_id" = "vms"."id"
LEFT OUTER JOIN "compliances" ON "compliances"."resource_id" = "vms"."id" AND "compliances"."resource_type" = $1
LEFT OUTER JOIN "operating_systems" ON "operating_systems"."vm_or_template_id" = "vms"."id"
LEFT OUTER JOIN "hardwares" ON "hardwares"."vm_or_template_id" = "vms"."id"
LEFT OUTER JOIN "taggings" ON "taggings"."taggable_id" = "vms"."id" AND "taggings"."taggable_type" = $2
LEFT OUTER JOIN "tags" ON "tags"."id" = "taggings"."tag_id"
WHERE "vms"."type" IN ('ManageIQ::Providers::InfraManager::Vm', 'ManageIQ::Providers::Microsoft::InfraManager::Vm', 'ManageIQ::Providers::Redhat::InfraManager::Vm', 'ManageIQ::Providers::Vmware::InfraManager::Vm', 'VmXen')
AND "vms"."template" = $3
Matthew Draper
@matthewd
Dec 01 2015 18:22
prepare q as select … and "vms"."template" = $3;
Keenan Brock
@kbrock
Dec 01 2015 18:22
I want to know if I remove the outer joins and the distinct - what would the query analyzer do?
Matthew Draper
@matthewd
Dec 01 2015 18:23
explain analyze execute q(.., .., 'foo');
Keenan Brock
@kbrock
Dec 01 2015 18:23
no way! (aka: cool)
Matthew Draper
@matthewd
Dec 01 2015 18:23
That can give a different query plan from select … "template" = 'foo';
Alex Krzos
@akrzos
Dec 01 2015 18:23
@matthewd Got it ExtManagementSystem.create(... was what I needed
Keenan Brock
@kbrock
Dec 01 2015 18:24
@matthewd that is true when the statistics on the table is changing and has changed since you prepared. or is that true in general?
Matthew Draper
@matthewd
Dec 01 2015 18:24
True in general
I mean.. relatively rare.. but very possible
Keenan Brock
@kbrock
Dec 01 2015 18:25
aah - with params, you don't have insight into the hueristics in the indexes, so can't make some assumptions/optimization
Matthew Draper
@matthewd
Dec 01 2015 18:25
Exactly; if it knows you're looking for the most/least frequent value, it can make a choice that could otherwise be disastrous
Keenan Brock
@kbrock
Dec 01 2015 18:25
yes
sybase stored the heuristics at compile time - but it looked them up on every query (~1997)
which caused problems for tables like metrics
again - that is probably different now - but that is one of my most impressionable databases.
there was a way to prepare with exec that would calculate up the huristics every time. but that was a hit - basically loosing a bunch of the benifit of prepared statements.
sorry - tangent
Matthew Draper
@matthewd
Dec 01 2015 18:28
I think PG was gaining some form of plan specialization thing around when I stopped paying attention a year ago… but dunno whether that's progressed
Keenan Brock
@kbrock
Dec 01 2015 18:28
yea - PG is oracle under the covers. (vs sybase / mssql) so that sometimes throws me
also, mysql is very different from pg, so a lot of plugins have steered the rails community incorrectly - things like select count(*) which is quick in mysql and slow in postgres.
Matthew Draper
@matthewd
Dec 01 2015 18:29
I'm pretty sure that'd offend a lot of people ;)
Keenan Brock
@kbrock
Dec 01 2015 18:29
:)
each one optimizes differently. bad when knowledge is obtained from the wrong source and assumptions are made
@jrafanie thanks for logging help. explains why sql comes across and then STOPS at select * from configurations...
Joe Rafaniello
@jrafanie
Dec 01 2015 18:31
;-)
It seems heavy handed but there was a need to configure the rails log level in the app
Years later, I'm sure there are better ways of doing it...
Keenan Brock
@kbrock
Dec 01 2015 18:33
years later we are learning what we can delete from the app
Joe Rafaniello
@jrafanie
Dec 01 2015 18:33
:fire: :fire:
Keenan Brock
@kbrock
Dec 01 2015 18:34
I sure want to pull apart/separate the vmdb / "configure everything" to different configuration per area (replication, rails in general, workers, branding, ...)
"tomorrow"
@matthewd in our sql, the prepared statement changes when :id => [1,2,3] changes. seems there would be a way to have postgres bind an array instead of generating the ids in the sql.
is that a limitation of rails, or the way we build sql?
Matthew Draper
@matthewd
Dec 01 2015 18:38
Rails. It's on a nice-to-fix list somewhere.
(Low priority because it can only help on PG)
.. patches welcome, of course ;)
Keenan Brock
@kbrock
Dec 01 2015 18:39
yes
of course
think it would be pretty slick actually
in our app, I wish we used more arrays vs join tables
Matthew Draper
@matthewd
Dec 01 2015 18:39
I think it's technically an Arel thing
Keenan Brock
@kbrock
Dec 01 2015 18:39
cool - thanks
not even in my "tomorrow" list
would prefer to use indexes for "validates uniqueness" vs sql query - not sure if that is in there yet
Keenan Brock
@kbrock
Dec 01 2015 18:55
@djberg96 speaking of sql fu. Is "metrics" (not "metrics_01") a sql table? is there a reason we wouldn't want an index on that?
Matthew Draper
@matthewd
Dec 01 2015 18:58
@kbrock does "it's empty" count?
Keenan Brock
@kbrock
Dec 01 2015 18:58
sounds like a great reason
Jason Frey
@Fryguy
Dec 01 2015 18:59
It's a parent table
It leverages table inheritance
It has no data and thus no indexes are needed
Keenan Brock
@kbrock
Dec 01 2015 19:00
yea - it is a "parent table"
cool
Jason Frey
@Fryguy
Dec 01 2015 19:01
er...partitioning, not inheritance
The child tables use inheritance for their column definitions, I think
See the triggers and checks on those tables for the exact details of how it works
Daniel Berger
@djberg96
Dec 01 2015 20:34
"A serious limitation of the inheritance feature is that indexes (including unique constraints) and foreign key constraints only apply to single tables, not to their inheritance children."
Jason Frey
@Fryguy
Dec 01 2015 20:35
right...so the parent table is not indexed, only the child tables
that is, you have index each one independently
Keenan Brock
@kbrock
Dec 01 2015 20:35
@djberg96 <snark>the easiest fix for this is drop table metrics*;</snark>
Daniel Berger
@djberg96
Dec 01 2015 20:36
:-P
Keenan Brock
@kbrock
Dec 01 2015 20:36
soon... soon...
Jason Frey
@Fryguy
Dec 01 2015 20:40
from that link that GregB listed, just noticed this: Atlas: https://github.com/Netflix/atlas
Netflix's cloud monitoring application
another interesting one: https://github.com/Netflix/vector
Keenan Brock
@kbrock
Dec 01 2015 21:33
1/2 second faster page loads
config/environment/development.rb: config.assets.debug = false