Commit graph

90 commits

Author SHA1 Message Date
Marcin Kuzminski
7966d6abb4 svn: fix usage of http exception from webob to pyramid one.
Webob exception had an condition that was unfilled for svn causing unexpected 500s.
2018-05-28 17:13:59 +02:00
Marcin Kuzminski
bdf5f0afb6 svn: enable hooks and integration framework execution.
- This change will allow SVN to execute rhodecode integration framework
via executing the builting hooks.
- uses txn_id for svn to provide metadata required via Apache
- Interception of SVN transaction is required to use temporary stores for metadata
- hooks are now part of vcsserver where the install/control logic is stored
2018-04-06 12:44:01 +02:00
Marcin Kuzminski
9c4a8f1afd http: improved log for ssl required 2018-02-18 11:35:35 +01:00
Marcin Kuzminski
ba5aec079a caches: use individual namespaces per user to prevent beaker caching problems.
- especially for mysql in case large number of data in caches there could be critical errors storing cache, and thus preventing
users from authentication. This is caused by the fact that we used single namespace for ALL users. It means it grew as number of users grew
reaching mysql single column limit.
This changes the behaviour and now we use namespace per-user it means that each user-id will have it's own cache namespace fragmenting maximum column data to
a single user cache. Which we should never reach.
2018-02-15 17:34:09 +01:00
Marcin Kuzminski
b16521f1c3 simplevcs: allow passing config into repo detection logic.
- allows proper check for repos together with requirement checks for Mercurial
2018-02-01 18:51:00 +01:00
Marcin Kuzminski
00b45c1fa7 release: update copyright year to 2018 2018-01-19 17:13:16 +01:00
Marcin Kuzminski
1fccd17a6d auth, performance: use cache_ttl for anonymous access taken from the rhodecode plugin.
- for operations like svn this boosts performance significantly for anonymous access enabled.
2017-12-04 14:20:53 +01:00
Marcin Kuzminski
539e88e6c6 svn: extend detection of SVN to PROPFIND/PROPATCH methods.
- in some cases like usage of tortoisesvn non of the available SVN
protocol detection methods are available
- with extended method we're able to catch directory delete/create
2017-11-27 18:51:25 +01:00
Marcin Kuzminski
245d213bf2 vcs: also register a global config for vcs_handler.
- this solves a case when SVN repository needs to find out a repo without
per-repo settings available
- we need to get the global config first to be able to extract repo name
2017-11-28 13:23:25 +01:00
Marcin Kuzminski
97dadd2f8b svn: log response code for SVN calls always even for 200 codes. 2017-11-27 18:45:50 +01:00
Marcin Kuzminski
098d879432 svn: pass in explicit SCM into the call function for faster detection of protocol. 2017-11-27 18:56:44 +01:00
Marcin Kuzminski
d3b43c92fc simplevcs: store rc_extras reference inside the apps itself so it can be used during
operations.
2017-11-22 16:25:30 +01:00
Marcin Kuzminski
a55c5ff1ea simplevcs: handle a case of damaged filesystem repo without 500 exception. 2017-11-16 16:31:18 +01:00
Marcin Kuzminski
4d9fa48377 simplevcs: fixed logic of extraction of base_path 2017-11-16 15:59:11 +01:00
Marcin Kuzminski
5f9ae2ae11 pylons: remove pylons as dependency
- dependencies: bumped:
 -setuptools-scm==1.15.6
 -celery==4.1.0
 -kombu==4.1.0
 -pytz==2017.3
 -Routes==2.4.1

