-
Notifications
You must be signed in to change notification settings - Fork 0
/
db.go
36 lines (26 loc) · 882 Bytes
/
db.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package database
import (
"context"
"net/http"
"github.com/aayushrangwala/watermark-service/internal"
)
type dbService struct{}
func NewService() Service { return &dbService{} }
func (d *dbService) Add(_ context.Context, doc *internal.Document) (string, error) {
return "", nil
}
func (d *dbService) Get(_ context.Context, filters ...internal.Filter) ([]internal.Document, error) {
return []internal.Document{}, nil
}
func (d *dbService) Update(_ context.Context, ticketId string, doc *internal.Document) (int, error) {
return http.StatusOK, nil
}
func (d *dbService) Remove(_ context.Context, ticketId string) (int, error) {
return http.StatusOK, nil
}
//func (d *dbService) Validate(_ context.Context, doc *internal.Document) (bool, error) {
// return true, nil
//}
func (d *dbService) ServiceStatus(_ context.Context) (int, error) {
return http.StatusOK, nil
}