feat(storage): add native PostgreSQL runtime and verified offline application import
Build and publish container images / images (push) Failing after 12m29s
Build and publish container images / images (push) Failing after 12m29s
This commit is contained in:
1 parent
96065d1e89
commit
0ba1dcfef0
243 files changed
+21441
-3090
No files matched your search
@@ -25,14 +25,15 @@ func (r *Repository) ReadPersonalLocalIndex(ctx context.Context, domain, id, act
|
||||
// TaskBlock gets a current event, or creates it if absent and a draft is supplied.
|
||||
// Retries NEVER overwrite an event moved/edited in the calendar. Metadata policy
|
||||
// is checked under the same lock as snapshot access and the eventual commit.
|
||||
func (r *Repository) TaskBlock(ctx context.Context, domain, id, actor, uid string, draft *Event) (Calendar, Event, error) {
|
||||
func (r *Repository) TaskBlock(ctx context.Context, domain, id, actor, uid string, draft *Event) (calendarResult Calendar, eventResult Event, resultErr error) {
|
||||
defer func() { resultErr = r.failure(resultErr) }()
|
||||
c, dir, unlock, err := r.lockedWithGuard(ctx, domain, id, actor, func(c Calendar) bool { return c.PersonalLocal(actor) })
|
||||
if err != nil {
|
||||
return Calendar{}, Event{}, err
|
||||
}
|
||||
defer unlock()
|
||||
var data string
|
||||
err = r.DB.QueryRowContext(ctx, `SELECT data FROM calendar_event_cache WHERE domain=? AND calendar=? AND uid=?`, domain, id, uid).Scan(&data)
|
||||
err = r.DB.QueryRowContext(ctx, `SELECT data FROM calendar_event_cache WHERE domain=`+r.p(1)+` AND calendar=`+r.p(2)+` AND uid=`+r.p(3), domain, id, uid).Scan(&data)
|
||||
if err == nil {
|
||||
event, e := Parse(data)
|
||||
return c, event, e
|
||||
|
||||
Reference in new issue
Block a user