1

I'm trying to speed up my django unit test, so I wrote custom database backend using for test purposes another tablespace located in memory. But I found no real advantages, the time my test running in memory remains the same.

Then I created two similar tables using different tablespaces and run 10000 inserts for the each one. Time for the both queries was about 1 sec.

Am I missing something? Why database located in memory doesn't shows performance grow?

1
  • have you tried making your backend such that it never creates any indexes? Commented Sep 24, 2010 at 14:02

1 Answer 1

1

For inserts, you were most likely just limited by the writes to the transaction log (pg_xlog). This is not affected by you moving the tables to a different tablespace. That only comes into effect once you write enough data to go beyond what fits in the cache and/or when you run a checkpoint in the test - and 10,000 rows and 1 second is nowhere near enough to reach that.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.