Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
84c71e5d
Commit
84c71e5d
authored
Nov 16, 2015
by
Marin Jankovski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add unique to oid index for lfs object.
parent
f445d3d1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
3 deletions
+9
-3
db/migrate/20151116144118_add_unique_for_lfs_oid_index.rb
db/migrate/20151116144118_add_unique_for_lfs_oid_index.rb
+7
-0
db/schema.rb
db/schema.rb
+2
-3
No files found.
db/migrate/20151116144118_add_unique_for_lfs_oid_index.rb
0 → 100644
View file @
84c71e5d
class
AddUniqueForLfsOidIndex
<
ActiveRecord
::
Migration
def
change
remove_index
:lfs_objects
,
:oid
remove_index
:lfs_objects
,
[
:oid
,
:size
]
add_index
:lfs_objects
,
:oid
,
unique:
true
end
end
db/schema.rb
View file @
84c71e5d
...
...
@@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord
::
Schema
.
define
(
version:
2015111
4113410
)
do
ActiveRecord
::
Schema
.
define
(
version:
2015111
6144118
)
do
# These are extensions that must be enabled in order to support this database
enable_extension
"plpgsql"
...
...
@@ -430,8 +430,7 @@ ActiveRecord::Schema.define(version: 20151114113410) do
t
.
string
"file"
end
add_index
"lfs_objects"
,
[
"oid"
,
"size"
],
name:
"index_lfs_objects_on_oid_and_size"
,
using: :btree
add_index
"lfs_objects"
,
[
"oid"
],
name:
"index_lfs_objects_on_oid"
,
using: :btree
add_index
"lfs_objects"
,
[
"oid"
],
name:
"index_lfs_objects_on_oid"
,
unique:
true
,
using: :btree
create_table
"lfs_objects_projects"
,
force:
true
do
|
t
|
t
.
integer
"lfs_object_id"
,
null:
false
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment