ShadowHokageForge / event-management

0 stars 0 forks source link

Event Service - Create DB Design #4

Closed SixPathsSage closed 1 hour ago

SixPathsSage commented 6 days ago

Description:

  1. Create a detailed Entity Relationship Diagram for event service.
  2. Mention all the tables and their relationship.
  3. Include all the Constraints in the diagram.
SixPathsSage commented 18 hours ago

image

Source

```plantuml @startuml skinparam linetype ortho left to right direction entity "event" as event { *id : UUID <> -- name : varchar(256) detail : text from: timestampz to: timestampz event_thumbnail_link: varchar(2048) is_online: boolean event_link: varchar(2048) location_id: uuid <> created_on: timestampz updated_on: timestampz created_by: uuid updated_by: uuid } entity "event_location_map" as event_location_map { *id : UUID <> -- latitude: varchar(11) longitude: varchar(12) name: varchar(256) address: text street: varchar(256) locality: varchar(256) city: varchar(256) state: varchar(256) country: varchar(256) event_id: UUID <> created_on: timestampz updated_on: timestampz created_by: uuid updated_by: uuid } entity "event_tag_map" as event_tag_map { tag_id : UUID <> event_id : UUID <> } entity "tag" as tag { *id : UUID <> -- name : varchar(50) } entity "comment" as comment { *id : UUID <> -- comment : text likes: long commented_on: timestampz commented_by: UUID } entity "comment_like_map" as comment_like_map { *id : UUID <> -- user_id : text comment_id: long } entity "reply" as reply { *id : UUID <> -- reply : text likes: long replied_on: timestampz replied_by: UUID comment_id: UUID } entity "reply_like_map" as reply_like_map { *id : UUID <> -- user_id : text reply_id: long } entity "user_entity" as user_entity { *id : UUID <> -- // Keycloak } note right of user_entity This table is present in keycloak db end note entity "event_attendee_map" as event_attendee_map { event_id: UUID user_id: UUID is_host: boolean } event ||..|| event_location_map event_tag_map }|..|| event event_tag_map }|..|| tag comment_like_map }|..|| comment comment }|..|| event reply_like_map }|..|| reply reply }|..|| comment event_attendee_map }|..|| user_entity event_attendee_map }|..|| event @enduml ```

SixPathsSage commented 18 hours ago

@RudhraBharathy Please review the DB Design

RudhraBharathy commented 1 hour ago

@SixPathsSage DB design looks fine!!