Commit Graph
139 Commits
Author SHA1 Message Date
Stan Hu a65de9c2c1 Reduce delay in destroying a project from 1-minute to immediately
Run ProjectDestroyWorker after pending_delete attribute has been committed to DB
2016-05-07 01:12:31 -07:00
Stan Hu 6dff1a9a2b Fix Error 500 due to stale cache when projects are renamed or transferred
Closes gitlab-org/gitlab-ee#506
2016-04-25 06:57:50 -07:00
Alfredo SumaranandJacob Schatz a96dc94428 Memoize target 2016-04-16 07:21:28 -04:00
Alfredo SumaranandJacob Schatz 1eeabdc6a5 Change variable name 2016-04-16 07:21:28 -04:00
Alfredo SumaranandJacob Schatz 05628e0c2f Fixes failing spec 2016-04-16 07:21:28 -04:00
Alfredo SumaranandJacob Schatz ad48ecacae Update method name and remove unneeded params 2016-04-16 07:21:28 -04:00
Alfredo SumaranandJacob Schatz 562c9652d6 Put owner and participating people first 2016-04-16 07:21:28 -04:00
Rémy Coutable 4a514b27e9 Merge branch 'issue_15155' into 'master'
Setup visibility level for project when transfering for a group

fixes #15155 

See merge request !3707
2016-04-14 15:13:08 +00:00
Felipe Artur a8ea2c1895 Change transfer service to use existing methods 2016-04-14 11:34:42 -03:00
Felipe Artur 11f46b459e Setup visibility level for project when transfering for a group 2016-04-13 15:28:10 -03:00
Yorick Peterse 3b9edce803 Instrument the HousekeepingService class
This allows us to track how much time is spent in updating the
"pushes_since_gc" column as well as the time needed to obtain the lease.
2016-04-13 15:31:13 +02:00
Douglas Barbosa Alexandre f2005fa566 Flush repository cache before import project data
GitHub Pull Requests importer handle with the repository while
importing data, we need to make sure that the cached values are valid.
2016-04-04 19:35:39 -03:00
Douwe Maan f505c753b0 Merge branch 'fix_remove_fork_link' into 'master'
Remove fork link closes all merge requests opened on source project

Currently, if you:

- create a fork
- open a merge request on the source project
- remove the fork link

The created MR cannot be closed.

With this MR, all pending MR is closed when the fork link is removed.

See merge request !3189
2016-04-04 15:37:08 +00:00
Baldinof a6b5b50e14 Fix incorrect variable name 2016-04-04 14:41:01 +00:00
Baldinof fa4126acff Move unlink fork logic to a service 2016-03-22 15:34:35 +01:00
Douwe Maan 8db1292139 Tweaks, refactoring, and specs 2016-03-20 21:04:07 +01:00
Douwe Maan 2eb19ea3ea Merge branch 'master' into issue_12658 2016-03-20 14:57:25 +01:00
Felipe Artur 8b830b8c3b Fix specs 2016-03-18 21:04:53 -03:00
Robert Speicher c790107854 Merge branch 'no-gc-retry' into 'master'
Do not retry "git gc"

To prevent 'git gc' timing out on a large repo and then bouncing
around in the retry queue.

