Bug 711005 - Return all relevant information in xml-rpc call
Summary: Return all relevant information in xml-rpc call
Keywords:
Status: VERIFIED
Alias: None
Product: TCMS
Classification: Other
Component: Application
Version: 3.4
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: ---
Assignee: Yuguang Wang
QA Contact: Nobody
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-06-06 07:49 UTC by Marian Ganisin
Modified: 2022-03-14 03:26 UTC (History)
4 users (show)

Fixed In Version: 3.5.0-1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)

Description Marian Ganisin 2011-06-06 07:49:08 UTC
Description of problem:

Many xml-rpc calls don't return all important values. For example build is missing in requests like TestRun.get(), only build_id is returned what is not enough in many common cases.

It causes one (or both) of:
1) High server load due to additional rpc calls
2) High complexity of client tools if utilizing xmlr-rpc MultiCall

It would be great to have all values returned by one call. I already noted something similar in Bug 595372, though more values should be handled. Here is list of some interesting attributes:

1. env values+name in TestRun.get and others like TestPlan.get_runs() (improvement in Bug 595372 still requires additional call per testrun)
2. build name in any call like TestRun.get, TestRun.get_test_cases, TestCase.get etc.
3. tags (obviously in name form) for any object if it can be tagged

Some typical use cases:
1. Get tagged runs in some plan (1 * get_runs + n * get_tags where n is number of runs in plan)
2. Get runs for specified arch (saved in env) in some plan (1 * get_runs + n * get_env_values + 1 * Env.get_properties)
3. Get tagged cases in some plan (1 * get_cases + n * get_tags)
4. Get runs for build in some plan (1 * get_runs + n * Build.get)

Comment 1 Yuguang Wang 2011-06-07 08:21:15 UTC
hi Marian,

Thanks for your suggestion, I'll take it.
Hopefully it would be fixed in version 3.5.

Comment 2 Yuguang Wang 2011-07-04 10:22:12 UTC
Added the necessary fields for return values.

Will inform you to verify when it's online.

Comment 3 Marian Ganisin 2011-07-04 10:38:17 UTC
(In reply to comment #2)
> Added the necessary fields for return values.
> 
> Will inform you to verify when it's online.

Sound great. Waiting for poke...

Comment 4 Jin Zhao 2011-07-14 10:22:38 UTC
Verify 3.5.0-1 on stage -->PASS

>>> handle.server.TestRun.get(22081)
{'build_id': 1171, 'environment_id': '0', 'plan_id': 4036, 'start_date': '2011-06-23 10:25:40', 'run_id': '22081', 'estimated_time': '00:00:00', 'plan': 'Copy of Copy of Test Plan for TCMS3.4 (Regression) ', 'stop_date': 'None', 'product_version': '4.0', 'summary': 'Test run for Copy of Copy of Test Plan for TCMS3.4 (Regression)  on Unknown environment', 'manager': 'jzhao', 'build': '3.2-4', 'notes': '', 'plan_text_version': '2', 'default_tester_id': 2778, 'default_tester': 'jzhao', 'manager_id': 2778}
>>> 

Actual result: 
Now the return value TestRun.get() plan name / manager name / Build / Default_tester name 

All the return value contains not only ID but also name.

Comment 5 Marian Ganisin 2011-07-18 08:34:51 UTC
I tried this on stage, it looks great. Even if it doesn't cover all cases I described in report (additional requests are required for environment and tags) I am fine with that, actually I am not using env and tags at the moment.

This will really help to reduce load of server!

Comment 6 Yuguang Wang 2011-07-18 09:13:00 UTC
Thanks for feedback, rpc needs lots of improvements in future.
(In reply to comment #5)
> I tried this on stage, it looks great. Even if it doesn't cover all cases I
> described in report (additional requests are required for environment and tags)
> I am fine with that, actually I am not using env and tags at the moment.
> 
> This will really help to reduce load of server!


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