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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
a9155a94
Commit
a9155a94
authored
Nov 22, 2017
by
Michael Kozono
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor
parent
8def25d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
10 deletions
+3
-10
lib/gitlab/background_migration/prepare_untracked_uploads.rb
lib/gitlab/background_migration/prepare_untracked_uploads.rb
+3
-10
No files found.
lib/gitlab/background_migration/prepare_untracked_uploads.rb
View file @
a9155a94
...
...
@@ -44,16 +44,10 @@ module Gitlab
t
.
string
:path
,
limit:
600
,
null:
false
t
.
boolean
:tracked
,
default:
false
,
null:
false
t
.
timestamps_with_timezone
null:
false
t
.
index
:path
,
unique:
true
t
.
index
:tracked
end
end
unless
UntrackedFile
.
connection
.
index_exists?
(
:untracked_files_for_uploads
,
:path
)
UntrackedFile
.
connection
.
add_index
:untracked_files_for_uploads
,
:path
,
unique:
true
end
unless
UntrackedFile
.
connection
.
index_exists?
(
:untracked_files_for_uploads
,
:tracked
)
UntrackedFile
.
connection
.
add_index
:untracked_files_for_uploads
,
:tracked
end
end
def
clear_untracked_file_paths
...
...
@@ -140,8 +134,7 @@ module Gitlab
end
def
postgresql_pre_9_5?
@postgresql_pre_9_5
||=
postgresql?
&&
ActiveRecord
::
Base
.
connection
.
select_value
(
'SHOW server_version_num'
).
to_i
<
90500
@postgresql_pre_9_5
||=
postgresql?
&&
Gitlab
::
Database
.
version
.
to_f
<
9.5
end
def
schedule_populate_untracked_uploads_jobs
...
...
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