From 575b8129b7277707bda0600e7e25c6e16fb42056 Mon Sep 17 00:00:00 2001 From: Arnaud Delcasse Date: Tue, 15 Apr 2025 10:25:02 +0200 Subject: [PATCH] Get all bookings --- handler/bookings.go | 26 + servers/grpc/proto/carpool-service.pb.go | 951 ++++++++++-------- servers/grpc/proto/carpool-service.proto | 10 + servers/grpc/proto/carpool-service_grpc.pb.go | 37 + servers/grpc/server/book.go | 33 + storage/mongodb.go | 23 + storage/postgresql.go | 60 ++ storage/storage.go | 1 + 8 files changed, 743 insertions(+), 398 deletions(-) diff --git a/handler/bookings.go b/handler/bookings.go index b27ce98..683ba3d 100644 --- a/handler/bookings.go +++ b/handler/bookings.go @@ -91,6 +91,32 @@ func (h *CarpoolServiceHandler) GetUserBookings(user_id string, mindate *time.Ti return results, nil } +// GetBookings retrieves all the bookings between 2 dates +func (h *CarpoolServiceHandler) GetBookings(mindate *time.Time, maxdate *time.Time) ([]internal.Booking, error) { + bookings, err := h.Storage.GetAllBookings() + if err != nil { + return nil, err + } + + results := []internal.Booking{} + + for _, b := range bookings { + if mindate != nil { + if b.PassengerPickupDate.ToTime().Before(*mindate) { + continue + } + } + if maxdate != nil { + if b.PassengerPickupDate.ToTime().After(*maxdate) { + continue + } + } + results = append(results, b) + } + + return results, nil +} + // UpdateBookingStatus sets a new status for a given booking id func (h *CarpoolServiceHandler) UpdateBookingStatus(id string, status ocss.BookingStatus) error { err := h.Storage.UpdateBookingStatus(id, status.String()) diff --git a/servers/grpc/proto/carpool-service.pb.go b/servers/grpc/proto/carpool-service.pb.go index 37d0b35..804d121 100644 --- a/servers/grpc/proto/carpool-service.pb.go +++ b/servers/grpc/proto/carpool-service.pb.go @@ -608,6 +608,108 @@ func (x *GetUserBookingsResponse) GetBookings() []*CarpoolServiceBooking { return nil } +type GetCarpoolBookingsRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + MinDate *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=min_date,json=minDate,proto3,oneof" json:"min_date,omitempty"` + MaxDate *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=max_date,json=maxDate,proto3,oneof" json:"max_date,omitempty"` +} + +func (x *GetCarpoolBookingsRequest) Reset() { + *x = GetCarpoolBookingsRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_carpool_service_proto_msgTypes[12] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetCarpoolBookingsRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetCarpoolBookingsRequest) ProtoMessage() {} + +func (x *GetCarpoolBookingsRequest) ProtoReflect() protoreflect.Message { + mi := &file_carpool_service_proto_msgTypes[12] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use GetCarpoolBookingsRequest.ProtoReflect.Descriptor instead. +func (*GetCarpoolBookingsRequest) Descriptor() ([]byte, []int) { + return file_carpool_service_proto_rawDescGZIP(), []int{12} +} + +func (x *GetCarpoolBookingsRequest) GetMinDate() *timestamppb.Timestamp { + if x != nil { + return x.MinDate + } + return nil +} + +func (x *GetCarpoolBookingsRequest) GetMaxDate() *timestamppb.Timestamp { + if x != nil { + return x.MaxDate + } + return nil +} + +type GetCarpoolBookingsResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Bookings []*CarpoolServiceBooking `protobuf:"bytes,1,rep,name=bookings,proto3" json:"bookings,omitempty"` +} + +func (x *GetCarpoolBookingsResponse) Reset() { + *x = GetCarpoolBookingsResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_carpool_service_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *GetCarpoolBookingsResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*GetCarpoolBookingsResponse) ProtoMessage() {} + +func (x *GetCarpoolBookingsResponse) ProtoReflect() protoreflect.Message { + mi := &file_carpool_service_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use GetCarpoolBookingsResponse.ProtoReflect.Descriptor instead. +func (*GetCarpoolBookingsResponse) Descriptor() ([]byte, []int) { + return file_carpool_service_proto_rawDescGZIP(), []int{13} +} + +func (x *GetCarpoolBookingsResponse) GetBookings() []*CarpoolServiceBooking { + if x != nil { + return x.Bookings + } + return nil +} + // OCSS-like interaction messages type DriverJourneysRequest struct { state protoimpl.MessageState @@ -628,7 +730,7 @@ type DriverJourneysRequest struct { func (x *DriverJourneysRequest) Reset() { *x = DriverJourneysRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[12] + mi := &file_carpool_service_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -641,7 +743,7 @@ func (x *DriverJourneysRequest) String() string { func (*DriverJourneysRequest) ProtoMessage() {} func (x *DriverJourneysRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[12] + mi := &file_carpool_service_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -654,7 +756,7 @@ func (x *DriverJourneysRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use DriverJourneysRequest.ProtoReflect.Descriptor instead. func (*DriverJourneysRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{12} + return file_carpool_service_proto_rawDescGZIP(), []int{14} } func (x *DriverJourneysRequest) GetDepartureLat() float64 { @@ -731,7 +833,7 @@ type DriverJourneysResponse struct { func (x *DriverJourneysResponse) Reset() { *x = DriverJourneysResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[13] + mi := &file_carpool_service_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -744,7 +846,7 @@ func (x *DriverJourneysResponse) String() string { func (*DriverJourneysResponse) ProtoMessage() {} func (x *DriverJourneysResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[13] + mi := &file_carpool_service_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -757,7 +859,7 @@ func (x *DriverJourneysResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use DriverJourneysResponse.ProtoReflect.Descriptor instead. func (*DriverJourneysResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{13} + return file_carpool_service_proto_rawDescGZIP(), []int{15} } func (x *DriverJourneysResponse) GetDriverJourneys() []*CarpoolServiceDriverJourney { @@ -786,7 +888,7 @@ type PassengerJourneysRequest struct { func (x *PassengerJourneysRequest) Reset() { *x = PassengerJourneysRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[14] + mi := &file_carpool_service_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -799,7 +901,7 @@ func (x *PassengerJourneysRequest) String() string { func (*PassengerJourneysRequest) ProtoMessage() {} func (x *PassengerJourneysRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[14] + mi := &file_carpool_service_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -812,7 +914,7 @@ func (x *PassengerJourneysRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use PassengerJourneysRequest.ProtoReflect.Descriptor instead. func (*PassengerJourneysRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{14} + return file_carpool_service_proto_rawDescGZIP(), []int{16} } func (x *PassengerJourneysRequest) GetDepartureLat() float64 { @@ -889,7 +991,7 @@ type PassengerJourneysResponse struct { func (x *PassengerJourneysResponse) Reset() { *x = PassengerJourneysResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[15] + mi := &file_carpool_service_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -902,7 +1004,7 @@ func (x *PassengerJourneysResponse) String() string { func (*PassengerJourneysResponse) ProtoMessage() {} func (x *PassengerJourneysResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[15] + mi := &file_carpool_service_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -915,7 +1017,7 @@ func (x *PassengerJourneysResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use PassengerJourneysResponse.ProtoReflect.Descriptor instead. func (*PassengerJourneysResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{15} + return file_carpool_service_proto_rawDescGZIP(), []int{17} } func (x *PassengerJourneysResponse) GetPassengerJourneys() []*CarpoolServicePassengerJourney { @@ -947,7 +1049,7 @@ type DriverRegularTripsRequest struct { func (x *DriverRegularTripsRequest) Reset() { *x = DriverRegularTripsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[16] + mi := &file_carpool_service_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -960,7 +1062,7 @@ func (x *DriverRegularTripsRequest) String() string { func (*DriverRegularTripsRequest) ProtoMessage() {} func (x *DriverRegularTripsRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[16] + mi := &file_carpool_service_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -973,7 +1075,7 @@ func (x *DriverRegularTripsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use DriverRegularTripsRequest.ProtoReflect.Descriptor instead. func (*DriverRegularTripsRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{16} + return file_carpool_service_proto_rawDescGZIP(), []int{18} } func (x *DriverRegularTripsRequest) GetDepartureLat() float64 { @@ -1071,7 +1173,7 @@ type DriverRegularTripsResponse struct { func (x *DriverRegularTripsResponse) Reset() { *x = DriverRegularTripsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[17] + mi := &file_carpool_service_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1084,7 +1186,7 @@ func (x *DriverRegularTripsResponse) String() string { func (*DriverRegularTripsResponse) ProtoMessage() {} func (x *DriverRegularTripsResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[17] + mi := &file_carpool_service_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1097,7 +1199,7 @@ func (x *DriverRegularTripsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use DriverRegularTripsResponse.ProtoReflect.Descriptor instead. func (*DriverRegularTripsResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{17} + return file_carpool_service_proto_rawDescGZIP(), []int{19} } func (x *DriverRegularTripsResponse) GetDriverRegularTrips() []*CarpoolServiceDriverRegularTrip { @@ -1129,7 +1231,7 @@ type PassengerRegularTripsRequest struct { func (x *PassengerRegularTripsRequest) Reset() { *x = PassengerRegularTripsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[18] + mi := &file_carpool_service_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1142,7 +1244,7 @@ func (x *PassengerRegularTripsRequest) String() string { func (*PassengerRegularTripsRequest) ProtoMessage() {} func (x *PassengerRegularTripsRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[18] + mi := &file_carpool_service_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1155,7 +1257,7 @@ func (x *PassengerRegularTripsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use PassengerRegularTripsRequest.ProtoReflect.Descriptor instead. func (*PassengerRegularTripsRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{18} + return file_carpool_service_proto_rawDescGZIP(), []int{20} } func (x *PassengerRegularTripsRequest) GetDepartureLat() float64 { @@ -1253,7 +1355,7 @@ type PassengerRegularTripsResponse struct { func (x *PassengerRegularTripsResponse) Reset() { *x = PassengerRegularTripsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[19] + mi := &file_carpool_service_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1266,7 +1368,7 @@ func (x *PassengerRegularTripsResponse) String() string { func (*PassengerRegularTripsResponse) ProtoMessage() {} func (x *PassengerRegularTripsResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[19] + mi := &file_carpool_service_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1279,7 +1381,7 @@ func (x *PassengerRegularTripsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use PassengerRegularTripsResponse.ProtoReflect.Descriptor instead. func (*PassengerRegularTripsResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{19} + return file_carpool_service_proto_rawDescGZIP(), []int{21} } func (x *PassengerRegularTripsResponse) GetDriverRegularTrips() []*CarpoolServiceDriverRegularTrip { @@ -1300,7 +1402,7 @@ type CreateCarpoolBookingRequest struct { func (x *CreateCarpoolBookingRequest) Reset() { *x = CreateCarpoolBookingRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[20] + mi := &file_carpool_service_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1313,7 +1415,7 @@ func (x *CreateCarpoolBookingRequest) String() string { func (*CreateCarpoolBookingRequest) ProtoMessage() {} func (x *CreateCarpoolBookingRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[20] + mi := &file_carpool_service_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1326,7 +1428,7 @@ func (x *CreateCarpoolBookingRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateCarpoolBookingRequest.ProtoReflect.Descriptor instead. func (*CreateCarpoolBookingRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{20} + return file_carpool_service_proto_rawDescGZIP(), []int{22} } func (x *CreateCarpoolBookingRequest) GetBooking() *CarpoolServiceBooking { @@ -1347,7 +1449,7 @@ type CreateCarpoolBookingResponse struct { func (x *CreateCarpoolBookingResponse) Reset() { *x = CreateCarpoolBookingResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[21] + mi := &file_carpool_service_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1360,7 +1462,7 @@ func (x *CreateCarpoolBookingResponse) String() string { func (*CreateCarpoolBookingResponse) ProtoMessage() {} func (x *CreateCarpoolBookingResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[21] + mi := &file_carpool_service_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1373,7 +1475,7 @@ func (x *CreateCarpoolBookingResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateCarpoolBookingResponse.ProtoReflect.Descriptor instead. func (*CreateCarpoolBookingResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{21} + return file_carpool_service_proto_rawDescGZIP(), []int{23} } func (x *CreateCarpoolBookingResponse) GetBooking() *CarpoolServiceBooking { @@ -1396,7 +1498,7 @@ type UpdateCarpoolBookingRequest struct { func (x *UpdateCarpoolBookingRequest) Reset() { *x = UpdateCarpoolBookingRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[22] + mi := &file_carpool_service_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1409,7 +1511,7 @@ func (x *UpdateCarpoolBookingRequest) String() string { func (*UpdateCarpoolBookingRequest) ProtoMessage() {} func (x *UpdateCarpoolBookingRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[22] + mi := &file_carpool_service_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1422,7 +1524,7 @@ func (x *UpdateCarpoolBookingRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateCarpoolBookingRequest.ProtoReflect.Descriptor instead. func (*UpdateCarpoolBookingRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{22} + return file_carpool_service_proto_rawDescGZIP(), []int{24} } func (x *UpdateCarpoolBookingRequest) GetBookingId() string { @@ -1455,7 +1557,7 @@ type UpdateCarpoolBookingResponse struct { func (x *UpdateCarpoolBookingResponse) Reset() { *x = UpdateCarpoolBookingResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[23] + mi := &file_carpool_service_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1468,7 +1570,7 @@ func (x *UpdateCarpoolBookingResponse) String() string { func (*UpdateCarpoolBookingResponse) ProtoMessage() {} func (x *UpdateCarpoolBookingResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[23] + mi := &file_carpool_service_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1481,7 +1583,7 @@ func (x *UpdateCarpoolBookingResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateCarpoolBookingResponse.ProtoReflect.Descriptor instead. func (*UpdateCarpoolBookingResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{23} + return file_carpool_service_proto_rawDescGZIP(), []int{25} } type GetCarpoolBookingRequest struct { @@ -1495,7 +1597,7 @@ type GetCarpoolBookingRequest struct { func (x *GetCarpoolBookingRequest) Reset() { *x = GetCarpoolBookingRequest{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[24] + mi := &file_carpool_service_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1508,7 +1610,7 @@ func (x *GetCarpoolBookingRequest) String() string { func (*GetCarpoolBookingRequest) ProtoMessage() {} func (x *GetCarpoolBookingRequest) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[24] + mi := &file_carpool_service_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1521,7 +1623,7 @@ func (x *GetCarpoolBookingRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCarpoolBookingRequest.ProtoReflect.Descriptor instead. func (*GetCarpoolBookingRequest) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{24} + return file_carpool_service_proto_rawDescGZIP(), []int{26} } func (x *GetCarpoolBookingRequest) GetBookingId() string { @@ -1542,7 +1644,7 @@ type GetCarpoolBookingResponse struct { func (x *GetCarpoolBookingResponse) Reset() { *x = GetCarpoolBookingResponse{} if protoimpl.UnsafeEnabled { - mi := &file_carpool_service_proto_msgTypes[25] + mi := &file_carpool_service_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1555,7 +1657,7 @@ func (x *GetCarpoolBookingResponse) String() string { func (*GetCarpoolBookingResponse) ProtoMessage() {} func (x *GetCarpoolBookingResponse) ProtoReflect() protoreflect.Message { - mi := &file_carpool_service_proto_msgTypes[25] + mi := &file_carpool_service_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1568,7 +1670,7 @@ func (x *GetCarpoolBookingResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetCarpoolBookingResponse.ProtoReflect.Descriptor instead. func (*GetCarpoolBookingResponse) Descriptor() ([]byte, []int) { - return file_carpool_service_proto_rawDescGZIP(), []int{25} + return file_carpool_service_proto_rawDescGZIP(), []int{27} } func (x *GetCarpoolBookingResponse) GetBooking() *CarpoolServiceBooking { @@ -1659,277 +1761,298 @@ var file_carpool_service_proto_rawDesc = []byte{ 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x6f, 0x6f, 0x6b, - 0x69, 0x6e, 0x67, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x22, 0xc2, 0x03, - 0x0a, 0x15, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, - 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, - 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, 0x0d, - 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x6e, - 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, - 0x61, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x6e, - 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, - 0x4c, 0x6e, 0x67, 0x12, 0x41, 0x0a, 0x0e, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, - 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, - 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, - 0x65, 0x6c, 0x74, 0x61, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, 0x69, - 0x6d, 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, 0x65, - 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x07, - 0x20, 0x01, 0x28, 0x01, 0x48, 0x01, 0x52, 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, - 0x65, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, 0x72, - 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x01, 0x48, 0x02, 0x52, 0x0d, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, 0x64, - 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, - 0x09, 0x20, 0x01, 0x28, 0x03, 0x48, 0x03, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x88, 0x01, - 0x01, 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, - 0x42, 0x13, 0x0a, 0x11, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, - 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, - 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x63, 0x6f, 0x75, - 0x6e, 0x74, 0x22, 0x5f, 0x0a, 0x16, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, - 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x45, 0x0a, 0x0f, - 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x5f, 0x6a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x18, - 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, - 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, - 0x6e, 0x65, 0x79, 0x52, 0x0e, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, - 0x65, 0x79, 0x73, 0x22, 0xc5, 0x03, 0x0a, 0x18, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, - 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x61, - 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, - 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, - 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, - 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x6e, 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, - 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x01, 0x52, - 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x61, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x61, - 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, - 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x6e, 0x67, 0x12, 0x41, 0x0a, 0x0e, - 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, - 0x52, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x12, - 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, - 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, - 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x01, 0x48, 0x01, 0x52, - 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, - 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, - 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x01, 0x48, 0x02, 0x52, 0x0d, 0x61, - 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, - 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x48, 0x03, + 0x69, 0x6e, 0x67, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x22, 0xad, 0x01, + 0x0a, 0x19, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, + 0x69, 0x6e, 0x67, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x3a, 0x0a, 0x08, 0x6d, + 0x69, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x00, 0x52, 0x07, 0x6d, 0x69, 0x6e, + 0x44, 0x61, 0x74, 0x65, 0x88, 0x01, 0x01, 0x12, 0x3a, 0x0a, 0x08, 0x6d, 0x61, 0x78, 0x5f, 0x64, + 0x61, 0x74, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x01, 0x52, 0x07, 0x6d, 0x61, 0x78, 0x44, 0x61, 0x74, 0x65, + 0x88, 0x01, 0x01, 0x42, 0x0b, 0x0a, 0x09, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x65, + 0x42, 0x0b, 0x0a, 0x09, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x22, 0x50, 0x0a, + 0x1a, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, + 0x6e, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x32, 0x0a, 0x08, 0x62, + 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, 0x2e, + 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x6f, + 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x08, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x22, + 0xc2, 0x03, 0x0a, 0x15, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, + 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, + 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, + 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, + 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, + 0x4c, 0x6e, 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, + 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, + 0x6c, 0x4c, 0x61, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, + 0x6c, 0x6e, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, + 0x61, 0x6c, 0x4c, 0x6e, 0x67, 0x12, 0x41, 0x0a, 0x0e, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, + 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, + 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x12, 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, + 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, 0x06, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, + 0x74, 0x69, 0x6d, 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, + 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, + 0x18, 0x07, 0x20, 0x01, 0x28, 0x01, 0x48, 0x01, 0x52, 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, + 0x75, 0x72, 0x65, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, + 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, + 0x20, 0x01, 0x28, 0x01, 0x48, 0x02, 0x52, 0x0d, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, + 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, 0x48, 0x03, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x88, 0x01, 0x01, 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, + 0x74, 0x61, 0x42, 0x13, 0x0a, 0x11, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, + 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x61, 0x72, 0x72, 0x69, + 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x5f, 0x0a, 0x16, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, + 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x45, + 0x0a, 0x0f, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x5f, 0x6a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, + 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, + 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, + 0x75, 0x72, 0x6e, 0x65, 0x79, 0x52, 0x0e, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, + 0x72, 0x6e, 0x65, 0x79, 0x73, 0x22, 0xc5, 0x03, 0x0a, 0x18, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, + 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, + 0x6c, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, + 0x74, 0x75, 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, + 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, + 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x6e, 0x67, 0x12, 0x1f, 0x0a, 0x0b, + 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x61, 0x74, 0x12, 0x1f, 0x0a, + 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x6e, 0x67, 0x12, 0x41, + 0x0a, 0x0e, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x52, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, + 0x65, 0x12, 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, + 0x06, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x44, 0x65, 0x6c, + 0x74, 0x61, 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, + 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x01, 0x48, + 0x01, 0x52, 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x52, 0x61, 0x64, 0x69, + 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, + 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x01, 0x48, 0x02, 0x52, + 0x0d, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, + 0x01, 0x12, 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28, 0x03, + 0x48, 0x03, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x88, 0x01, 0x01, 0x42, 0x0d, 0x0a, 0x0b, + 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x42, 0x13, 0x0a, 0x11, 0x5f, + 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, + 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, + 0x69, 0x75, 0x73, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x6b, 0x0a, + 0x19, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, + 0x79, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4e, 0x0a, 0x12, 0x70, 0x61, + 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x5f, 0x6a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, + 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, + 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x52, 0x11, 0x70, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, + 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x22, 0xb2, 0x05, 0x0a, 0x19, 0x44, + 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, + 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, + 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, + 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, + 0x6e, 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, + 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, + 0x4c, 0x61, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, + 0x6e, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, + 0x6c, 0x4c, 0x6e, 0x67, 0x12, 0x31, 0x0a, 0x15, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, + 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x6f, 0x66, 0x5f, 0x64, 0x61, 0x79, 0x18, 0x05, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x12, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x54, 0x69, + 0x6d, 0x65, 0x4f, 0x66, 0x44, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x13, 0x64, 0x65, 0x70, 0x61, 0x72, + 0x74, 0x75, 0x72, 0x65, 0x5f, 0x77, 0x65, 0x65, 0x6b, 0x5f, 0x64, 0x61, 0x79, 0x73, 0x18, 0x06, + 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x57, + 0x65, 0x65, 0x6b, 0x44, 0x61, 0x79, 0x73, 0x12, 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, + 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, + 0x69, 0x6d, 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, + 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x01, 0x48, 0x01, 0x52, 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, + 0x72, 0x65, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, + 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x09, 0x20, + 0x01, 0x28, 0x01, 0x48, 0x02, 0x52, 0x0d, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, + 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x69, 0x6e, 0x5f, 0x64, + 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, + 0x03, 0x52, 0x10, 0x6d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, + 0x61, 0x74, 0x65, 0x88, 0x01, 0x01, 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, + 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0b, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x04, + 0x52, 0x10, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, + 0x74, 0x65, 0x88, 0x01, 0x01, 0x12, 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0c, + 0x20, 0x01, 0x28, 0x03, 0x48, 0x05, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x88, 0x01, 0x01, + 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x42, + 0x13, 0x0a, 0x11, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, + 0x64, 0x69, 0x75, 0x73, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, + 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x15, 0x0a, 0x13, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, + 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, 0x15, + 0x0a, 0x13, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, + 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, + 0x70, 0x0a, 0x1a, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, + 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x52, 0x0a, + 0x14, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x5f, + 0x74, 0x72, 0x69, 0x70, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x43, 0x61, + 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x72, 0x69, 0x76, + 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x52, 0x12, 0x64, + 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, + 0x73, 0x22, 0xb5, 0x05, 0x0a, 0x1c, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, + 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, + 0x6c, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, + 0x74, 0x75, 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, + 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, + 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x6e, 0x67, 0x12, 0x1f, 0x0a, 0x0b, + 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x61, 0x74, 0x12, 0x1f, 0x0a, + 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x04, 0x20, 0x01, + 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x6e, 0x67, 0x12, 0x31, + 0x0a, 0x15, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, + 0x5f, 0x6f, 0x66, 0x5f, 0x64, 0x61, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x12, 0x64, + 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x4f, 0x66, 0x44, 0x61, + 0x79, 0x12, 0x2e, 0x0a, 0x13, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x77, + 0x65, 0x65, 0x6b, 0x5f, 0x64, 0x61, 0x79, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, + 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x57, 0x65, 0x65, 0x6b, 0x44, 0x61, 0x79, + 0x73, 0x12, 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x44, 0x65, 0x6c, + 0x74, 0x61, 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, + 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x01, 0x48, + 0x01, 0x52, 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x52, 0x61, 0x64, 0x69, + 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, + 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x01, 0x48, 0x02, 0x52, + 0x0d, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, + 0x01, 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, + 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x03, 0x52, 0x10, 0x6d, 0x69, 0x6e, + 0x44, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x88, 0x01, 0x01, + 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, + 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, + 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, + 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x04, 0x52, 0x10, 0x6d, 0x61, 0x78, 0x44, + 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x88, 0x01, 0x01, 0x12, + 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x48, 0x05, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x88, 0x01, 0x01, 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x42, 0x13, 0x0a, 0x11, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, - 0x73, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x6b, 0x0a, 0x19, 0x50, - 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x4e, 0x0a, 0x12, 0x70, 0x61, 0x73, 0x73, - 0x65, 0x6e, 0x67, 0x65, 0x72, 0x5f, 0x6a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x18, 0x01, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, - 0x75, 0x72, 0x6e, 0x65, 0x79, 0x52, 0x11, 0x70, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, - 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x22, 0xb2, 0x05, 0x0a, 0x19, 0x44, 0x72, 0x69, - 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, - 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, - 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, - 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x6e, 0x67, - 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, 0x74, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x61, - 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x6e, 0x67, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, - 0x6e, 0x67, 0x12, 0x31, 0x0a, 0x15, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, - 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x6f, 0x66, 0x5f, 0x64, 0x61, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x12, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x54, 0x69, 0x6d, 0x65, - 0x4f, 0x66, 0x44, 0x61, 0x79, 0x12, 0x2e, 0x0a, 0x13, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, - 0x72, 0x65, 0x5f, 0x77, 0x65, 0x65, 0x6b, 0x5f, 0x64, 0x61, 0x79, 0x73, 0x18, 0x06, 0x20, 0x03, - 0x28, 0x09, 0x52, 0x11, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x57, 0x65, 0x65, - 0x6b, 0x44, 0x61, 0x79, 0x73, 0x12, 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, - 0x6c, 0x74, 0x61, 0x18, 0x07, 0x20, 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, 0x69, 0x6d, - 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, 0x65, 0x70, - 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x01, 0x48, 0x01, 0x52, 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, - 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, 0x72, 0x72, - 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x01, 0x48, 0x02, 0x52, 0x0d, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, 0x64, 0x69, - 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, - 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x03, 0x52, - 0x10, 0x6d, 0x69, 0x6e, 0x44, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, - 0x65, 0x88, 0x01, 0x01, 0x12, 0x4d, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x61, - 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x04, 0x52, 0x10, - 0x6d, 0x61, 0x78, 0x44, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, - 0x88, 0x01, 0x01, 0x12, 0x19, 0x0a, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x03, 0x48, 0x05, 0x52, 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x88, 0x01, 0x01, 0x42, 0x0d, - 0x0a, 0x0b, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x42, 0x13, 0x0a, - 0x11, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, - 0x75, 0x73, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, - 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x15, 0x0a, 0x13, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, - 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, 0x15, 0x0a, 0x13, - 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, - 0x61, 0x74, 0x65, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x70, 0x0a, - 0x1a, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, - 0x69, 0x70, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x52, 0x0a, 0x14, 0x64, - 0x72, 0x69, 0x76, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x5f, 0x74, 0x72, - 0x69, 0x70, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x43, 0x61, 0x72, 0x70, - 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, - 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x52, 0x12, 0x64, 0x72, 0x69, - 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x22, - 0xb5, 0x05, 0x0a, 0x1c, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, - 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x6c, 0x61, - 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, - 0x72, 0x65, 0x4c, 0x61, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, - 0x72, 0x65, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x02, 0x20, 0x01, 0x28, 0x01, 0x52, 0x0c, 0x64, 0x65, - 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x4c, 0x6e, 0x67, 0x12, 0x1f, 0x0a, 0x0b, 0x61, 0x72, - 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x61, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x01, 0x52, - 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x61, 0x74, 0x12, 0x1f, 0x0a, 0x0b, 0x61, - 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x6c, 0x6e, 0x67, 0x18, 0x04, 0x20, 0x01, 0x28, 0x01, - 0x52, 0x0a, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x4c, 0x6e, 0x67, 0x12, 0x31, 0x0a, 0x15, - 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x6f, - 0x66, 0x5f, 0x64, 0x61, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x12, 0x64, 0x65, 0x70, - 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x54, 0x69, 0x6d, 0x65, 0x4f, 0x66, 0x44, 0x61, 0x79, 0x12, - 0x2e, 0x0a, 0x13, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x77, 0x65, 0x65, - 0x6b, 0x5f, 0x64, 0x61, 0x79, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x64, 0x65, - 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x57, 0x65, 0x65, 0x6b, 0x44, 0x61, 0x79, 0x73, 0x12, - 0x22, 0x0a, 0x0a, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x18, 0x07, 0x20, - 0x01, 0x28, 0x03, 0x48, 0x00, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x44, 0x65, 0x6c, 0x74, 0x61, - 0x88, 0x01, 0x01, 0x12, 0x2e, 0x0a, 0x10, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, - 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x01, 0x48, 0x01, 0x52, - 0x0f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, - 0x88, 0x01, 0x01, 0x12, 0x2a, 0x0a, 0x0e, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, - 0x61, 0x64, 0x69, 0x75, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x01, 0x48, 0x02, 0x52, 0x0d, 0x61, - 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x52, 0x61, 0x64, 0x69, 0x75, 0x73, 0x88, 0x01, 0x01, 0x12, - 0x4d, 0x0a, 0x12, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, - 0x5f, 0x64, 0x61, 0x74, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x03, 0x52, 0x10, 0x6d, 0x69, 0x6e, 0x44, 0x65, - 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x88, 0x01, 0x01, 0x12, 0x4d, - 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, - 0x64, 0x61, 0x74, 0x65, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, - 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, - 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x48, 0x04, 0x52, 0x10, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x70, - 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x44, 0x61, 0x74, 0x65, 0x88, 0x01, 0x01, 0x12, 0x19, 0x0a, - 0x05, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x48, 0x05, 0x52, 0x05, - 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x88, 0x01, 0x01, 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x74, 0x69, 0x6d, - 0x65, 0x5f, 0x64, 0x65, 0x6c, 0x74, 0x61, 0x42, 0x13, 0x0a, 0x11, 0x5f, 0x64, 0x65, 0x70, 0x61, - 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, 0x11, 0x0a, 0x0f, - 0x5f, 0x61, 0x72, 0x72, 0x69, 0x76, 0x61, 0x6c, 0x5f, 0x72, 0x61, 0x64, 0x69, 0x75, 0x73, 0x42, - 0x15, 0x0a, 0x13, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, - 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, 0x15, 0x0a, 0x13, 0x5f, 0x6d, 0x61, 0x78, 0x5f, 0x64, - 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, 0x08, 0x0a, - 0x06, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x73, 0x0a, 0x1d, 0x50, 0x61, 0x73, 0x73, 0x65, - 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x52, 0x0a, 0x14, 0x64, 0x72, 0x69, 0x76, - 0x65, 0x72, 0x5f, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x5f, 0x74, 0x72, 0x69, 0x70, 0x73, - 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, - 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, - 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x52, 0x12, 0x64, 0x72, 0x69, 0x76, 0x65, 0x72, - 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x22, 0x4f, 0x0a, 0x1b, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, - 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x30, 0x0a, 0x07, 0x62, - 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x43, - 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x6f, 0x6f, - 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x22, 0x50, 0x0a, - 0x1c, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, - 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x30, 0x0a, + 0x73, 0x42, 0x15, 0x0a, 0x13, 0x5f, 0x6d, 0x69, 0x6e, 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, + 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, 0x15, 0x0a, 0x13, 0x5f, 0x6d, 0x61, 0x78, + 0x5f, 0x64, 0x65, 0x70, 0x61, 0x72, 0x74, 0x75, 0x72, 0x65, 0x5f, 0x64, 0x61, 0x74, 0x65, 0x42, + 0x08, 0x0a, 0x06, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x22, 0x73, 0x0a, 0x1d, 0x50, 0x61, 0x73, + 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, + 0x70, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x52, 0x0a, 0x14, 0x64, 0x72, + 0x69, 0x76, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x5f, 0x74, 0x72, 0x69, + 0x70, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, + 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, + 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x52, 0x12, 0x64, 0x72, 0x69, 0x76, + 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x22, 0x4f, + 0x0a, 0x1b, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, + 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x30, 0x0a, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x22, - 0x8c, 0x01, 0x0a, 0x1b, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, - 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, - 0x1d, 0x0a, 0x0a, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x49, 0x64, 0x12, 0x34, - 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1c, - 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, - 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, - 0x61, 0x74, 0x75, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0x1e, - 0x0a, 0x1c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, - 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x39, - 0x0a, 0x18, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6f, - 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, - 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x49, 0x64, 0x22, 0x4d, 0x0a, 0x19, 0x47, 0x65, 0x74, - 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x30, 0x0a, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, - 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, - 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, - 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x32, 0xfd, 0x07, 0x0a, 0x0e, 0x43, 0x61, 0x72, - 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x52, 0x0a, 0x13, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, - 0x65, 0x73, 0x12, 0x1b, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, - 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x1c, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, - 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x52, 0x0a, 0x13, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, - 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x12, 0x1b, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, - 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, - 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x49, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, - 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x67, + 0x50, 0x0a, 0x1c, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, + 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, + 0x30, 0x0a, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x16, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, + 0x67, 0x22, 0x8c, 0x01, 0x0a, 0x1b, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, + 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x69, 0x64, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x49, 0x64, + 0x12, 0x34, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, + 0x32, 0x1c, 0x2e, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, + 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x18, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, + 0x22, 0x1e, 0x0a, 0x1c, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, + 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, + 0x22, 0x39, 0x0a, 0x18, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, + 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, + 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x09, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x49, 0x64, 0x22, 0x4d, 0x0a, 0x19, 0x47, + 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x30, 0x0a, 0x07, 0x62, 0x6f, 0x6f, 0x6b, + 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x43, 0x61, 0x72, 0x70, + 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, + 0x67, 0x52, 0x07, 0x62, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x32, 0xce, 0x08, 0x0a, 0x0e, 0x43, + 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x52, 0x0a, + 0x13, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, + 0x75, 0x74, 0x65, 0x73, 0x12, 0x1b, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x1a, 0x19, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, - 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x46, - 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x50, 0x6c, 0x61, 0x6e, 0x6e, 0x69, 0x6e, - 0x67, 0x12, 0x17, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x50, 0x6c, 0x61, 0x6e, 0x6e, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x47, 0x65, 0x74, - 0x55, 0x73, 0x65, 0x72, 0x50, 0x6c, 0x61, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x50, 0x6c, 0x61, - 0x6e, 0x6e, 0x65, 0x64, 0x54, 0x72, 0x69, 0x70, 0x12, 0x16, 0x2e, 0x47, 0x65, 0x74, 0x50, 0x6c, - 0x61, 0x6e, 0x6e, 0x65, 0x64, 0x54, 0x72, 0x69, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x17, 0x2e, 0x47, 0x65, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x6e, 0x65, 0x64, 0x54, 0x72, 0x69, - 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x46, 0x0a, 0x0f, 0x47, - 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x12, 0x17, - 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, - 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x0e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, - 0x72, 0x6e, 0x65, 0x79, 0x73, 0x12, 0x16, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, - 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x17, 0x2e, - 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4c, 0x0a, 0x11, 0x50, 0x61, 0x73, 0x73, - 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x12, 0x19, 0x2e, - 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, - 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x50, 0x61, 0x73, 0x73, 0x65, - 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x12, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, - 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x12, 0x1a, 0x2e, 0x44, - 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, - 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, - 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x58, 0x0a, 0x15, 0x50, 0x61, 0x73, 0x73, 0x65, - 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, - 0x12, 0x1d, 0x2e, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, - 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, - 0x1e, 0x2e, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, - 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x4e, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, - 0x6e, 0x67, 0x12, 0x1c, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, - 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x1d, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, - 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x4e, 0x0a, 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x42, 0x6f, 0x6f, 0x6b, 0x69, - 0x6e, 0x67, 0x12, 0x1c, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, - 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x1d, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, - 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, - 0x00, 0x12, 0x45, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x12, - 0x19, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, - 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x47, 0x65, 0x74, - 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, - 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x42, 0x5a, 0x40, 0x67, 0x69, 0x74, 0x2e, - 0x63, 0x6f, 0x6f, 0x70, 0x67, 0x6f, 0x2e, 0x69, 0x6f, 0x2f, 0x63, 0x6f, 0x6f, 0x70, 0x67, 0x6f, - 0x2d, 0x70, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x2f, 0x63, 0x61, 0x72, 0x70, 0x6f, 0x6f, - 0x6c, 0x2d, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, - 0x73, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x06, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x33, + 0x74, 0x1a, 0x1c, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, + 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x00, 0x12, 0x52, 0x0a, 0x13, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, + 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x12, 0x1b, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, + 0x65, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1c, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x52, 0x65, + 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x49, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x65, 0x67, 0x75, + 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x12, 0x18, 0x2e, 0x47, 0x65, 0x74, 0x52, + 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, + 0x52, 0x6f, 0x75, 0x74, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, + 0x12, 0x46, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x50, 0x6c, 0x61, 0x6e, 0x6e, + 0x69, 0x6e, 0x67, 0x12, 0x17, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x50, 0x6c, 0x61, + 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x47, + 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x50, 0x6c, 0x61, 0x6e, 0x6e, 0x69, 0x6e, 0x67, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x50, + 0x6c, 0x61, 0x6e, 0x6e, 0x65, 0x64, 0x54, 0x72, 0x69, 0x70, 0x12, 0x16, 0x2e, 0x47, 0x65, 0x74, + 0x50, 0x6c, 0x61, 0x6e, 0x6e, 0x65, 0x64, 0x54, 0x72, 0x69, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x17, 0x2e, 0x47, 0x65, 0x74, 0x50, 0x6c, 0x61, 0x6e, 0x6e, 0x65, 0x64, 0x54, + 0x72, 0x69, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x46, 0x0a, + 0x0f, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, + 0x12, 0x17, 0x2e, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, + 0x67, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x47, 0x65, 0x74, 0x55, + 0x73, 0x65, 0x72, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, + 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x12, 0x1a, 0x2e, 0x47, 0x65, + 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, + 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, + 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x73, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x43, 0x0a, 0x0e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, + 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x12, 0x16, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, + 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x17, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4c, 0x0a, 0x11, 0x50, + 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, + 0x12, 0x19, 0x2e, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, + 0x6e, 0x65, 0x79, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, 0x50, 0x61, + 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x4a, 0x6f, 0x75, 0x72, 0x6e, 0x65, 0x79, 0x73, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4f, 0x0a, 0x12, 0x44, 0x72, 0x69, + 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x12, + 0x1a, 0x2e, 0x44, 0x72, 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, + 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1b, 0x2e, 0x44, 0x72, + 0x69, 0x76, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x58, 0x0a, 0x15, 0x50, 0x61, + 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, + 0x69, 0x70, 0x73, 0x12, 0x1d, 0x2e, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, + 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x50, 0x61, 0x73, 0x73, 0x65, 0x6e, 0x67, 0x65, 0x72, 0x52, 0x65, + 0x67, 0x75, 0x6c, 0x61, 0x72, 0x54, 0x72, 0x69, 0x70, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x4e, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x42, 0x6f, + 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x12, 0x1c, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, + 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, + 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x4e, 0x0a, 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x42, 0x6f, + 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x12, 0x1c, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, + 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x43, 0x61, 0x72, 0x70, + 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x45, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x42, 0x6f, 0x6f, 0x6b, 0x69, + 0x6e, 0x67, 0x12, 0x19, 0x2e, 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, + 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1a, 0x2e, + 0x47, 0x65, 0x74, 0x43, 0x61, 0x72, 0x70, 0x6f, 0x6f, 0x6c, 0x42, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, + 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x42, 0x5a, 0x40, 0x67, + 0x69, 0x74, 0x2e, 0x63, 0x6f, 0x6f, 0x70, 0x67, 0x6f, 0x2e, 0x69, 0x6f, 0x2f, 0x63, 0x6f, 0x6f, + 0x70, 0x67, 0x6f, 0x2d, 0x70, 0x6c, 0x61, 0x74, 0x66, 0x6f, 0x72, 0x6d, 0x2f, 0x63, 0x61, 0x72, + 0x70, 0x6f, 0x6f, 0x6c, 0x2d, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x2f, 0x73, 0x65, 0x72, + 0x76, 0x65, 0x72, 0x73, 0x2f, 0x67, 0x72, 0x70, 0x63, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, + 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1944,7 +2067,7 @@ func file_carpool_service_proto_rawDescGZIP() []byte { return file_carpool_service_proto_rawDescData } -var file_carpool_service_proto_msgTypes = make([]protoimpl.MessageInfo, 27) +var file_carpool_service_proto_msgTypes = make([]protoimpl.MessageInfo, 29) var file_carpool_service_proto_goTypes = []interface{}{ (*CreateRegularRoutesRequest)(nil), // 0: CreateRegularRoutesRequest (*CreateRegularRoutesResponse)(nil), // 1: CreateRegularRoutesResponse @@ -1958,86 +2081,93 @@ var file_carpool_service_proto_goTypes = []interface{}{ (*GetPlannedTripResponse)(nil), // 9: GetPlannedTripResponse (*GetUserBookingsRequest)(nil), // 10: GetUserBookingsRequest (*GetUserBookingsResponse)(nil), // 11: GetUserBookingsResponse - (*DriverJourneysRequest)(nil), // 12: DriverJourneysRequest - (*DriverJourneysResponse)(nil), // 13: DriverJourneysResponse - (*PassengerJourneysRequest)(nil), // 14: PassengerJourneysRequest - (*PassengerJourneysResponse)(nil), // 15: PassengerJourneysResponse - (*DriverRegularTripsRequest)(nil), // 16: DriverRegularTripsRequest - (*DriverRegularTripsResponse)(nil), // 17: DriverRegularTripsResponse - (*PassengerRegularTripsRequest)(nil), // 18: PassengerRegularTripsRequest - (*PassengerRegularTripsResponse)(nil), // 19: PassengerRegularTripsResponse - (*CreateCarpoolBookingRequest)(nil), // 20: CreateCarpoolBookingRequest - (*CreateCarpoolBookingResponse)(nil), // 21: CreateCarpoolBookingResponse - (*UpdateCarpoolBookingRequest)(nil), // 22: UpdateCarpoolBookingRequest - (*UpdateCarpoolBookingResponse)(nil), // 23: UpdateCarpoolBookingResponse - (*GetCarpoolBookingRequest)(nil), // 24: GetCarpoolBookingRequest - (*GetCarpoolBookingResponse)(nil), // 25: GetCarpoolBookingResponse - nil, // 26: GetUserPlanningResponse.RoutesByDatesEntry - (*CarpoolFeatureCollection)(nil), // 27: CarpoolFeatureCollection - (*timestamppb.Timestamp)(nil), // 28: google.protobuf.Timestamp - (*CarpoolServiceBooking)(nil), // 29: CarpoolServiceBooking - (*CarpoolServiceDriverJourney)(nil), // 30: CarpoolServiceDriverJourney - (*CarpoolServicePassengerJourney)(nil), // 31: CarpoolServicePassengerJourney - (*CarpoolServiceDriverRegularTrip)(nil), // 32: CarpoolServiceDriverRegularTrip - (CarpoolServiceBookingStatus)(0), // 33: CarpoolServiceBookingStatus - (*CarpoolRoutesCollection)(nil), // 34: CarpoolRoutesCollection + (*GetCarpoolBookingsRequest)(nil), // 12: GetCarpoolBookingsRequest + (*GetCarpoolBookingsResponse)(nil), // 13: GetCarpoolBookingsResponse + (*DriverJourneysRequest)(nil), // 14: DriverJourneysRequest + (*DriverJourneysResponse)(nil), // 15: DriverJourneysResponse + (*PassengerJourneysRequest)(nil), // 16: PassengerJourneysRequest + (*PassengerJourneysResponse)(nil), // 17: PassengerJourneysResponse + (*DriverRegularTripsRequest)(nil), // 18: DriverRegularTripsRequest + (*DriverRegularTripsResponse)(nil), // 19: DriverRegularTripsResponse + (*PassengerRegularTripsRequest)(nil), // 20: PassengerRegularTripsRequest + (*PassengerRegularTripsResponse)(nil), // 21: PassengerRegularTripsResponse + (*CreateCarpoolBookingRequest)(nil), // 22: CreateCarpoolBookingRequest + (*CreateCarpoolBookingResponse)(nil), // 23: CreateCarpoolBookingResponse + (*UpdateCarpoolBookingRequest)(nil), // 24: UpdateCarpoolBookingRequest + (*UpdateCarpoolBookingResponse)(nil), // 25: UpdateCarpoolBookingResponse + (*GetCarpoolBookingRequest)(nil), // 26: GetCarpoolBookingRequest + (*GetCarpoolBookingResponse)(nil), // 27: GetCarpoolBookingResponse + nil, // 28: GetUserPlanningResponse.RoutesByDatesEntry + (*CarpoolFeatureCollection)(nil), // 29: CarpoolFeatureCollection + (*timestamppb.Timestamp)(nil), // 30: google.protobuf.Timestamp + (*CarpoolServiceBooking)(nil), // 31: CarpoolServiceBooking + (*CarpoolServiceDriverJourney)(nil), // 32: CarpoolServiceDriverJourney + (*CarpoolServicePassengerJourney)(nil), // 33: CarpoolServicePassengerJourney + (*CarpoolServiceDriverRegularTrip)(nil), // 34: CarpoolServiceDriverRegularTrip + (CarpoolServiceBookingStatus)(0), // 35: CarpoolServiceBookingStatus + (*CarpoolRoutesCollection)(nil), // 36: CarpoolRoutesCollection } var file_carpool_service_proto_depIdxs = []int32{ - 27, // 0: CreateRegularRoutesRequest.routes:type_name -> CarpoolFeatureCollection - 27, // 1: GetRegularRoutesResponse.routes:type_name -> CarpoolFeatureCollection - 28, // 2: GetUserPlanningRequest.min_departure_date:type_name -> google.protobuf.Timestamp - 28, // 3: GetUserPlanningRequest.max_departure_date:type_name -> google.protobuf.Timestamp - 26, // 4: GetUserPlanningResponse.routes_by_dates:type_name -> GetUserPlanningResponse.RoutesByDatesEntry - 27, // 5: GetPlannedTripResponse.planned_trip:type_name -> CarpoolFeatureCollection - 28, // 6: GetUserBookingsRequest.min_date:type_name -> google.protobuf.Timestamp - 28, // 7: GetUserBookingsRequest.max_date:type_name -> google.protobuf.Timestamp - 29, // 8: GetUserBookingsResponse.bookings:type_name -> CarpoolServiceBooking - 28, // 9: DriverJourneysRequest.departure_date:type_name -> google.protobuf.Timestamp - 30, // 10: DriverJourneysResponse.driver_journeys:type_name -> CarpoolServiceDriverJourney - 28, // 11: PassengerJourneysRequest.departure_date:type_name -> google.protobuf.Timestamp - 31, // 12: PassengerJourneysResponse.passenger_journeys:type_name -> CarpoolServicePassengerJourney - 28, // 13: DriverRegularTripsRequest.min_departure_date:type_name -> google.protobuf.Timestamp - 28, // 14: DriverRegularTripsRequest.max_departure_date:type_name -> google.protobuf.Timestamp - 32, // 15: DriverRegularTripsResponse.driver_regular_trips:type_name -> CarpoolServiceDriverRegularTrip - 28, // 16: PassengerRegularTripsRequest.min_departure_date:type_name -> google.protobuf.Timestamp - 28, // 17: PassengerRegularTripsRequest.max_departure_date:type_name -> google.protobuf.Timestamp - 32, // 18: PassengerRegularTripsResponse.driver_regular_trips:type_name -> CarpoolServiceDriverRegularTrip - 29, // 19: CreateCarpoolBookingRequest.booking:type_name -> CarpoolServiceBooking - 29, // 20: CreateCarpoolBookingResponse.booking:type_name -> CarpoolServiceBooking - 33, // 21: UpdateCarpoolBookingRequest.status:type_name -> CarpoolServiceBookingStatus - 29, // 22: GetCarpoolBookingResponse.booking:type_name -> CarpoolServiceBooking - 34, // 23: GetUserPlanningResponse.RoutesByDatesEntry.value:type_name -> CarpoolRoutesCollection - 0, // 24: CarpoolService.CreateRegularRoutes:input_type -> CreateRegularRoutesRequest - 2, // 25: CarpoolService.DeleteRegularRoutes:input_type -> DeleteRegularRoutesRequest - 4, // 26: CarpoolService.GetRegularRoutes:input_type -> GetRegularRoutesRequest - 6, // 27: CarpoolService.GetUserPlanning:input_type -> GetUserPlanningRequest - 8, // 28: CarpoolService.GetPlannedTrip:input_type -> GetPlannedTripRequest - 10, // 29: CarpoolService.GetUserBookings:input_type -> GetUserBookingsRequest - 12, // 30: CarpoolService.DriverJourneys:input_type -> DriverJourneysRequest - 14, // 31: CarpoolService.PassengerJourneys:input_type -> PassengerJourneysRequest - 16, // 32: CarpoolService.DriverRegularTrips:input_type -> DriverRegularTripsRequest - 18, // 33: CarpoolService.PassengerRegularTrips:input_type -> PassengerRegularTripsRequest - 20, // 34: CarpoolService.CreateBooking:input_type -> CreateCarpoolBookingRequest - 22, // 35: CarpoolService.UpdateBooking:input_type -> UpdateCarpoolBookingRequest - 24, // 36: CarpoolService.GetBooking:input_type -> GetCarpoolBookingRequest - 1, // 37: CarpoolService.CreateRegularRoutes:output_type -> CreateRegularRoutesResponse - 3, // 38: CarpoolService.DeleteRegularRoutes:output_type -> DeleteRegularRoutesResponse - 5, // 39: CarpoolService.GetRegularRoutes:output_type -> GetRegularRoutesResponse - 7, // 40: CarpoolService.GetUserPlanning:output_type -> GetUserPlanningResponse - 9, // 41: CarpoolService.GetPlannedTrip:output_type -> GetPlannedTripResponse - 11, // 42: CarpoolService.GetUserBookings:output_type -> GetUserBookingsResponse - 13, // 43: CarpoolService.DriverJourneys:output_type -> DriverJourneysResponse - 15, // 44: CarpoolService.PassengerJourneys:output_type -> PassengerJourneysResponse - 17, // 45: CarpoolService.DriverRegularTrips:output_type -> DriverRegularTripsResponse - 19, // 46: CarpoolService.PassengerRegularTrips:output_type -> PassengerRegularTripsResponse - 21, // 47: CarpoolService.CreateBooking:output_type -> CreateCarpoolBookingResponse - 23, // 48: CarpoolService.UpdateBooking:output_type -> UpdateCarpoolBookingResponse - 25, // 49: CarpoolService.GetBooking:output_type -> GetCarpoolBookingResponse - 37, // [37:50] is the sub-list for method output_type - 24, // [24:37] is the sub-list for method input_type - 24, // [24:24] is the sub-list for extension type_name - 24, // [24:24] is the sub-list for extension extendee - 0, // [0:24] is the sub-list for field type_name + 29, // 0: CreateRegularRoutesRequest.routes:type_name -> CarpoolFeatureCollection + 29, // 1: GetRegularRoutesResponse.routes:type_name -> CarpoolFeatureCollection + 30, // 2: GetUserPlanningRequest.min_departure_date:type_name -> google.protobuf.Timestamp + 30, // 3: GetUserPlanningRequest.max_departure_date:type_name -> google.protobuf.Timestamp + 28, // 4: GetUserPlanningResponse.routes_by_dates:type_name -> GetUserPlanningResponse.RoutesByDatesEntry + 29, // 5: GetPlannedTripResponse.planned_trip:type_name -> CarpoolFeatureCollection + 30, // 6: GetUserBookingsRequest.min_date:type_name -> google.protobuf.Timestamp + 30, // 7: GetUserBookingsRequest.max_date:type_name -> google.protobuf.Timestamp + 31, // 8: GetUserBookingsResponse.bookings:type_name -> CarpoolServiceBooking + 30, // 9: GetCarpoolBookingsRequest.min_date:type_name -> google.protobuf.Timestamp + 30, // 10: GetCarpoolBookingsRequest.max_date:type_name -> google.protobuf.Timestamp + 31, // 11: GetCarpoolBookingsResponse.bookings:type_name -> CarpoolServiceBooking + 30, // 12: DriverJourneysRequest.departure_date:type_name -> google.protobuf.Timestamp + 32, // 13: DriverJourneysResponse.driver_journeys:type_name -> CarpoolServiceDriverJourney + 30, // 14: PassengerJourneysRequest.departure_date:type_name -> google.protobuf.Timestamp + 33, // 15: PassengerJourneysResponse.passenger_journeys:type_name -> CarpoolServicePassengerJourney + 30, // 16: DriverRegularTripsRequest.min_departure_date:type_name -> google.protobuf.Timestamp + 30, // 17: DriverRegularTripsRequest.max_departure_date:type_name -> google.protobuf.Timestamp + 34, // 18: DriverRegularTripsResponse.driver_regular_trips:type_name -> CarpoolServiceDriverRegularTrip + 30, // 19: PassengerRegularTripsRequest.min_departure_date:type_name -> google.protobuf.Timestamp + 30, // 20: PassengerRegularTripsRequest.max_departure_date:type_name -> google.protobuf.Timestamp + 34, // 21: PassengerRegularTripsResponse.driver_regular_trips:type_name -> CarpoolServiceDriverRegularTrip + 31, // 22: CreateCarpoolBookingRequest.booking:type_name -> CarpoolServiceBooking + 31, // 23: CreateCarpoolBookingResponse.booking:type_name -> CarpoolServiceBooking + 35, // 24: UpdateCarpoolBookingRequest.status:type_name -> CarpoolServiceBookingStatus + 31, // 25: GetCarpoolBookingResponse.booking:type_name -> CarpoolServiceBooking + 36, // 26: GetUserPlanningResponse.RoutesByDatesEntry.value:type_name -> CarpoolRoutesCollection + 0, // 27: CarpoolService.CreateRegularRoutes:input_type -> CreateRegularRoutesRequest + 2, // 28: CarpoolService.DeleteRegularRoutes:input_type -> DeleteRegularRoutesRequest + 4, // 29: CarpoolService.GetRegularRoutes:input_type -> GetRegularRoutesRequest + 6, // 30: CarpoolService.GetUserPlanning:input_type -> GetUserPlanningRequest + 8, // 31: CarpoolService.GetPlannedTrip:input_type -> GetPlannedTripRequest + 10, // 32: CarpoolService.GetUserBookings:input_type -> GetUserBookingsRequest + 12, // 33: CarpoolService.GetCarpoolBookings:input_type -> GetCarpoolBookingsRequest + 14, // 34: CarpoolService.DriverJourneys:input_type -> DriverJourneysRequest + 16, // 35: CarpoolService.PassengerJourneys:input_type -> PassengerJourneysRequest + 18, // 36: CarpoolService.DriverRegularTrips:input_type -> DriverRegularTripsRequest + 20, // 37: CarpoolService.PassengerRegularTrips:input_type -> PassengerRegularTripsRequest + 22, // 38: CarpoolService.CreateBooking:input_type -> CreateCarpoolBookingRequest + 24, // 39: CarpoolService.UpdateBooking:input_type -> UpdateCarpoolBookingRequest + 26, // 40: CarpoolService.GetBooking:input_type -> GetCarpoolBookingRequest + 1, // 41: CarpoolService.CreateRegularRoutes:output_type -> CreateRegularRoutesResponse + 3, // 42: CarpoolService.DeleteRegularRoutes:output_type -> DeleteRegularRoutesResponse + 5, // 43: CarpoolService.GetRegularRoutes:output_type -> GetRegularRoutesResponse + 7, // 44: CarpoolService.GetUserPlanning:output_type -> GetUserPlanningResponse + 9, // 45: CarpoolService.GetPlannedTrip:output_type -> GetPlannedTripResponse + 11, // 46: CarpoolService.GetUserBookings:output_type -> GetUserBookingsResponse + 13, // 47: CarpoolService.GetCarpoolBookings:output_type -> GetCarpoolBookingsResponse + 15, // 48: CarpoolService.DriverJourneys:output_type -> DriverJourneysResponse + 17, // 49: CarpoolService.PassengerJourneys:output_type -> PassengerJourneysResponse + 19, // 50: CarpoolService.DriverRegularTrips:output_type -> DriverRegularTripsResponse + 21, // 51: CarpoolService.PassengerRegularTrips:output_type -> PassengerRegularTripsResponse + 23, // 52: CarpoolService.CreateBooking:output_type -> CreateCarpoolBookingResponse + 25, // 53: CarpoolService.UpdateBooking:output_type -> UpdateCarpoolBookingResponse + 27, // 54: CarpoolService.GetBooking:output_type -> GetCarpoolBookingResponse + 41, // [41:55] is the sub-list for method output_type + 27, // [27:41] is the sub-list for method input_type + 27, // [27:27] is the sub-list for extension type_name + 27, // [27:27] is the sub-list for extension extendee + 0, // [0:27] is the sub-list for field type_name } func init() { file_carpool_service_proto_init() } @@ -2192,7 +2322,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverJourneysRequest); i { + switch v := v.(*GetCarpoolBookingsRequest); i { case 0: return &v.state case 1: @@ -2204,7 +2334,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverJourneysResponse); i { + switch v := v.(*GetCarpoolBookingsResponse); i { case 0: return &v.state case 1: @@ -2216,7 +2346,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PassengerJourneysRequest); i { + switch v := v.(*DriverJourneysRequest); i { case 0: return &v.state case 1: @@ -2228,7 +2358,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PassengerJourneysResponse); i { + switch v := v.(*DriverJourneysResponse); i { case 0: return &v.state case 1: @@ -2240,7 +2370,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverRegularTripsRequest); i { + switch v := v.(*PassengerJourneysRequest); i { case 0: return &v.state case 1: @@ -2252,7 +2382,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DriverRegularTripsResponse); i { + switch v := v.(*PassengerJourneysResponse); i { case 0: return &v.state case 1: @@ -2264,7 +2394,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PassengerRegularTripsRequest); i { + switch v := v.(*DriverRegularTripsRequest); i { case 0: return &v.state case 1: @@ -2276,7 +2406,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*PassengerRegularTripsResponse); i { + switch v := v.(*DriverRegularTripsResponse); i { case 0: return &v.state case 1: @@ -2288,7 +2418,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CreateCarpoolBookingRequest); i { + switch v := v.(*PassengerRegularTripsRequest); i { case 0: return &v.state case 1: @@ -2300,7 +2430,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CreateCarpoolBookingResponse); i { + switch v := v.(*PassengerRegularTripsResponse); i { case 0: return &v.state case 1: @@ -2312,7 +2442,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateCarpoolBookingRequest); i { + switch v := v.(*CreateCarpoolBookingRequest); i { case 0: return &v.state case 1: @@ -2324,7 +2454,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateCarpoolBookingResponse); i { + switch v := v.(*CreateCarpoolBookingResponse); i { case 0: return &v.state case 1: @@ -2336,7 +2466,7 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetCarpoolBookingRequest); i { + switch v := v.(*UpdateCarpoolBookingRequest); i { case 0: return &v.state case 1: @@ -2348,6 +2478,30 @@ func file_carpool_service_proto_init() { } } file_carpool_service_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*UpdateCarpoolBookingResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_carpool_service_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetCarpoolBookingRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_carpool_service_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*GetCarpoolBookingResponse); i { case 0: return &v.state @@ -2365,13 +2519,14 @@ func file_carpool_service_proto_init() { file_carpool_service_proto_msgTypes[14].OneofWrappers = []interface{}{} file_carpool_service_proto_msgTypes[16].OneofWrappers = []interface{}{} file_carpool_service_proto_msgTypes[18].OneofWrappers = []interface{}{} + file_carpool_service_proto_msgTypes[20].OneofWrappers = []interface{}{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_carpool_service_proto_rawDesc, NumEnums: 0, - NumMessages: 27, + NumMessages: 29, NumExtensions: 0, NumServices: 1, }, diff --git a/servers/grpc/proto/carpool-service.proto b/servers/grpc/proto/carpool-service.proto index abdde7f..494ea5f 100644 --- a/servers/grpc/proto/carpool-service.proto +++ b/servers/grpc/proto/carpool-service.proto @@ -14,6 +14,7 @@ service CarpoolService { rpc GetUserPlanning(GetUserPlanningRequest) returns (GetUserPlanningResponse) {} rpc GetPlannedTrip(GetPlannedTripRequest) returns (GetPlannedTripResponse) {} rpc GetUserBookings(GetUserBookingsRequest) returns (GetUserBookingsResponse) {} + rpc GetCarpoolBookings(GetCarpoolBookingsRequest) returns (GetCarpoolBookingsResponse) {} // OCSS interactions rpc DriverJourneys(DriverJourneysRequest) returns (DriverJourneysResponse) {} @@ -75,6 +76,15 @@ message GetUserBookingsResponse { repeated CarpoolServiceBooking bookings = 1; } +message GetCarpoolBookingsRequest { + optional google.protobuf.Timestamp min_date = 2; + optional google.protobuf.Timestamp max_date = 3; +} + +message GetCarpoolBookingsResponse { + repeated CarpoolServiceBooking bookings = 1; +} + // OCSS-like interaction messages diff --git a/servers/grpc/proto/carpool-service_grpc.pb.go b/servers/grpc/proto/carpool-service_grpc.pb.go index 06e6c73..f27bb4f 100644 --- a/servers/grpc/proto/carpool-service_grpc.pb.go +++ b/servers/grpc/proto/carpool-service_grpc.pb.go @@ -25,6 +25,7 @@ const ( CarpoolService_GetUserPlanning_FullMethodName = "/CarpoolService/GetUserPlanning" CarpoolService_GetPlannedTrip_FullMethodName = "/CarpoolService/GetPlannedTrip" CarpoolService_GetUserBookings_FullMethodName = "/CarpoolService/GetUserBookings" + CarpoolService_GetCarpoolBookings_FullMethodName = "/CarpoolService/GetCarpoolBookings" CarpoolService_DriverJourneys_FullMethodName = "/CarpoolService/DriverJourneys" CarpoolService_PassengerJourneys_FullMethodName = "/CarpoolService/PassengerJourneys" CarpoolService_DriverRegularTrips_FullMethodName = "/CarpoolService/DriverRegularTrips" @@ -46,6 +47,7 @@ type CarpoolServiceClient interface { GetUserPlanning(ctx context.Context, in *GetUserPlanningRequest, opts ...grpc.CallOption) (*GetUserPlanningResponse, error) GetPlannedTrip(ctx context.Context, in *GetPlannedTripRequest, opts ...grpc.CallOption) (*GetPlannedTripResponse, error) GetUserBookings(ctx context.Context, in *GetUserBookingsRequest, opts ...grpc.CallOption) (*GetUserBookingsResponse, error) + GetCarpoolBookings(ctx context.Context, in *GetCarpoolBookingsRequest, opts ...grpc.CallOption) (*GetCarpoolBookingsResponse, error) // OCSS interactions DriverJourneys(ctx context.Context, in *DriverJourneysRequest, opts ...grpc.CallOption) (*DriverJourneysResponse, error) PassengerJourneys(ctx context.Context, in *PassengerJourneysRequest, opts ...grpc.CallOption) (*PassengerJourneysResponse, error) @@ -118,6 +120,15 @@ func (c *carpoolServiceClient) GetUserBookings(ctx context.Context, in *GetUserB return out, nil } +func (c *carpoolServiceClient) GetCarpoolBookings(ctx context.Context, in *GetCarpoolBookingsRequest, opts ...grpc.CallOption) (*GetCarpoolBookingsResponse, error) { + out := new(GetCarpoolBookingsResponse) + err := c.cc.Invoke(ctx, CarpoolService_GetCarpoolBookings_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *carpoolServiceClient) DriverJourneys(ctx context.Context, in *DriverJourneysRequest, opts ...grpc.CallOption) (*DriverJourneysResponse, error) { out := new(DriverJourneysResponse) err := c.cc.Invoke(ctx, CarpoolService_DriverJourneys_FullMethodName, in, out, opts...) @@ -193,6 +204,7 @@ type CarpoolServiceServer interface { GetUserPlanning(context.Context, *GetUserPlanningRequest) (*GetUserPlanningResponse, error) GetPlannedTrip(context.Context, *GetPlannedTripRequest) (*GetPlannedTripResponse, error) GetUserBookings(context.Context, *GetUserBookingsRequest) (*GetUserBookingsResponse, error) + GetCarpoolBookings(context.Context, *GetCarpoolBookingsRequest) (*GetCarpoolBookingsResponse, error) // OCSS interactions DriverJourneys(context.Context, *DriverJourneysRequest) (*DriverJourneysResponse, error) PassengerJourneys(context.Context, *PassengerJourneysRequest) (*PassengerJourneysResponse, error) @@ -226,6 +238,9 @@ func (UnimplementedCarpoolServiceServer) GetPlannedTrip(context.Context, *GetPla func (UnimplementedCarpoolServiceServer) GetUserBookings(context.Context, *GetUserBookingsRequest) (*GetUserBookingsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetUserBookings not implemented") } +func (UnimplementedCarpoolServiceServer) GetCarpoolBookings(context.Context, *GetCarpoolBookingsRequest) (*GetCarpoolBookingsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetCarpoolBookings not implemented") +} func (UnimplementedCarpoolServiceServer) DriverJourneys(context.Context, *DriverJourneysRequest) (*DriverJourneysResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DriverJourneys not implemented") } @@ -368,6 +383,24 @@ func _CarpoolService_GetUserBookings_Handler(srv interface{}, ctx context.Contex return interceptor(ctx, in, info, handler) } +func _CarpoolService_GetCarpoolBookings_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetCarpoolBookingsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(CarpoolServiceServer).GetCarpoolBookings(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: CarpoolService_GetCarpoolBookings_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(CarpoolServiceServer).GetCarpoolBookings(ctx, req.(*GetCarpoolBookingsRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _CarpoolService_DriverJourneys_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DriverJourneysRequest) if err := dec(in); err != nil { @@ -525,6 +558,10 @@ var CarpoolService_ServiceDesc = grpc.ServiceDesc{ MethodName: "GetUserBookings", Handler: _CarpoolService_GetUserBookings_Handler, }, + { + MethodName: "GetCarpoolBookings", + Handler: _CarpoolService_GetCarpoolBookings_Handler, + }, { MethodName: "DriverJourneys", Handler: _CarpoolService_DriverJourneys_Handler, diff --git a/servers/grpc/server/book.go b/servers/grpc/server/book.go index e8df789..d635ca5 100644 --- a/servers/grpc/server/book.go +++ b/servers/grpc/server/book.go @@ -54,6 +54,39 @@ func (s *CarpoolServiceServerImpl) GetUserBookings(ctx context.Context, req *pro }, nil } +func (s *CarpoolServiceServerImpl) GetCarpoolBookings(ctx context.Context, req *proto.GetCarpoolBookingsRequest) (*proto.GetCarpoolBookingsResponse, error) { + log.Debug(). + Time("mindate", req.MinDate.AsTime()). + Time("maxdate", req.MaxDate.AsTime()). + Msg("grpc server - GetUserBookings") + + var mindate *time.Time + if req.MinDate != nil { + d := req.MinDate.AsTime() + mindate = &d + } + var maxdate *time.Time + if req.MaxDate != nil { + d := req.MaxDate.AsTime() + maxdate = &d + } + + bookings, err := s.Handler.GetBookings(mindate, maxdate) + if err != nil { + return nil, status.Errorf(codes.Internal, "error retrieving user bookings - %s", err.Error()) + } + + results := []*proto.CarpoolServiceBooking{} + + for _, b := range bookings { + nb := proto.BookingFromInternal(b) + results = append(results, nb) + } + return &proto.GetCarpoolBookingsResponse{ + Bookings: results, + }, nil +} + func (s *CarpoolServiceServerImpl) UpdateBooking(ctx context.Context, req *proto.UpdateCarpoolBookingRequest) (*proto.UpdateCarpoolBookingResponse, error) { err := s.Handler.UpdateBookingStatus(req.BookingId, req.Status.ToOCSS()) if err != nil { diff --git a/storage/mongodb.go b/storage/mongodb.go index 1330ab6..9d21727 100644 --- a/storage/mongodb.go +++ b/storage/mongodb.go @@ -280,6 +280,29 @@ func (s MongoDBStorage) GetUserBookings(userid string) ([]internal.Booking, erro return bookings, nil } +func (s MongoDBStorage) GetAllBookings() ([]internal.Booking, error) { + findOptions := options.Find() + collection := s.Client.Database(s.DbName).Collection(s.Collections["bookings"]) + cur, err := collection.Find(context.TODO(), bson.M{}, findOptions) + if err != nil { + return nil, err + } + + var bookings []internal.Booking + for cur.Next(context.TODO()) { + var elem internal.Booking + + if err := cur.Decode(&elem); err != nil { + log.Error().Err(err).Msg("error reading bookings response") + return nil, err + } + + bookings = append(bookings, elem) + } + + return bookings, nil +} + func (s MongoDBStorage) UpdateBookingStatus(bookingid string, status string) error { // TODO implement UpdateBookingStatus return errors.New("MongoDB Storage - UpdateBookingStatus not implemented") diff --git a/storage/postgresql.go b/storage/postgresql.go index c26b474..fc5c173 100644 --- a/storage/postgresql.go +++ b/storage/postgresql.go @@ -412,6 +412,66 @@ func (s PostgresqlStorage) GetUserBookings(userid string) ([]internal.Booking, e return results, nil } +func (s PostgresqlStorage) GetAllBookings() ([]internal.Booking, error) { + req := fmt.Sprintf(`select booking, status, driver_route, passenger_route from %s + where 1=1`, s.Tables["bookings"]) + rows, err := s.DbConnection.Query(req) + if err != nil { + log.Error().Err(err).Msg("GetUserBookings query issue") + } + + results := []internal.Booking{} + for rows.Next() { + var booking ocss.Booking + var status string + var bookingbytes, driverroute, passengerroute []byte + err := rows.Scan( + &bookingbytes, + &status, + &driverroute, + &passengerroute, + ) + if err != nil { + log.Error().Err(err).Msg("not able to get and scan booking in GetUsersBooking") + return nil, err + } + + err = json.Unmarshal(bookingbytes, &booking) + if err != nil { + log.Error().Err(err).Msg("issue unmarshalling booking in GetUsersBooking") + return nil, err + } + + // Override booking status + booking.Status = ocss.BookingStatusFromString(status) + + var dr, pr *geojson.FeatureCollection + if driverroute != nil { + dr, err = geojson.UnmarshalFeatureCollection(driverroute) + if err != nil { + log.Error().Err(err).Msg("could not unmarshal driver route feature collection") + return nil, err + } + } + + if passengerroute != nil { + pr, err = geojson.UnmarshalFeatureCollection(passengerroute) + if err != nil { + log.Error().Err(err).Msg("could not unmarshal passenger route feature collection") + return nil, err + } + } + + results = append(results, internal.Booking{ + Booking: booking, + DriverRoute: dr, + PassengerRoute: pr, + }) + + } + return results, nil +} + func (s PostgresqlStorage) StoreRouteSchedules(journeys []internal.PlannedRouteSchedule) error { tx, err := s.DbConnection.Begin() if err != nil { diff --git a/storage/storage.go b/storage/storage.go index 96ba02d..ee09f00 100644 --- a/storage/storage.go +++ b/storage/storage.go @@ -18,6 +18,7 @@ type Storage interface { CreateBooking(internal.Booking) error GetBooking(id string) (*internal.Booking, error) GetUserBookings(userid string) ([]internal.Booking, error) + GetAllBookings() ([]internal.Booking, error) UpdateBookingStatus(bookingid string, status string) error // Caching temporary results