cancel
Showing results for 
Search instead for 
Did you mean: 

How does the 'site activities' dashlet work?

daforce93
Champ in-the-making
Champ in-the-making
Hi everyone,

I know that the "site activities" dashlet in Share works by first doing a GET request to share/service/components/dashlets/activities/list, which then sends a GET request to the webscript at api/activities/feed/user.

I think (though I'm not 100% sure on this) that the executeImpl method of the UserFeedRetrieverWebScript class (see: https://github.com/Alfresco/community-edition/blob/70f90384d2745fbc0c1d1be2aaa01cab40c47f34/projects...) is then called. Then, the getUserFeedEntries method of ActivityServiceImpl is called (see: https://github.com/Alfresco/community-edition/blob/70f90384d2745fbc0c1d1be2aaa01cab40c47f34/projects...), which then calls feedDAO.selectUserFeedEntries, which does some SQL Queries using MyBatis.

My question is this: Is there a table that holds the activities themselves? If that is the case, then wouldn't each action (that could show up in an Activities feed) need to insert into this table?

Thanks,

Jordan
1 ACCEPTED ANSWER

janv
Employee
Employee

Hi Jordan,

Thanks for the detailed question. If you're interested in the original design then please take a look at 3.0 Activities Design 

Essentially, activities are posted to the "alf_activity_post",table and then background jobs handle the "generation" of the user-specific activity feeds (that are held in the "alf_activity_feed") table. This has handled the initial requirements relatively well over time, no pun intended 😉

However, in the future, we would like to improve the capabilities of the activity streams and take the opportunity to revisit and improve the overall architecture and design.

Regards,

Jan

View answer in original post

2 REPLIES 2

jpotts
World-Class Innovator
World-Class Innovator

When someone starts asking about the database schema my spidey sense starts tingling.

Are you thinking of writing into that table directly?

janv
Employee
Employee

Hi Jordan,

Thanks for the detailed question. If you're interested in the original design then please take a look at 3.0 Activities Design 

Essentially, activities are posted to the "alf_activity_post",table and then background jobs handle the "generation" of the user-specific activity feeds (that are held in the "alf_activity_feed") table. This has handled the initial requirements relatively well over time, no pun intended 😉

However, in the future, we would like to improve the capabilities of the activity streams and take the opportunity to revisit and improve the overall architecture and design.

Regards,

Jan