-
Notifications
You must be signed in to change notification settings - Fork 386
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
added/updated postgresql implementation of log_storage #1571
Merged
Merged
Changes from all commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
7abee92
added/updated postgresql implementation of log_storage
bigjimnolan c9ac881
reverted some test code to make commit compatible with integration te…
bigjimnolan af2cb5a
Typo fix in db code
bigjimnolan d12bba1
udpated queue batching code to work for postgres
bigjimnolan b79e24e
updated code using gofmt and goimport
bigjimnolan 86a2de4
more format fixing
bigjimnolan 93301be
Made updates referenced in pull request. Added test coverage for log…
bigjimnolan 733e86f
Updated test code to explicitly declare funtion for AddLeaf call
bigjimnolan ed19758
Updated test code and fixed methodology for pushing sql code into dat…
bigjimnolan 55b8240
Updated log storage and added some more testing
bigjimnolan 7509c43
Trying to fix this odd error with compact.VisitFn
bigjimnolan 628a6a3
ignoring test for now
bigjimnolan 5e21ca2
used goimports
bigjimnolan b3d4fcd
updated for lint checks
bigjimnolan 44b41c4
fixing goimport random gripe
bigjimnolan bde1d03
must be a different copy of goimports on the server
bigjimnolan b3767ad
lint fixes?
bigjimnolan a028c8b
Seeing if this is the issue with goimports
bigjimnolan d80b158
will this pass the lint check?
bigjimnolan 8c98f37
will this pass the lint check?
bigjimnolan a424960
will this pass the lint check 3/?
bigjimnolan 620357d
removed some more commented code; added some more error checking
bigjimnolan bab9462
removed some more old code
bigjimnolan 33a71fc
updating storage_test
bigjimnolan a23c318
manual update to master
bigjimnolan 1004e83
Added warning about experimental nature of PostgreSQL support
bigjimnolan a750242
Update storage/postgres/README.md
bigjimnolan 1acdaa0
Update storage/postgres/README.md
bigjimnolan 59837d6
Update storage/postgres/storage.sql
bigjimnolan 16137cd
Update storage/postgres/storage_test.go
bigjimnolan e70d3ea
Update storage/postgres/storage_test.go
bigjimnolan 7bfb409
Apply suggestions from code review
bigjimnolan e5807c5
Made updates based on pull request comments
bigjimnolan 714e7fb
updated readme.txt
bigjimnolan 96f9796
Merge branch 'master' of https://github.com/bigjimnolan/trillian
bigjimnolan 3ff3939
udpated readme to restart build
bigjimnolan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# Postgres LogStorage | ||
|
||
## Notes and Caveats | ||
The current LogStorage part of the Postgres implementation was based off what | ||
was already written for MySQL. Thus, the two user-defined functions included in | ||
storage.sql. MySQL doesn't kill a transaction when a duplicate is detected, but | ||
PostgreSQL does. So, to preserve the workflow, I included the two functions | ||
which trap this error and allow the code to continue executing. The only other | ||
change I made was to fully translate the MySQL queries to PostgreSQL compatible ones | ||
and tidy up some of the extant tree storage code. | ||
|
||
storage_unsafe.sql really isn't unsafe, but I have pulled some of the safety | ||
rails from the tables to improve performance. It also works under the notion that | ||
bigjimnolan marked this conversation as resolved.
Show resolved
Hide resolved
|
||
there will only be a single tree in a given database. An improvement on this theme | ||
would be to add all layers below the trees table in their own separate schemas. | ||
This would further eliminate indexs and foreign key requirements, but it should | ||
be left for those who require enhanced performance. Storage.sql should be fine for most applications |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why did we lose the comments from some of these lines?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These comments were causing the server-side goimports to fail. I have no idea why. They checked out just fine on my local side. When I removed them, the autobuild succeeded. I have no problem with someone putting them back in.