Warning: Can't synchronize with repository "(default)" (/home/git/ome.git does not appear to be a Git repository.). Look in the Trac log for more information.
Notice: In order to edit this ticket you need to be either: a Product Owner, The owner or the reporter of the ticket, or, in case of a Task not yet assigned, a team_member"

Task #3895 (closed)

Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

look at containerService

Reported by: wmoore Owned by: wmoore
Priority: major Milestone: OMERO-Beta4.3
Component: Web Version: n.a.
Keywords: n.a. Cc: cneves, atarkowska
Resources: n.a. Referenced By: n.a.
References: n.a. Remaining Time: n.a.
Sprint: 2011-01-27 (4)

Description (last modified by wmoore)

Investigate the possibility of using the container service for various 'container' methods.

  • Review, organise & group current 'container' methods together in webclient_gateway
  • Try using container service for one or more methods:
    • Does container service provide filter by user etc
    • Are the details, owner etc loaded?
  • NB: Given the current 'lazy loading' strategy in Blitz Gateway, it never makes sense to load children of any object?

For example: listProjects can be implemented with code like this:

def listProjects(self, eid=None):
    params = omero.sys.Parameters()
    params.map = {}
    f = omero.sys.Filter()
    f.ownerId = rlong(long(eid))
    params.theFilter = f
    cs = self.getContainerService()
    ps = cs.loadContainerHierarchy("Project", None, params)
    projs = [ProjectWrapper(conn, p) for p in ps]
    projs.sort(key=lambda x: x.name)
    return projs

Points to note:

  • sorting by name is client-side (maybe don't bother)?
  • Project.details.owner and Project.details.creationEvent are not loaded (need to be loaded by subsequent calls if needed.
  • Should they be loaded by the Container Service?

Change History (5)

comment:1 Changed 13 years ago by wmoore

  • Status changed from new to accepted

comment:2 Changed 13 years ago by wmoore

  • Description modified (diff)

comment:3 Changed 13 years ago by wmoore

If we move to using Container Service for the various loading methods in gateway, then we need to load details in subsequent calls OR change Container Service.

NB: up till now, all calls to creationEventDate() have been using iQuery, since the method was broken for returning the already-loaded details.

comment:4 Changed 13 years ago by wmoore

  • Resolution set to fixed
  • Status changed from accepted to closed

comment:5 Changed 13 years ago by wmoore

(In [8932/omero]) Highlighting (already grouped) container methods in webclient_gateway.py See #3895

Note: See TracTickets for help on using tickets. You may also have a look at Agilo extensions to the ticket.

1.3.13-PRO © 2008-2011 Agilo Software all rights reserved (this page was served in: 0.67796 sec.)

We're Hiring!