Bug 905140 - Code change request - refactor AsyncDataProvider (and other DataProvider)
Summary: Code change request - refactor AsyncDataProvider (and other DataProvider)
Keywords:
Status: CLOSED DEFERRED
Alias: None
Product: oVirt
Classification: Retired
Component: ovirt-engine-webadmin
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Einav Cohen
QA Contact:
URL:
Whiteboard: ux
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-01-28 16:51 UTC by Yair Zaslavsky
Modified: 2016-01-28 21:56 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-12-09 14:53:26 UTC
oVirt Team: ---
Embargoed:


Attachments (Terms of Use)

Description Yair Zaslavsky 2013-01-28 16:51:18 UTC
Description of problem:

I would suggest to break down AsyncDataProvider and other DataProvider classes to classes based on entities.

A similar approach was done with DbFacade class at engine - it contained lots of methods for CRUD operations on engine - these were extracted out to DAOs (VmStaticDao , etc...)

I think this will make the code more readable.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Itamar Heim 2013-12-01 08:47:40 UTC
vojtech - can be closed as part of the rest api work?

Comment 2 Vojtech Szocs 2013-12-09 14:22:24 UTC
(In reply to Itamar Heim from comment #1)
> vojtech - can be closed as part of the rest api work?

Yes, I think we can close this for now.

AsyncDataProvider class still contains lots of code, however this code invokes queries via GWT RPC.

Assuming oVirt JavaScript SDK initiative, when moving UI to work with REST API, we can do one of following:

1, aggregate helper methods based on logical entity (as suggested by Yair) as part of continual transition to REST API usage

2, move these helper methods (or a subset) into JavaScript SDK itself

Comment 3 Itamar Heim 2013-12-09 14:53:26 UTC
going to be resolved via the move to rest api


Note You need to log in before you can comment on or make changes to this bug.