Make gitea serv use api/internal #4886

Merged
sapk merged 19 commits from serv-use-internals into master 2018-10-30 06:20:14 +00:00
sapk commented 2018-09-06 23:07:18 +00:00 (Migrated from github.com)

In order to limit concurrent access to database (mostly for SQLite)

Related: #4848 #2040

In order to limit concurrent access to database (mostly for SQLite) Related: #4848 #2040
lafriks commented 2018-09-07 00:14:13 +00:00 (Migrated from github.com)

Git clone tests seems to fail now

Git clone tests seems to fail now
lunny requested changes 2018-09-07 00:40:36 +00:00
sapk commented 2018-09-13 13:31:11 +00:00 (Migrated from github.com)

I have not much time until 2 weeks. I will look at tests since I test clone manually and it worked but I must have forget one corner case.

I have not much time until 2 weeks. I will look at tests since I test clone manually and it worked but I must have forget one corner case.
codecov-io commented 2018-10-23 16:50:34 +00:00 (Migrated from github.com)

Codecov Report

No coverage uploaded for pull request base (master@aefeb8c). Click here to learn what that means.
The diff coverage is 37.25%.

Impacted file tree graph

@@           Coverage Diff            @@
##             master   #4886   +/-   ##
========================================
  Coverage          ?   37.5%           
========================================
  Files             ?     310           
  Lines             ?   45929           
  Branches          ?       0           
========================================
  Hits              ?   17226           
  Misses            ?   26232           
  Partials          ?    2471
Impacted Files Coverage Δ
routers/private/key.go 20% <20%> (ø)
routers/private/internal.go 58.2% <57.44%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aefeb8c...63e1f3d. Read the comment docs.

# [Codecov](https://codecov.io/gh/go-gitea/gitea/pull/4886?src=pr&el=h1) Report > :exclamation: No coverage uploaded for pull request base (`master@aefeb8c`). [Click here to learn what that means](https://docs.codecov.io/docs/error-reference#section-missing-base-commit). > The diff coverage is `37.25%`. [![Impacted file tree graph](https://codecov.io/gh/go-gitea/gitea/pull/4886/graphs/tree.svg?width=650&token=t1G57YGbPy&height=150&src=pr)](https://codecov.io/gh/go-gitea/gitea/pull/4886?src=pr&el=tree) ```diff @@ Coverage Diff @@ ## master #4886 +/- ## ======================================== Coverage ? 37.5% ======================================== Files ? 310 Lines ? 45929 Branches ? 0 ======================================== Hits ? 17226 Misses ? 26232 Partials ? 2471 ``` | [Impacted Files](https://codecov.io/gh/go-gitea/gitea/pull/4886?src=pr&el=tree) | Coverage Δ | | |---|---|---| | [routers/private/key.go](https://codecov.io/gh/go-gitea/gitea/pull/4886/diff?src=pr&el=tree#diff-cm91dGVycy9wcml2YXRlL2tleS5nbw==) | `20% <20%> (ø)` | | | [routers/private/internal.go](https://codecov.io/gh/go-gitea/gitea/pull/4886/diff?src=pr&el=tree#diff-cm91dGVycy9wcml2YXRlL2ludGVybmFsLmdv) | `58.2% <57.44%> (ø)` | | ------ [Continue to review full report at Codecov](https://codecov.io/gh/go-gitea/gitea/pull/4886?src=pr&el=continue). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta) > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://codecov.io/gh/go-gitea/gitea/pull/4886?src=pr&el=footer). Last update [aefeb8c...63e1f3d](https://codecov.io/gh/go-gitea/gitea/pull/4886?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
sapk commented 2018-10-23 16:54:15 +00:00 (Migrated from github.com)

I found the stupid mistake I made. 😑
This PR should be good.

I found the stupid mistake I made. :expressionless: This PR should be good.
lunny approved these changes 2018-10-24 08:25:17 +00:00

Both hooks command also need to use api/internal.

Both hooks command also need to use api/internal.
sapk commented 2018-10-24 08:40:42 +00:00 (Migrated from github.com)

@lunny I will have to verify but hook seems to only use const in models and already use private (api/internal).
We could drop https://github.com/go-gitea/gitea/blob/master/cmd/hook.go#L69 that shouldn't be needed anymore but that will be in another PR.

@lunny I will have to verify but hook seems to only use const in models and already use private (api/internal). We could drop https://github.com/go-gitea/gitea/blob/master/cmd/hook.go#L69 that shouldn't be needed anymore but that will be in another PR.

@sapk Another PR to remove that is good.

@sapk Another PR to remove that is good.
betacat0 approved these changes 2018-10-30 05:37:50 +00:00
appleboy approved these changes 2018-10-30 05:40:03 +00:00
This repo is archived. You cannot comment on pull requests.
No reviewers
No Milestone
No project
No Assignees
3 Participants
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: lunny/gitea#4886
No description provided.