Hi Ishara, Thank you for pointing this out.
On Tue, Oct 2, 2018 at 5:42 AM Ishara Cooray <[email protected]> wrote: > Hi Wasura, > > I think PARENT_COMMENT_ID should have a default value because first > comment does not have a associated parent comment. > > When we are inserting a parent comment it will not have a PARENT_COMMENT_ID. So this may throw an error due to violation of Referential Integrity Constraint. So I thought not to have any constraint for PARENT_COMMENT_ID and we discussed this yesterday during the code review. > Since there are two fields CREATED_BY and UPDATED_BY I guess comments can > be updated(edit/delete) by someone other than the owner. > +1 for this. I must handle this in the logic when updating a comment. I will look into this matter. > Appreciate if you clarify the expected behavior. > > > Thanks & Regards, > Ishara Cooray > Thank you! > > On Mon, Oct 1, 2018 at 10:54 PM Wasura Wattearachchi <[email protected]> > wrote: > >> Hi all, >> >> According to what we have discussed today during the code review, I added >> a new attribute named ENTRY_POINT to distinguish the role of the person, >> based on the entry point - whether the particular person initiates the >> comment from the API Store or the API Publisher. Following is the ERD for >> that (You can find the newly added attribute in green colour). >> >> >> >> >> Following is the corresponding *table* and the data types. >> >> >> AM_API_COMMENTS >> >> UUID >> >> VARCHAR(255) >> >> PRIMARY KEY >> >> COMMENT_TEXT >> >> TEXT >> >> USER_IDENTIFIER >> >> VARCHAR(255) >> >> CATEGORY >> >> VARCHAR(20) >> >> DEFAULT ‘General’ >> >> PARENT_COMMENT_ID >> >> VARCHAR(255) >> >> ENTRY_POINT >> >> VARCHAR(20) >> >> API_ID >> >> VARCHAR(255) >> >> FOREIGN KEY REFERENCES AM_API (UUID) ON DELETE CASCADE ON UPDATE CASCADE >> >> CREATED_BY >> >> VARCHAR(100) >> >> CREATED_TIME >> >> TIMESTAMP >> >> DEFAULT CURRENT_TIMESTAMP >> >> UPDATED_BY >> >> VARCHAR(100) >> >> UPDATED_TIME >> >> TIMESTAMP >> >> DEFAULT CURRENT_TIMESTAMP >> >> >> I would much appreciate if you can provide feedback and suggestions. >> >> >> Thank you! >> >> >> On Wed, Sep 19, 2018 at 10:24 AM Ishara Cooray <[email protected]> wrote: >> >>> Hi, >>> >>> Thanks for the clarification Wasura. >>> >>> In C5 we have used *USER_IDENTIFIER* in below APIM tables. >>> AM_USER_NAME_MAPPING >>> AM_API_RATINGS >>> AM_API_COMMENTS >>> >>> But in C5 UM tables we still have used *USER_ID*. >>> >>> AUTH_UM_PASSWORD_INFO >>> AUTH_UM_USER_GROUP >>> AUTH_UM_USER_ATTRIBUTES >>> >>> Is there any particular reason for that? >>> >>> I am +1 to use USER_ID in apim tables as well. >>> >>> >>> Thanks & Regards, >>> Ishara Cooray >>> Senior Software Engineer >>> Mobile : +9477 262 9512 >>> WSO2, Inc. | http://wso2.com/ >>> Lean . Enterprise . Middleware >>> >>> On Tue, Sep 18, 2018 at 9:17 PM, Wasura Wattearachchi <[email protected]> >>> wrote: >>> >>>> Hi Ishara, >>>> >>>> I agree with you. It is better to have USER_ID rather than >>>> USER_IDENTIFIER. But there is a problem. I checked all the tables in >>>> the database again and found that there are some tables which have >>>> USER_IDENTIFIER column (which is used to symbolize the username of the >>>> current user like in AM_API_COMMENTS table). >>>> So if I change the USER_IDENTIFIER field to USER_ID in my table >>>> (AM_API_COMMENTS) then the consistency of the database will be lost, >>>> because other tables have it as USER_IDENTIFIER while AM_API_COMMENTS has >>>> it as USER_ID. >>>> >>>> So I think it is better to keep it this way as USER_IDENTIFIER without >>>> doing any changes. What are the ideas of others? >>>> >>>> Thanks! >>>> >>>> On Tue, Sep 18, 2018 at 5:47 AM Ishara Cooray <[email protected]> wrote: >>>> >>>>> Hi Wasura, >>>>> We can simplify USER_IDENTIFIER field as USER_ID >>>>> >>>>> And also I think we need to categorize comments as "Bug", "Feature >>>>> Request" or "General". By default it should be "General. >>>>> >>>>> What is the way that we identify the category of a particular comment? >>>>> >>>> >>>> >>>> -- >>>> Wasura Wattearachchi >>>> Software Engineer Intern | WSO2 >>>> >>>> Email: [email protected] <[email protected]> >>>> Mobile: +94775396038 >>>> >>> >>> >> >> -- >> Wasura Wattearachchi >> Software Engineer Intern | WSO2 >> >> Email: [email protected] <[email protected]> >> Mobile: +94775396038 >> <http://wso2.com/signature> >> > -- Wasura Wattearachchi Software Engineer Intern | WSO2 Email: [email protected] <[email protected]> Mobile: +94775396038 <http://wso2.com/signature>
_______________________________________________ Architecture mailing list [email protected] https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
