Full MVC of gitlab-zoekt-indexer
All threads resolved!
All threads resolved!
Compare changes
Files
4+ 93
− 68
@@ -18,6 +18,7 @@ import (
@@ -18,6 +18,7 @@ import (
@@ -42,11 +43,44 @@ type gitalyConnectionInfo struct {
@@ -42,11 +43,44 @@ type gitalyConnectionInfo struct {
@@ -56,6 +90,11 @@ func (s *indexServer) createIndexDir() {
@@ -56,6 +90,11 @@ func (s *indexServer) createIndexDir() {
@@ -82,12 +121,12 @@ func (s *indexServer) handleStatus() http.HandlerFunc {
@@ -82,12 +121,12 @@ func (s *indexServer) handleStatus() http.HandlerFunc {
@@ -106,6 +145,10 @@ func (s *indexServer) decode(r *http.Request, v interface{}) error {
@@ -106,6 +145,10 @@ func (s *indexServer) decode(r *http.Request, v interface{}) error {
@@ -114,14 +157,6 @@ func (s *indexServer) handleIndex() http.HandlerFunc {
@@ -114,14 +157,6 @@ func (s *indexServer) handleIndex() http.HandlerFunc {
@@ -132,48 +167,45 @@ func (s *indexServer) handleIndex() http.HandlerFunc {
@@ -132,48 +167,45 @@ func (s *indexServer) handleIndex() http.HandlerFunc {
@@ -184,11 +216,11 @@ func (s *indexServer) handleTruncate() http.HandlerFunc {
@@ -184,11 +216,11 @@ func (s *indexServer) handleTruncate() http.HandlerFunc {
@@ -197,24 +229,31 @@ func (s *indexServer) respondWith(w http.ResponseWriter, r *http.Request, route
@@ -197,24 +229,31 @@ func (s *indexServer) respondWith(w http.ResponseWriter, r *http.Request, route
func (s *indexServer) respondWithError(w http.ResponseWriter, r *http.Request, route string, err error) {
@@ -239,24 +278,6 @@ func (s *indexServer) initMetrics() {
@@ -239,24 +278,6 @@ func (s *indexServer) initMetrics() {
@@ -285,11 +306,15 @@ func main() {
@@ -285,11 +306,15 @@ func main() {