I would add to that plan working with the registry team on optimizing the performance from their side. We had huge success doing that for API Cloud - told GReg team which query was too slow and why and they created a fix that helped us.
Dmitry On Fri, Mar 13, 2015 at 2:28 AM, Gayan Dhanushka <[email protected]> wrote: > Hi all, > > I have been working on improving the performance in the user home page as > a result of the above findings. > > *Getting all applications of the user from the back end only when users > are added to new applications* > > I have removed getting all applications of the user when the user home > page is accessed after a certain period of time. Getting the whole > application list of a particular user needs multiple calls to read rxts and > particular information like the branch count from the runtime database. > Hence this is a very costly operation. Therefore I have introduced a cache > in the back end so that whenever a user is added to a newly created > application the cache entry is created. So whenever the user home page is > loaded first this cache will be searched for that particular user and > unless the used exists in the cache application home data will not be > loaded from the rxts and the runtime database. > > *Introducing a ApplicationSummary object* > > Up until now we had a ApplicationInfoBean object which contained all the > data I have created a new ApplicationSummary object which contains only the > applicationName, applicationKey and applicationType which are the only > attributed that is needed to populate the user home page. By doing this the > database calls to retrieve the branch count is removed. These database > calls were made while retrieving information for each application. > Therefore this would make a considerable improvement when it comes to users > with a number of applications. > > Furthermore I am +1 for removing the application creation status from the > database as well since it can be ignored when retrieving user home > information. The only use case that I can think of it is that when some one > creates an application and if he immediately logs out and logs in. This is > very unlikely to happen. Please share your thoughts about this. > > Regards > Gayan > > > > On Fri, Mar 13, 2015 at 11:58 AM, Dimuthu Leelarathne <[email protected]> > wrote: > >> Hi all, >> >> In our efforts to improve performance this is going to be our approach. >> >> *BE Performance* - We are going to keep profiling and improving the BE >> performance. This includes registry and db access. So the idea is to cache >> data in session when applicable and cache data at Carbon cache layer when >> applicable. >> >> As a start we have profiled the user home data. I am attaching java >> profiler snapshot. And as a result Gayan is working on put app home data >> to session and clear it when the user is invited to the app (happen over >> the cluster). Likewise we'll keep on profiling and caching appropriately >> when it is applicable/appropriate. Even though registry is aching rxts, >> accessing it is costly at times. We'll keep updating architecture@ and >> dev@ with our efforts. >> >> *FE Performance* - Next step is to use browser local cache with web >> sockets when applicable. Nginx is supporting web sockets. For example we >> can cache the Application object in the browser cache whenever app home is >> loaded and keep updating certain fields via web sockets. As discussed with >> the UI team we'll be writing a generic layer to do that. >> >> thanks, >> dimuthu >> >> -- >> Dimuthu Leelarathne >> Architect & Product Lead of App Factory >> >> WSO2, Inc. (http://wso2.com) >> email: [email protected] >> Mobile : 0773661935 >> >> Lean . Enterprise . Middleware >> > > > > -- > Gayan Dhanuska > Software Engineer > http://wso2.com/ > Lean Enterprise Middleware > > Mobile > 071 666 2327 > > Office > Tel : 94 11 214 5345 > Fax : 94 11 214 5300 > > Twitter : https://twitter.com/gayanlggd > -- Dmitry Sotnikov VP of Cloud; WSO2, Inc.; http://wso2.com/ email: [email protected]; cell: +1.949.303.9653; Skype: DSotnikov Lean . Enterprise . Middleware <http://wso2.com/events/>
_______________________________________________ Architecture mailing list [email protected] https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
