12097 Commits

Author SHA1 Message Date
CES Marvin
264fd6b048 Release version 2.24.0 2.24.0 2021-10-07 14:23:06 +00:00
Konstantin Schaper
5902afc005 Adjust changelog for release 2.24.0 2021-10-07 15:01:17 +02:00
Sebastian Sdorra
47249bffba Add osx package to release flow (#1822)
Triggers the build job which updates the scm-server formula of the scm-manager homebrew-tap as part of the scm-manager release build job.
2021-10-07 14:41:34 +02:00
René Pfeuffer
41b8f091c0 Add recursive deletion in modify command (#1821)
Adds a method in the ModifyCommand to delete not only files, but also directories recursively.
2021-10-07 14:40:48 +02:00
Sebastian Sdorra
d1de7bf214 Clear external group cache on explicit logout or user deletion (#1819)
Clears the external group cache whenever a user gets logged out by the logout rest method or the user gets deleted.

Co-authored-by: Eduard Heimbuch <eduard.heimbuch@cloudogu.com>
2021-10-06 14:34:10 +02:00
Sebastian Sdorra
1318f40e6d Fix bugs in svn and source tree for folders with a % in the name (#1818)
* Update svnkit to 1.10.3-scm1 to fix handling of path with % in the name
* Fix source tree and breadcrumb navigation for folders with a % in the name
2021-10-04 11:19:25 +02:00
René Pfeuffer
dbdf814d23 Add status code 401 to test rest dispatcher 2021-10-01 18:17:40 +02:00
Sebastian Sdorra
f5d9855a24 Add extension points for source tree (#1816)
This change will add an extension point which allows to wrap the source tree. This is required in order to use a context provider e.g. to capture a selected file. Another extension point allows to add a row between the row of a file.
In order to implement the extension points ui-extensions has now a wrapper property and passes the children of an extension point to implementing extension.
2021-09-30 16:41:04 +02:00
René Pfeuffer
2b85081032 Make EMail computation available for DisplayUser (#1815)
Adds an internal api call to determine a email address for a DisplayUser instance
in class EMail. This was available only for the User class before, but there is no
reason, why this should be limited.

Additionally one can also set the author for the merge command as DisplayUser,
which will trigger the fallback mechanisms for the email address, if it is missing.

This is introduced to make merge commits possible for users without email addresses
in the review plugin (scm-manager/scm-review-plugin#149).
2021-09-30 14:32:31 +02:00
Eduard Heimbuch
922dc27c49 Add delete method for configuration store (#1814)
Add method to delete configuration stores completely.
2021-09-30 08:54:22 +02:00
René Pfeuffer
f6de626cd5 Fix edge cases in mirror command (#1812)
- The clone of the repository failed, if no master branch had
  been mirrored, because this was what the HEAD was set to, and
  jgit fails with an exception if the HEAD branch does not exist.
- The HEAD branch had to be corrected to an existing branch,
  because otherwise a rejected 'master' branch could not be
  deleted and was synchronized in a second sync if the working
  directory had been cached.
2021-09-28 09:54:14 +02:00
Sebastian Sdorra
24effd9041 Fix deletion of repositories from search index (#1813) 2021-09-27 13:15:29 +02:00
Florian Scholdei
ad2dfa42fd Fix DangerZone spacing 2021-09-24 16:38:55 +02:00
Florian Scholdei
cf7664ad1f Update Button.tsx 2021-09-16 17:56:04 +02:00
Florian Scholdei
2cb006d040 Replace styled-components with bulma helpers (#1783)
Use Bulma helpers whenever possible instead of custom styled components.
This pull request replaces primarily color definitions, spacing and flex instructions.
2021-09-15 17:40:08 +02:00
Eduard Heimbuch
8a65660278 Auto mapper binding (#1807)
Bind mapper implementations automatically to related mappers using the annotation processor. With this change it is not longer required to bind mapper explicitly using mapper modules which reduces some boilerplate code.
2021-09-14 09:26:47 +02:00
René Pfeuffer
e1ff57e0a9 Fix API description for url import (#1805) 2021-09-13 07:35:17 +02:00
Eduard Heimbuch
4cd7fb622a Initialize mercurial logger (#1804)
Use own logger for mercurial internal commands. This prevents log overflow by javahg's JULLogger.
2021-09-10 10:27:21 +02:00
CES Marvin
a95a18512d Prepare for next development iteration 2021-09-08 12:07:31 +00:00
CES Marvin
ae699571f3 Release version 2.23.0 2.23.0 2021-09-08 11:42:03 +00:00
Eduard Heimbuch
1fa591a381 Adjust changelog for release 2.23.0 2021-09-08 13:20:37 +02:00
Sebastian Sdorra
5b4d032611 Fix query for enum fields (#1800)
The enum fields were not searchable, because they were stored without analysation or transformation, but if an enum field was searched for within a query, the StandardAnalyzer was used. This means that the enum was stored in the index as an uppercase string, but the query searches for lowercase (the StandardAnalyzer uses a lowercase filter).
To fix this problem we are now using the KeywordAnalyzer for every non tokenized field. The StandardAnalyzer is only used for tokenized fields, which does not specify an other analyzer such code, path or id.
For enum fields we have introduced a new analyzer which uses an uppercase filter by default, this makes it possible to ignore case during search for enum fields.
2021-09-08 10:56:57 +02:00
Sebastian Sdorra
49dfd66a4f Disable chromatic (#1801) 2021-09-08 09:59:51 +02:00
Sebastian Sdorra
92fa67e937 Fix missing encoding of useBranch hook (#1798) 2021-09-08 07:45:41 +02:00
Eduard Heimbuch
059f1aeab0 Add community link to README.md (#1796) 2021-09-07 09:54:17 +02:00
Eduard Heimbuch
64b03d6ded Fix illegal access from plugin to core api. 2021-09-06 15:21:53 +02:00
René Pfeuffer
13d72d45c6 Prevent multiple instances of working copy pool (#1797)
The working copy pool has to be a singleton, because
otherwise there could be multiple instances with their
own caches and therefore no reuse and maybe more relevant
working directories that will never be deleted.
2021-09-06 08:40:22 +02:00
Sebastian Sdorra
856315a15f Fix broken login page if login info response could not be parsed (#1795) 2021-09-06 08:33:24 +02:00
Eduard Heimbuch
43e1ea06c8 Fix HalRepresentationWithEmbedded type (#1793)
Fix HalRepresentationWithEmbedded type since _embedded can be null.

Co-authored-by: Sebastian Sdorra <sebastian.sdorra@cloudogu.com>
2021-09-02 15:47:15 +02:00
Sebastian Sdorra
0ba8300051 Fix duplicate entries in branch selector (#1794) 2021-09-02 15:09:45 +02:00
René Pfeuffer
c408b38f10 Fix repository index
The index was missing the repository itself. This lead
to no repositories in the search detail page.
2021-09-02 11:14:12 +02:00
Sebastian Sdorra
70fba6c990 More flexible delete and query api (#1790)
Replaces the filter and delete by repository api's with a more flexible api, which allows to filter and delete by any id part.
2021-09-01 16:19:19 +02:00
Sebastian Sdorra
ea7964d224 Add support for enum fields during indexing (#1792)
* Add support for enum fields during indexing

* Add missing value extractor for enums
2021-09-01 15:40:38 +02:00
Konstantin Schaper
9ad501b4c6 fix redundant git repo closing (#1789)
Both the GitLogCommand and the GitModificationsCommand incorrectly closed the underlying git repository. This caused the git repository to be opened once but closed twice, which in turn flooded the logs with avoidable warnings and affected performance. The redundant closing of the git repo has been removed from both commands.
2021-09-01 09:44:11 +02:00
Sebastian Sdorra
765a39e4ce Remove unsafe index options api (#1787)
The IndexOptions api has several problems:
- It is possible to open the same index with different options, which could lead to scoring problems
- If the index is already opened from another task, the options are ignored and the one from the opening task are used
- The analyzer which is derived from the options is used for every field which has not configured a specific analyzer
- This change removes the options api completely.

Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
2021-08-31 14:03:16 +02:00
Sebastian Sdorra
61c2ebe80e Keep quick search input on page reload (#1788) 2021-08-31 13:30:15 +02:00
Sebastian Sdorra
571025032c Create a more flexible and typesafe id for indexed objects (#1785)
Id's can now be combined with more than just a repository. It is now possible to build a more complex Id such as Comment -> Pull request -> Repository. The id's now bound to a specific type. This makes it harder to accidentally use a id within an index of the wrong type.
2021-08-31 11:27:49 +02:00
Eduard Heimbuch
58f792a285 Fetch clone modal data on first opening (#1784)
Get the data of the clone modal the first time it is opened. This way, we display a loading spinner for a fraction of a second when the modal is first opened. But we also prevent fetching a lot of data that is probably not needed.
2021-08-31 07:39:02 +02:00
Sebastian Sdorra
cf55b15d21 Refactor SvnMirrorCommand
Extracted authentication logic into its own class.
Use source url instead of target url for authenticators and proxy excludes.
Use error code instead of complete message to detect a missing initialisation on update.
2021-08-26 12:20:44 +02:00
Sebastian Sdorra
0a26741ebd One index per type and parallel indexing (#1781)
Before this change the search uses a single index which distinguishes types (repositories, users, etc.) with a field (_type).
But it has turned out that this could lead to problems, in particular if different types have the same field and uses different analyzers for those fields. The following links show even more problems of a combined index:

    https://www.elastic.co/blog/index-vs-type
    https://www.elastic.co/guide/en/elasticsearch/reference/6.0/removal-of-types.html

With this change every type becomes its own index and the SearchEngine gets an api to modify multiple indices at once to remove all documents from all indices, which are related to a specific repository, for example.

The search uses another new api to coordinate the indexing, the central work queue.
The central work queue is able to coordinate long-running or resource intensive tasks. It is able to run tasks in parallel, but can also run tasks which targets the same resources in sequence. The queue is also persistent and can restore queued tasks after restart.

Co-authored-by: Konstantin Schaper <konstantin.schaper@cloudogu.com>
2021-08-25 15:40:11 +02:00
Konstantin Schaper
44f25d6b15 Fix disabled local proxy configuration being used over global config (#1780)
The original proxy configuration implementation only used the global configuration if the local proxy configuration was not provided (i.e. null). This PR adds the corner case where a local configuration is provided, but disabled. In this case, the global proxy configuration will be used as a fallback as well.
2021-08-25 08:19:52 +02:00
Florian Scholdei
7e94f434dd Update faq for initial administration user 2021-08-24 15:05:23 +02:00
Florian Scholdei
5c9b270e6e Remove deletion of modalRoot node (#1779)
Remove deletion of empty modalRoot node to allow a different modal to continue to exist
2021-08-24 11:26:16 +02:00
Sebastian Sdorra
1d80ecd976 Fix changelog generation 2021-08-24 07:54:55 +02:00
Sebastian Sdorra
519748106e Fix too heavy logging of SchemeBasedWebTokenGenerator (#1777)
Reduce log level of `could not create token from authentication header from warn to debug, because it is normal that these message is logged if multiple SchemeBasedWebTokenGenerator are registered.

Fixes #1772
2021-08-23 20:07:52 +02:00
Sebastian Sdorra
03449de238 Fix repository viewer for filenames which contains a hash (#1776)
Add missing url encoding for file links in the repository viewer.

Fixes #1766
2021-08-23 20:05:10 +02:00
Sebastian Sdorra
da2b34e528 Preserve request method on force base url (#1778)
The redirect which is used to force base url uses now 307 instead of 302 in order to preserve the request method.

Closes #1771
2021-08-23 20:02:12 +02:00
Sebastian Sdorra
7f9f4e566c Proxy support for pull, push and mirror commands (#1773)
Apply proxy support for jGit by extracting the required functionality from the DefaultAdvancedHttpClient into its own class HttpURLConnectionFactory. This new class is now used by the DefaultAdvancedHttpClient and jGit.
The HttpURLConnection also fixes proxy server authentication, which was non functional in DefaultAdvancedHttpClient.
The proxy support for SVNKit is implemented by using the provided method of the BasicAuthenticationManager.
For mercurial the support is configured by writing the required settings to a temporary hgrc file.
2021-08-19 11:27:51 +02:00
Sebastian Sdorra
a7bb67f36b Fix branch selector display revision if selected instead of first branch (#1767)
The select component displays the first option if the value is not part of the options. This behaviour breaks the BranchSelector which uses Select since version 2.22.0 (before it used the deprecated DropDown component). The BranchSelector has to display the revision if one is selected, which is not part of the options.
This change will add a addValueToOptions property to the Select component and restore the old behaviour.
2021-08-16 14:54:50 +02:00
Sebastian Sdorra
c03a9f6fcb Fix error message for parse error on search result page (#1768)
Show same parse error on detail page as on omni search.
2021-08-16 13:19:03 +02:00