Removed all pylons components. Refactored the code to use only pyramid
parts
2017-11-15 13:42:54 +01:00
Marcin Kuzminski
7781eabe94 auth: use cache_ttl from a plugin to also cache permissions.
- this gives a 30% speed increase in operations like svn commit
- generally uses the same mechanismy like auth cache to cache permissions for faster
access to vcs commands
2017-10-07 10:02:39 +02:00
Marcin Kuzminski
f445addfdd vcs: reduce sql queries used during pull/push operations. 2017-09-28 21:45:19 +02:00
Marcin Kuzminski
3f0ff6b65b vcs: report 404 for shadow repos that are not existing anymore. Before we got 500 exception in this case. 2017-09-01 13:10:52 +02:00
Marcin Kuzminski
858b640885 http-app: adds some logging. 2017-07-28 02:42:52 +02:00
Daniel Dourvaris
93b6dfba9a gists: migrated gists controller to pyramid view. 2017-07-07 12:05:30 +02:00
Marcin Kuzminski
175cd5d4db audit-logs: log user agent for push/pull. 2017-04-28 21:03:00 +02:00
Marcin Kuzminski
479c786358 http-app: simplify detection of chunked encoding.
- since we now properly use chunked requests git client reports this in nicer way.
we no longer need to rely on hacks to detect chunked streams.
2017-04-18 09:31:49 +02:00
Marcin Kuzminski
93bb2a8b36 svn: escape special chars to allow interactions with non-standard svn paths.
- fixes #4306
2017-04-03 13:40:39 +02:00
Marcin Kuzminski
e7fd657687 git-lfs: push settings to git-lfs backend stored inside our rhodecode settings
- fixes #4235
2017-03-21 11:58:56 +01:00
Marcin Kuzminski
f7aa78c7e1 git-lfs: streaming support for file upload.
- ref #4235
2017-03-21 14:37:47 +01:00
Marcin Kuzminski
1e7801cf57 git-lfs: enable support for detection of git-lfs requests type
- fixes #4235
2017-03-18 12:22:37 +01:00
Marcin Kuzminski
58fe679096 http-app: prevent httplib3 logs to spawn our rhodecode logs.
- it often happens that there are odd logs, and it confuses people looking at those.
2017-03-15 17:30:14 +01:00
Marcin Kuzminski
8732733a54 authentication: enabled authentication with auth_token and repository scope.
- fixes #3932
- vcs type tokens now with repo scope narrows the usage to a repository.
2017-03-03 20:48:23 +01:00
Marcin Kuzminski
cfa10105b7 core: properly handle new redirections set in decorators.
- Allows easier full pyramid migration
2017-03-02 16:10:47 +01:00
Marcin Kuzminski
886cc7d28b http-proto: in case incoming requests come in as chunked stream the data to VCSServer.
This should solve a problem of uploading large files to rhodecode. In case of
git with small postBuffers GIT client streams data to the server. In such
case we want to stream the data back again to vcsserver without reading it fully
inside RhodeCode.
2017-02-10 16:25:06 +01:00
Marcin Kuzminski
3d3f2db34a core: removed pyro4 from Enterprise code. Fixes #5198 2017-02-07 15:58:49 +01:00
Marcin Kuzminski
4c2c087cf8 core: let pyramid handle tracebacks for all exceptions.
Otherwise we'll miss exception caused in pure pyramid view.
2017-01-12 23:36:07 +01:00
Marcin Kuzminski
584bd214ae vcs: do an early detection of vcs-type request.
We we to know to detect vcs type request as early as possible. IF we know
we're handling an VCS request, we can skip some of the pylons stack initialization.

- This fixes issues with leaking sessions and other object from pylons into
a purely VCS type request.
2017-01-12 01:20:31 +01:00
Marcin Kuzminski
fcc027c282 license: updated copyright year to 2017 2017-01-02 09:30:39 +01:00
Marcin Kuzminski
90deb7d32c vcs-server: expose remote tracebacks from http backend using the Pyro4AwareFormatter. 2016-12-21 12:43:47 +01:00
Marcin Kuzminski
fab9234763 svn-support: enable better logging of handled SVN commands. 2016-12-12 18:24:43 +01:00
Marcin Kuzminski
d5210dfe63 simplevcs: fix a typo when running detection of vcs backend.
- the flag should be explicit_scm which skips detection of VCS systems.
This improves the speed of calls by not trying to look for a valid vcs.
2016-11-17 18:48:31 +01:00
Martin Bornhold
10181aa8e6 vcs: Send custom repo-locked status code to the VCSServer. 2016-10-10 16:07:15 +02:00
Martin Bornhold
add98db605 vcs: Add a comment about removing some code when dropping Pyro4 support. 2016-10-10 14:06:26 +02:00
Martin Bornhold
d3b91c664e vcs: Include reason phrase from VCSServer into HTTP status string. 2016-10-10 13:58:52 +02:00
Martin Bornhold
dff5dd52e0 http: Allow http, pyro and custom implementations for scm app. 2016-10-04 12:01:10 +02:00
Martin Bornhold
ecc24326d7 vcs: Do not pass the backend key into the scm app instances.
We used the key as a value for a response header. Since this header is removed there
is no need to pass the backend key araound.
2016-10-06 16:25:27 +02:00
Martin Bornhold
c6466346b4 vcs: Remove custom response header which contains backend key.
We used this custom header to skip the error handling.
This is no linger needed since the VCS middleware is moved above of the error handling.
2016-10-06 16:10:40 +02:00
Martin Bornhold
1a3f93ca85 error-handling: Remove if condition to check if the response is a vcs response.
We moved the VCS middleware out of the error handling. Therefore we don't need to skip the error handling anymore.
2016-10-06 16:08:34 +02:00
Martin Bornhold
861adffd82 tests: Add a way to deactivate exception re-raising in tests. 2016-10-07 09:15:43 +02:00
Martin Bornhold
b213d2244c wsgi-stack: Refactor the error handling view into a middleware class. 2016-10-06 12:01:57 +02:00
Martin Bornhold
acc2367ab9 shadow: Simplyfy the regular expression for detecting shadow repository URLs 2016-09-28 13:25:57 +02:00
Martin Bornhold
5eeb75edac shadow: Fix an error in the regex to detect shadow repository URLs. 2016-09-26 14:54:21 +02:00
Martin Bornhold
9efcbadac8 vcs: Explicit use one of the repo names (acl, url, vcs) 2016-09-23 13:23:32 +02:00
Martin Bornhold
2cd4d08392 vcs: Clean up the shadow-repo-expose code and make some nicer comments. 2016-09-23 12:52:24 +02:00