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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
452f7fec
Commit
452f7fec
authored
Aug 18, 2017
by
Douglas Barbosa Alexandre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Drop unnecessary timestamp columns in Geo event tables
parent
e4424496
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
4 deletions
+20
-4
db/migrate/20170818174141_drop_unnecessary_timestamp_columns_in_geo_event_tables.rb
...drop_unnecessary_timestamp_columns_in_geo_event_tables.rb
+19
-0
db/schema.rb
db/schema.rb
+1
-4
No files found.
db/migrate/20170818174141_drop_unnecessary_timestamp_columns_in_geo_event_tables.rb
0 → 100644
View file @
452f7fec
class
DropUnnecessaryTimestampColumnsInGeoEventTables
<
ActiveRecord
::
Migration
include
Gitlab
::
Database
::
MigrationHelpers
DOWNTIME
=
false
disable_ddl_transaction!
def
up
remove_column
:geo_repository_deleted_events
,
:created_at
remove_column
:geo_repository_deleted_events
,
:updated_at
remove_column
:geo_repository_updated_events
,
:created_at
end
def
down
add_column
:geo_repository_deleted_events
,
:created_at
,
:datetime_with_timezone
add_column
:geo_repository_deleted_events
,
:updated_at
,
:datetime_with_timezone
add_column
:geo_repository_updated_events
,
:created_at
,
:datetime_with_timezone
end
end
db/schema.rb
View file @
452f7fec
...
...
@@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord
::
Schema
.
define
(
version:
2017081
1203342
)
do
ActiveRecord
::
Schema
.
define
(
version:
2017081
8174141
)
do
# These are extensions that must be enabled in order to support this database
enable_extension
"plpgsql"
...
...
@@ -705,8 +705,6 @@ ActiveRecord::Schema.define(version: 20170811203342) do
t
.
text
"deleted_path"
,
null:
false
t
.
text
"deleted_wiki_path"
t
.
text
"deleted_project_name"
,
null:
false
t
.
datetime_with_timezone
"created_at"
,
null:
false
t
.
datetime_with_timezone
"updated_at"
,
null:
false
end
add_index
"geo_repository_deleted_events"
,
[
"project_id"
],
name:
"index_geo_repository_deleted_events_on_project_id"
,
using: :btree
...
...
@@ -726,7 +724,6 @@ ActiveRecord::Schema.define(version: 20170811203342) do
add_index
"geo_repository_renamed_events"
,
[
"project_id"
],
name:
"index_geo_repository_renamed_events_on_project_id"
,
using: :btree
create_table
"geo_repository_updated_events"
,
id: :bigserial
,
force: :cascade
do
|
t
|
t
.
datetime
"created_at"
,
null:
false
t
.
integer
"branches_affected"
,
null:
false
t
.
integer
"tags_affected"
,
null:
false
t
.
integer
"project_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