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.
- Timestamp:
-
05/25/12 15:42:38 (12 years ago)
- Author:
-
atarkowska
- Comment:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
-
-
Property
Priority
changed from
minor
to
critical
-
Property
Component
changed from
General
to
Services
-
Property
Summary
changed from
BUG: omero.sys.Parameters vs _ctx
to
BUG: omero.sys.Parameters vs Ice.Current
-
initial
|
v2
|
|
1 | | With the latest idea of passing current context via omero.group omero.sys.Parameters().filter.groupId should be redundant as mislead and is not taken to the account any more. |
| 1 | The latest changes that allows passing context groupId via Ice.Current to overwrite eventContext.groupId change the usage of omero.sys.Parameters().filter.groupId. |
| 2 | |
| 3 | Competitions: |
| 4 | |
| 5 | {{{ |
| 6 | | omero.sys.Parameters.filter.groupId | Ice.Current | groupId | |
| 7 | |======================================================================================| |
| 8 | | null / >=0 | null | EventContext.groupId | |
| 9 | | null / >=0 | omero.group >= 0 | Ice.Current | |
| 10 | | null | omero.group = -1 | cross group call | |
| 11 | | >=0 | omero.group = -1 | Parameters.filter.groupId | |
| 12 | |
| 13 | }}} |
| 14 | |
| 15 | |
| 16 | Example of overwriting: |
| 17 | |
| 18 | {{{ |
| 19 | p = omero.sys.Parameters() |
| 20 | p.map = {} |
| 21 | f = omero.sys.Filter() |
| 22 | f.limit = rint(100000) |
| 23 | f.groupId = rlong(group_id) |
| 24 | f.ownerId = rlong(experimenter_id) |
| 25 | |
| 26 | sql = "select i from Image i join fetch i.details.owner join fetch i.details.group" |
| 27 | conn.getQueryService().findAllByQuery(sql, p, {'omero.group': "-1"}) |
| 28 | |
| 29 | }}} |
| 30 | |
| 31 | |
| 32 | As discussed, would be nice to invoke wrapper to make sure services' methods are forced to use default value if Ice.Current is not set , like omero.group = -1. That is especially important in ISearch and ITimiline, as those services are expected to make cross group calls by default and results could be easily narrow down by Parameters then. |
1.3.13-PRO © 2008-2011
Agilo Software all
rights reserved
(this page was served in: 0.13234 sec.)