revamp the data module for better api and working with auto update#1916
revamp the data module for better api and working with auto update#1916tardyp merged 23 commits intobuildbot:masterfrom
Conversation
Current coverage is
|
|
@tothandras: intermediate working version. (auto update is not finished though) |
|
@rutsky 1b9b86d version has autoupdate working pretty much reliably. I want to continue and make a big api change (simplification) before merging it. dataService.get will not return promise, but directly the collection, as the promise is not appropriate for a constantly updating data |
|
@tardyp You put a lot of work into this! ;) Looks good, although I didn't have time to test it.
What about getting related data? In a lot of cases we need to know some resolved data before making the next request. |
|
@tardyp, I checked your recent changes and noticed, that test fails: Other than that issue with test, forcescheduler works for me. |
|
@tardyp, when I open waterfall view (that should contain three completed builds) I get stack overflow error:
As I see |
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
- improve data mock to add expectations - make accessor a private method of Base data class - default subscribe is now true if via accessor, false if via dataapi. Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
first initial load, then the updates from REST api Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Simplify the initial data gathering
get does not return promise, but a collection lots of fixes simplification and cleanup made possible with this new api Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
|
@tothandras you can see the onNew, onChange callbacks that are made for dealing with loading more data, and doing stuff on the flow. |
|
@tardyp great! 👍 |
It is available from db api, and very useful for the UI for efficient way to know builder is obsolete Signed-off-by: Pierre Tardy <tardyp@gmail.com>
and improvements: - minimal height for builds - only display for builders that have master attached (e.g filter out obsolete builders) - fix +, - key bindings Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
- Unit tests should be converted to dataService.when - build tab does not work yet Signed-off-by: Pierre Tardy <tardyp@gmail.com>
|
started the port of md_base. |
|
Of course. I will have a look at it
|
|
@tardyp It seems that the currently |
|
@shanzi, by default it checks out the last published version of data module. You will need to use the link trick in order to develop with a change data module: |
There was a problem hiding this comment.
@tardyp I found the problem exists here. The restService successfully fetched the builds of a builder but at here they are all be filtered out.
The problems is that, in the query filter, we have a field named builderid with its value to be "2"(string). But in the array of BuildInstance, the builderid field is 2(Integer). The coffee script translate == into ===, so "2" != 2. Thus for BuildInstance this function always returns false. This causes the problem that prevent the displaying of builds in builder page.
There was a problem hiding this comment.
I make a pull request here tardyp#7
Though the list of builds is displaying now, we still have problems displaying a single build. I will look into that later.
|
@tardyp I have a trouble setting up My node version is |
|
@shanzi I experienced same error, see https://irclogs.jackgrigg.com/irc.freenode.net/buildbot/2015-12-26#i_3767937 |
|
Try to install older version of guanlecoja, e.g. |
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
Signed-off-by: Pierre Tardy <tardyp@gmail.com>
|
Removing do not merge, as I think it is ready for merge. md_base is "kinda" working, and is in a state were it shows its great potential. I've updated the documentation. A notable change is that I added a dependency on blockdiag, which is a nice sphinx extension to build decent looking diagrams using text only description (kind of like graphviz, but with much better look) |
|
@tardyp Is waterfall view and console view should work? They don't in my configuration. Force build and rebuild works good. |
|
Yes, it is supposed to work. what is the error? Le ven. 1 janv. 2016 à 22:08, Vladimir Rutsky notifications@github.com a
|
|
@tardyp when I open Console view (http://localhost:8080/#/console) I see infinitely spinning loader. I don't see any errors in the Firefox console. Waterfall view works. During Force build (and some other operations) I see |
|
Console view doesn't work when there is no change source. It only display Here, the design make it difficult to distinguish no data compared to data Le sam. 2 janv. 2016 12:51, Vladimir Rutsky notifications@github.com a
|
|
I'd like to merge this by end of day if there are no objection. |
revamp the data module for better api and working with auto update
In my tests, the midterm version does not work well with updates.
I liked the collection class from the final version, so I include it back, as well as the js query implementation.
The idea is to have the collection listening to its own events and reapply the query when modified.
some of the details are described here:
https://docs.google.com/document/d/1VRdY2lqyz0UnbD4kllkzXBDIGDDoxvVgmWjn6M3oK4A/edit?ts=563b583f#