<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/gitlab/gitlab-ce.git/db/migrate/20140407135544_fix_namespaces.rb, branch user-inline-scripts</title>
<subtitle>gitlab.com: gitlab-org/gitlab-ce.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/gitlab/gitlab-ce.git/'/>
<entry>
<title>Fix bug where destroying a namespace would not always destroy projects</title>
<updated>2016-08-11T22:36:35+00:00</updated>
<author>
<name>Stan Hu</name>
<email>stanhu@gmail.com</email>
</author>
<published>2016-05-29T02:54:17+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/gitlab/gitlab-ce.git/commit/?id=cb8a425ba42e9be23b8712ed29b1db2dcc6bd139'/>
<id>cb8a425ba42e9be23b8712ed29b1db2dcc6bd139</id>
<content type='text'>
There is a race condition in DestroyGroupService now that projects are deleted asynchronously:

1. User attempts to delete group
2. DestroyGroupService iterates through all projects and schedules a Sidekiq job to delete each Project
3. DestroyGroupService destroys the Group, leaving all its projects without a namespace
4. Projects::DestroyService runs later but the can?(current_user,
   :remove_project) is `false` because the user no longer has permission to
   destroy projects with no namespace.
5. This leaves the project in pending_delete state with no namespace/group.

Projects without a namespace or group also adds another problem: it's not possible to destroy the container
registry tags, since container_registry_path_with_namespace is the wrong value.

The fix is to destroy the group asynchronously and to run execute directly on Projects::DestroyService.

Closes #17893
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There is a race condition in DestroyGroupService now that projects are deleted asynchronously:

1. User attempts to delete group
2. DestroyGroupService iterates through all projects and schedules a Sidekiq job to delete each Project
3. DestroyGroupService destroys the Group, leaving all its projects without a namespace
4. Projects::DestroyService runs later but the can?(current_user,
   :remove_project) is `false` because the user no longer has permission to
   destroy projects with no namespace.
5. This leaves the project in pending_delete state with no namespace/group.

Projects without a namespace or group also adds another problem: it's not possible to destroy the container
registry tags, since container_registry_path_with_namespace is the wrong value.

The fix is to destroy the group asynchronously and to run execute directly on Projects::DestroyService.

Closes #17893
</pre>
</div>
</content>
</entry>
<entry>
<title>Enable RuboCop for migrations</title>
<updated>2016-06-09T15:05:25+00:00</updated>
<author>
<name>Sean McGivern</name>
<email>sean@gitlab.com</email>
</author>
<published>2016-06-09T12:39:16+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/gitlab/gitlab-ce.git/commit/?id=98bb435f4266719b1e0fca57472a0f4e50d30371'/>
<id>98bb435f4266719b1e0fca57472a0f4e50d30371</id>
<content type='text'>
Migrations shouldn't fail RuboCop checks - especially lint checks, such
as the nested method check. To avoid changing code in existing
migrations, add the magic comment to the top of each of them to skip
that file.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Migrations shouldn't fail RuboCop checks - especially lint checks, such
as the nested method check. To avoid changing code in existing
migrations, add the magic comment to the top of each of them to skip
that file.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add trailing newline to all text files.</title>
<updated>2014-06-21T09:20:22+00:00</updated>
<author>
<name>Ciro Santilli</name>
<email>ciro.santilli@gmail.com</email>
</author>
<published>2014-06-21T09:18:57+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/gitlab/gitlab-ce.git/commit/?id=a7e0ca9e83851ae573eb19a977814f550b07f44f'/>
<id>a7e0ca9e83851ae573eb19a977814f550b07f44f</id>
<content type='text'>
Present in the large majority of files of each respective type.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Present in the large majority of files of each respective type.
</pre>
</div>
</content>
</entry>
<entry>
<title>add a space</title>
<updated>2014-04-07T14:26:52+00:00</updated>
<author>
<name>Job van der Voort</name>
<email>job@gitlab.com</email>
</author>
<published>2014-04-07T14:26:52+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/gitlab/gitlab-ce.git/commit/?id=52cf11b9f2f22218abd79aa3936ddb7f0d6cee59'/>
<id>52cf11b9f2f22218abd79aa3936ddb7f0d6cee59</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix faulty namespaces</title>
<updated>2014-04-07T14:03:49+00:00</updated>
<author>
<name>Job van der Voort</name>
<email>job@gitlab.com</email>
</author>
<published>2014-04-07T14:03:49+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/gitlab/gitlab-ce.git/commit/?id=6d196962670b35ea48588aad3cfdb6f2d11febab'/>
<id>6d196962670b35ea48588aad3cfdb6f2d11febab</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
