= V2, MAPS and Infrastructure - Performance Issues = [[V2Master]] <> = Introduction = Includes issues associated with: 1. V2 1. MAPS 1. Infrastructure = V2 Issues = First manual tests are beased on a development database, migrated from a Linthal DrawMGT V14.0 system: - 29076 documents - 41240 revisions - Classifications not migrated yet == General == === Open/Close blocks === We should consider the possibility to load blocks only if the user open it, and load it through unobtrusive javascript. === General Caching === We should consider using some general caching gem, e.g. [[https://github.com/matthewrudy/memoist|memoist]] == Document List == To display a page of the document list by selecting one of the page buttons took before any changes about '''6.3 s'''. === Minimize Selecting Folders === Based on the server log there are more than '''700''' select was performed from the table ''folders'', however only '''143''' caused an SQL call, the rest was taken from Rails SQL cache. '''SOLUTION (done)''': the Folder methods ''get_folders_permitted'', ''get_self_and_ancestors'' and ''get_self_and_descendants'' are using an own cache. The elapsed time improvement is about '''1.2 s'''. It seems, that the creation of the model instances takes so much time, even if no database access is performed. === Optimize SQL === It is not really possible to optimize the SQL, it's quite quick. We could set database indexes for all potential search fields. However the problem is that every document search starts with the list of all documents. In DrawMGT listing filters by the current contract and not the whole database is listed. Probably we should eliminate list functions of models with many records and display only the search block on the first call. '''TO BE DECIDED''' == Classification List == Practically unusable. It is so slow on a couple hundred records, than to move an element to more than 1 line up or down is nerve-racking. * Up/Down/Delete should work with unobtrusive !JavaScript. * Probably only the opened blocks should be loaded. = MAPS Issues = = Infrastructure Issues =