See merge request !3266
2016-03-18 20:26:40 +00:00
Zeger-Jan van de WegandFelipe Artur b959ae553b Improve group visibility level feature 2016-03-18 16:58:04 -03:00
Douglas Barbosa Alexandre 7ee528336a Restrict access for confidential issues on autocomplete 2016-03-17 20:55:59 -03:00
Jacob Vosmaer 2057bc02a3 Do not retry "git gc" 2016-03-17 11:02:11 +01:00
Felipe Artur 44c127447b Merge 4009-external-users into issue_12658 2016-03-16 20:16:42 -03:00
Felipe Artur ec20fdf366 Code improvements and add Create group service 2016-03-16 19:44:33 -03:00
Jacob Vosmaer 30b36c92c3 Use an exception to pass messages 2016-03-15 11:03:43 +01:00
Jacob Vosmaer 021d53c96d Run 'git gc' every 10 pushes 2016-03-14 16:49:24 +01:00
Jacob Vosmaer a02fe251df Allow project housekeeping only once an hour 2016-03-14 15:55:45 +01:00
Felipe Artur c3e70280df Prevent projects to have higher visibility than groups
Prevent Groups to have smaller visibility than projects
Add default_group_visibility_level to configuration
Code improvements
2016-03-10 10:38:36 -03:00
Yorick Peterse ff28a7cc36 Moved cache expiration code to Repository hooks
This keeps all the cache expiration code in a single file/class instead
of spreading it all across the codebase.
2016-02-23 12:02:59 +01:00
Yorick Peterse b1203108b0 Flush all repository caches when deleting a repo
This ensures that _all_ caches (including any caches normally only
flushed under certain conditions) are flushed whenever a project is
removed. Because cache keys are based on project namespaces (excluding
IDs) not doing so could result in a newly created project re-using old
caches (if the project was re-created using the same name).
2016-02-17 11:38:18 +01:00
Josh Frye 91b9cbff8d First pass at deleting projects in the background. 2016-01-29 09:14:16 -05:00
Douglas Barbosa Alexandre c040323419 Move Gitlab::BitbucketImport::KeyDeleter to it's own importer 2016-01-26 10:56:22 -02:00
Douglas Barbosa Alexandre 6dd88e090e Extract Projects::ImportService service from RepositoryImportWorker 2016-01-25 22:58:30 -02:00
Douglas Barbosa Alexandre 096485ef65 Creator should be added as a master of the project on creation
This also enable a project creator to add themselves as a master of the
project.
2016-01-20 20:06:28 -02:00
Douglas Barbosa Alexandre 2ece1b774a Fix creator should be added as a master of the project on creation 2016-01-19 13:24:42 -02:00
Jeroen Nijhof 706255b926 Merge gitlab.com:gitlab-org/gitlab-ce 2016-01-11 09:32:35 +01:00
Douwe Maan 0614793b38 DRY up upload and download services 2016-01-08 17:38:53 +01:00
Douwe Maan 1886d727f7 Add API project upload endpoint 2016-01-07 13:37:14 +01:00
Jeroen Nijhof 9b28220f88 Merge gitlab.com:gitlab-org/gitlab-ce 2016-01-06 14:55:44 +01:00
Steve Norman 79ec7f2897 Added system hooks messages for renaming and transferring a project 2016-01-04 13:48:00 +00:00
Tomasz Maczukin 3cfd892f38 Merge branch 'master' into fix/visibility-level-setting-in-forked-projects
* master: (723 commits)
  Bump Rack Attack to v4.3.1 for security fix
  Remove duplicate entry in the changelog
  Remove extra spaces after branchname
  Fix merge-request-reopen button title
  Add branch and tag operation to tree dropdown
  Use gitlab-shell 2.6.9
  Clarify Windows shell executor artifact upload support
  Fix feature specs: we always show the build status if ci_commit is present
  Do not display project group/name when issue and MR are in same project
  Don't create CI status for refs that doesn't have .gitlab-ci.yml, even if the builds are enabled
  Use gitlab-workhorse 0.5.1
  Fix ci_projects migration by using the value only from latest row [ci skip]
  Revert sidebar position for issue and merge request
  Add info on using private Docker registries in CI [ci skip]
  Upgrade Poltergeist to 1.8.1. #4131
  Fix ux issue with "This issue will be closed automatically" message
  Move MR Builds tab next to Commits
  Api support for requesting starred projects for user
  Fix Rubocop complain.
  Fix merge widget JS for buttons
  ...

Conflicts:
	app/models/project.rb
2015-12-21 13:27:34 +01:00
Kamil Trzciński c810234357 Merge branch 'ci-project-migrate' into 'master'
Ci Project migrate

- This doesn't migrate: allow_git_fetch, coverage_regex, timeout. Since this are project configuration settings I would propose to migrate them to `.gitlab-ci.yml`.
- This requires offline migrations.
- It simplifies database models making all CI objects to be attached to: Project.
- It removes Ci::Project, but makes /ci/projects working by adding method: Project.find_by_ci_id for backward compatibility (badges, triggers).
- We should add default `timeout` to Application Settings.
- It misses specs.
- It is based on ci-services-migrate for now.
- It removes CI events.
- It removes administrator CI projects overview.
- It removes CI application settings.

In 8.4 or 8.5 we can remove redundant tables and columns.


See merge request !1987
2015-12-14 10:35:40 +00:00
Kamil Trzcinski e80e3f5372 Migrate CI::Project to Project 2015-12-11 18:02:09 +01:00
Stan Hu 8d5527007a Provide better diagnostic message upon project creation errors
Prevents an Error 500 when project fails to create due to invalid parameters.

See #3937
2015-12-09 09:50:16 -08:00
Tomasz Maczukin 85ad95be74 Merge branch 'master' into fix/visibility-level-setting-in-forked-projects
* master: (296 commits)
  fox tests
  Don't rescue Exception, but StandardError
  adressing comments
  Update gitlab-shell documentation [ci skip]
  Align hash literals in IssuesFinder spec
  Fix tests
  Fix 'Attach a file' link in new tag form
  Add link to git-lfs client  [ci skip]
  Do not limit workhorse POST/PUT size in NGINX
  added specs
  added spinach tests
  Since GitLab CI is enabled by default, remove enabling it by pushing .gitlab-ci.yml
  Fix tests
  Commits without .gitlab-ci.yml are marked as skipped
  Changelog entry for finding issues performance
  Use a JOIN in IssuableFinder#by_project
  Memoize IssuableFinder#projects
  Removed trailing whitespace from IssuableFinder
  Added benchmark for IssuesFinder
  Updated DB schema with new issues/projects indexes
  ...

Conflicts:
	app/models/project.rb
2015-11-20 00:29:04 +01:00
Tomasz Maczukin 1144b70ab6 Change update_forks_visibility_level into after_update hook in Project model 2015-11-20 00:13:56 +01:00
Tomasz Maczukin 945e4293cb Prevent unnecessary forks iteration at parent update 2015-11-19 23:40:29 +01:00
Jeroen Nijhof d4690af8bc Use GitlabShellWorker.perform_async for housekeeping 2015-11-19 16:04:07 +01:00
Jeroen Nijhof 839aae0e47 Added housekeeping status and moved path check to gitlab-shell 2015-11-19 15:16:54 +01:00
Tomasz Maczukin 6f41e3d9ca Change forks method to has_many relation 2015-11-18 22:11:15 +01:00