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"

Bug #910 (closed)

Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

IAdmin.lookupGroups does not load the group of the users of a group

Reported by: jamoore Owned by: jamoore
Priority: minor Cc: jburel
Sprint: n.a.
Total Remaining Time: n.a.

Description

From Jean-Marie:

I know have the following error:

java.lang.NullPointerException
 at pojos.ExperimenterData.getDefaultGroup(ExperimenterData.java:219)

Basically Experimenter.getGroups() is always null

Experimenters are retrieved using
IAdmin service = getAdminService();
List<ExperimenterGroup> groups = service.lookupGroups();

This code used to work.
... I would imagine post session.

Change History (3)

comment:1 Changed 16 years ago by jmoore

  • Cc jburel added

The query itself does not load the group of the experimenter in
a group and never has:

      @RolesAllowed("user")
      public List<ExperimenterGroup> lookupGroups() {
              return iQuery.findAllByQuery("select g from ExperimenterGroup g "
                              + "left outer join fetch g.groupExperimenterMap m "
                              + "left outer join fetch m.child", null);
      }

Probably what was happening pre-sessions is that since login was
happening on each call, the experimenter was being loaded even on
read-only calls. Now it's only loaded on write calls at the most.

Should i add:

"left outer join fetch child.groupExperimenterMap m2 "
"left outer join fetch m2.parent " ?

comment:2 Changed 16 years ago by jmoore

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

r2326 closes. Jean-Marie, if there are any other changes like this, we may should look at doing them all in beta4 and updating the javadocs for IAdmin.

comment:3 Changed 16 years ago by jburel

The reason I entered the ticket is b/c insight crashes when switching to another user,
and insight code did not change.

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.64469 sec.)

We're Hiring!