In fact I recently changed dbDump to all/export I think. The problem was
that dbDump did never work.

Instead of the dbDump path it called the {key} path. So it returned an
empty configuration element. The test was still green though. So I added
a size check to the test.

As this ambiguity between {key} and a fixed path can happen any time I
wonder if we should change the paths for the lists like in this case the
configuration items to something like:
/configurations/items/{key} instead of /configurations/{key}.

Christian

On 07.02.2013 10:35, Francesco Chicchiriccò wrote:
> On 06/02/2013 12:08, Jan Bernhardt wrote:
>> Hi Francesco,
>>> From: Francesco Chicchiriccò [mailto:ilgro...@apache.org]
>>>
>>> Hi all,
>>> I am currently completing some modifications started yesterday with
>>> ConfigurationServiceProxy.dbExport() that will involve some
>>> refactoring on
>>> console's HttpResourceStream and also to core's ReportTestITCase.
>>>
>>> Basically, I would like to encapsulate the logic for handling streams
>>> (content.xml and reports in various formats) in the relevant service
>>> proxies.
>>>
>>> While doing this, I've just noticed that ReportSevice has
>>>
>>>       @GET
>>>       @Path("executions/{executionId}/dbDump")
>>>       Response exportExecutionResult(@PathParam("executionId") Long
>>> executionId,
>>>               @QueryParam("format") ReportExecExportFormat fmt);
>>>
>>> while ConfigurationService has
>>>
>>>       @GET
>>>       @Path("dbDump")
>>>       Response dbExport();
>>>
>>> Any special reason for this "dbDump"?
>> No there is no special reason for "dbDump". (Code looks to me, as if
>> this is what happens here.) I only tried to find a consistent manner,
>> who to title a downloadable stream. I'm completely open for any
>> suggestions/improvements for a different URL path.
>
> What about
>
>     @GET
>     @Path("executions/{executionId}/stream")
>     Response exportExecutionResult(@PathParam("executionId") Long
> executionId,
>             @QueryParam("format") ReportExecExportFormat fmt);
>
> and
>
>     @GET
>     @Path("stream")
>     Response dbExport();
>
> ?
>
> Regards.
>


-- 
Christian Schneider
http://www.liquid-reality.de

Open Source Architect
http://www.talend.com

Reply via email to