-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/17888/#review35465
-----------------------------------------------------------


Antonio, I see a lot of following statements in the log:

WARN  [c.c.a.d.ParamGenericValidationWorker] 
(915287025@qtp-639735230-0:ctx-2d569730 ctx-4a62e44e ctx-9daa3a7a) Received 
unkown parameters for command listresourcedetailsresponse. Unknown parameters : 
signature apikey
WARN  [c.c.a.d.ParamGenericValidationWorker] 
(915287025@qtp-639735230-0:ctx-bf65e84b ctx-324455f7 ctx-e35e2f8c) Received 
unkown parameters for command listresourcedetailsresponse. Unknown parameters : 
signature apikey
WARN  [c.c.a.d.ParamGenericValidationWorker] 
(915287025@qtp-639735230-0:ctx-53c56b66 ctx-8fc794cf ctx-73a9769d) Received 
unkown parameters for command listresourcedetailsresponse. Unknown parameters : 
signature apikey
WARN  [c.c.a.d.ParamGenericValidationWorker] 
(915287025@qtp-639735230-0:ctx-5b1b394d ctx-e3dadaf6 ctx-855d01b0) Received 
unkown parameters for command listvolumesresponse. Unknown parameters : 
signature apikey
WARN  [c.c.a.d.ParamGenericValidationWorker] 
(915287025@qtp-639735230-0:ctx-d5f66fed ctx-a345e484 ctx-b24443e3) Received 
unkown parameters for command listnicsresponse. Unknown parameters : signature 
apikey

Signature and api key are generic parameters and passed to every command when 
its authenticated with api/secret key


WARN  [c.c.a.d.ParamGenericValidationWorker] 
(915287025@qtp-639735230-0:ctx-6f93bea3 ctx-30322830 ctx-ae8ac900) Received 
unkown parameters for command listserviceofferingsresponse. Unknown parameters 
: listall signature apikey

listAll is also generic. 

In other words, you should validate parameters not just against those defined 
in the command class itself, but also:

* the classes the command inherits from
* generic parameters like apikey/secretkey. There may be more, please double 
check.

And minor thing - correct the spelling of word "unknown" in your logs.

- Alena Prokharchyk


On Feb. 25, 2014, 12:11 p.m., Antonio Fornie wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/17888/
> -----------------------------------------------------------
> 
> (Updated Feb. 25, 2014, 12:11 p.m.)
> 
> 
> Review request for cloudstack, Alena Prokharchyk, daan Hoogland, and Hugo 
> Trippaers.
> 
> 
> Repository: cloudstack-git
> 
> 
> Description
> -------
> 
> Dispatcher corrections, refactoring and tests. Corrects problems from 
> previous attempts that were reverted by Alena. Most of the changes are the 
> same, but this one is not creating conflicts of Map types for Aync Commands 
> or for parameters as Lists or Maps.
> 
> 
> Diffs
> -----
> 
>   api/src/org/apache/cloudstack/api/ApiConstants.java 7b7f9ca 
>   api/src/org/apache/cloudstack/api/BaseCmd.java 0e83cee 
>   api/src/org/apache/cloudstack/api/BaseListCmd.java c1a4b4c 
>   
> api/src/org/apache/cloudstack/api/command/user/autoscale/CreateAutoScaleVmProfileCmd.java
>  06d86ec 
>   
> server/resources/META-INF/cloudstack/core/spring-server-core-misc-context.xml 
> fd2f5fb 
>   server/src/com/cloud/api/ApiAsyncJobDispatcher.java 71ac616 
>   server/src/com/cloud/api/ApiDispatcher.java ed95c72 
>   server/src/com/cloud/api/ApiServer.java d715db6 
>   server/src/com/cloud/api/ApiServlet.java 46f7eba 
>   server/src/com/cloud/api/dispatch/CommandCreationWorker.java PRE-CREATION 
>   server/src/com/cloud/api/dispatch/DispatchChain.java PRE-CREATION 
>   server/src/com/cloud/api/dispatch/DispatchChainFactory.java PRE-CREATION 
>   server/src/com/cloud/api/dispatch/DispatchTask.java PRE-CREATION 
>   server/src/com/cloud/api/dispatch/DispatchWorker.java PRE-CREATION 
>   server/src/com/cloud/api/dispatch/ParamGenericValidationWorker.java 
> PRE-CREATION 
>   server/src/com/cloud/api/dispatch/ParamProcessWorker.java PRE-CREATION 
>   server/src/com/cloud/api/dispatch/ParamSemanticValidationWorker.java 
> PRE-CREATION 
>   server/src/com/cloud/api/dispatch/ParamUnpackWorker.java PRE-CREATION 
>   server/src/com/cloud/network/as/AutoScaleManagerImpl.java ff2b2ea 
>   server/src/com/cloud/storage/snapshot/SnapshotSchedulerImpl.java 3159059 
>   server/test/com/cloud/api/ApiDispatcherTest.java 7314a57 
>   server/test/com/cloud/api/dispatch/CommandCreationWorkerTest.java 
> PRE-CREATION 
>   server/test/com/cloud/api/dispatch/DispatchChainFactoryTest.java 
> PRE-CREATION 
>   server/test/com/cloud/api/dispatch/ParamGenericValidationWorkerTest.java 
> PRE-CREATION 
>   server/test/com/cloud/api/dispatch/ParamProcessWorkerTest.java PRE-CREATION 
>   server/test/com/cloud/api/dispatch/ParamSemanticValidationWorkerTest.java 
> PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/17888/diff/
> 
> 
> Testing
> -------
> 
> Full build and test plus manually testing many features. Also including 
> CreateTagsCommand that failed in previous commit.
> 
> All unit and integration tests.
> 
> Test CS Web UI with the browser going through several use cases.
> 
> Also use the CS API by sending HTTP requests generated manually including 
> requests for Async Commands with Map parameters and during these tests apart 
> fromtesting correct functionality I also debugged to check that Maps created 
> correctly where they should but also that in the cases where the async 
> command must be persisted and later on retrieved and deserialized by gson 
> everything works ok and does what and where is expected. An example based on 
> the comment by Alena:
> http://localhost:8096/client/api?command=createTags&resourceids=ids&resourcetype=type&tags[0].key=region&tags[0].value=canada
> Also other examples like
> http://localhost:8096/client/api?command=createSecondaryStagingStore&url=httpbla&details[0].key=region&details[0].value=canada&details[1].key=element&details[1].value=fire
> 
> 
> Thanks,
> 
> Antonio Fornie
> 
>

Reply via email to