DASH-330 Added event watcher for site.upd. When site is unpublished, the event...

Activity

SAKTRUNK-94 14

Keyboard shortcuts  
Summarize the review outcomes (optional)
 
#permalink

Details

Warning: no files are visible, they have all been filtered.
Participant Role Time Spent Comments Latest Comment
Author 32m 7 Done!
Reviewer - 0% reviewed      
Total   32m 14  
#permalink

Objectives

DASH-330: Dashboard displays events from a previously published site that is unpublished

"Added event watcher for site.upd.
When site is unpublished, the event watcher will remove all news/calendar link associated with the site, so that user won't see any site item in their dashboard tools;
When the site is published, the event watcher will add news/calendar links for eligible users based on existing calendar/news items within the site."

Branches in review

#permalink

Issues Raised From Comments

Key Summary State Assignee
#permalink

General Comments

Reggie Rodrigues

Looks great!

Looks great!

David Haines

The processing processing looks identical for the links and calendar except f...

The processing processing looks identical for the links and calendar except for the name of the methods or sql query. The methods could easily be generalized a bit so that the only difference is which version of the method / query gets called. This makes it easier to test and harder to introduce a mistake by forgetting to update both versions of the method. It also makes it very clear what the differences in the processing are which makes it easier for the next person to understand the code.

Zhen Qian

That's a great suggestion. I have consolidated the functions of (add news li...

That's a great suggestion.

I have consolidated the functions of (add news links, remove news links, add calendar links, and remove calendar links) into one single function:

modifyLinksByContext(context, type, addOrRemove)

So now it is much easier to maintain.

/api/src/.../dash/logic/DashboardLogic.java Changed  
Open in IDE #permalink
/impl/src/.../dao/impl/DashboardDaoImpl.java Changed   4
Open in IDE #permalink
/impl/src/java/.../dash/dao/DashboardDao.java Changed  
Open in IDE #permalink
/impl/.../listener/SiteUpdateEventProcessor.java Added   3
Open in IDE #permalink
/impl/.../logic/DashboardCommonLogicImpl.java Changed  
Open in IDE #permalink
/impl/src/.../logic/DashboardLogicImpl.java Changed   2
Open in IDE #permalink
/impl/src/resources/hsqldb.properties Changed  
Open in IDE #permalink
/impl/src/resources/mysql.properties Changed  
Open in IDE #permalink
/impl/src/resources/oracle.properties Changed  
Open in IDE #permalink
/impl/src/.../dash/mock/DashboardDaoMock.java Changed  
Open in IDE #permalink
/pack/src/webapp/WEB-INF/components.xml Changed   2
Open in IDE #permalink

Review updated: Reload | Ignore | Collapse

You cannot reload the review while writing a comment.

Create issue

X
Assign To Me

Log time against