Thanks for the explanation Achim. Will see if I can get further now.

/Bengt


2012/12/14 Achim Nierbeck <[email protected]>

> Hi Bengt,
>
> let's try to clarify this. Pax-Web starts the jetty container and
> configures it by
> 1) using the configuration through the configuration admin service. As
> it's a requirement by the OSGi spec that the service port is configured
> that way.
> 2) reading the jetty.xml file either through the configured config.file
> property or if available from the class-space (attached by a fragment)
>
> So if pax-web is running in Karaf you can stick to the jetty.xml in the
> etc folder, you don't need a fragment bundle for this case.
>
> The configuration you have in your cfg file will override the
> configuration of the feature file.
>
> Finally to your last question of how to use the jetty.xml file.
> Basically it's the way described at [1]. For certain configurations you
> need to change the way to get a hold on it, cause the jetty.xml file is
> interpreted after the server has already been configured. So basically it's
> a "re-configuration" of the existing instance so if there are examples on
> how to use it for jetty-web.xml you should try that kind of configuration
> also. :)
>
> regards, Achim
>
>
> 2012/12/14 Bengt Rodehav <[email protected]>
>
>> Thanks for your reply Achim.
>>
>> However, I don't quite understand how this works - is this described
>> somewhere? Things that would be nice to understand are:
>>
>> - What role does the jettyconfig file has?
>> - What role does etc/jetty.xml has? Is it generated?
>> - How is the final jetty configuration built up?
>> - When do I have to use a fragment (as described on the wiki)?
>>
>> To top it off I also have my ownd etc/org.ops4j.pax.web.cfg file. I'm not
>> sure how it works together with the default configuration in the feature.
>>
>> Just trying to get a grasp on this...
>>
>> /Bengt
>>
>>
>>
>>
>> 2012/12/14 Achim Nierbeck <[email protected]>
>>
>>> Hi Bengt,
>>>
>>> since the Jetty.xml isn't the "lead" configuration for the jetty file
>>> and since the jetty is started in the "embedded" style you need to get a
>>> hold of this a bit different, or
>>> you use a jetty-web.xml file.
>>>
>>> I'm not sure about the right syntax right now, but since it doesn't work
>>> and the jetty.xml is interpreted after the server is configured you
>>> probably need some getAttribute first.
>>> A maybe not so good matching example can be found at [1]
>>>
>>> regards, Achim
>>>
>>> [1] - http://nierbeck.de/cgi-bin/weblog_basic/index.php?p=165
>>>
>>>
>>>
>>> 2012/12/14 Bengt Rodehav <[email protected]>
>>>
>>>> I'm running a web application on Karaf 2.2.8. I need to send quite a
>>>> lot of data to the server using the POST method. I get the following error
>>>> message on the web browser side:
>>>>
>>>> Form too large1588889>200000
>>>>
>>>> After googling I found how to reconfigure this on
>>>> http://wiki.eclipse.org/Jetty/Howto/Configure_Form_Size.
>>>>
>>>> I therefore modified the etc/jetty.xml as follows:
>>>>
>>>> ...
>>>> <Configure class="org.eclipse.jetty.server.Server">
>>>>     <Call name="setAttribute">
>>>>       <Arg>org.eclipse.jetty.server.Request.maxFormContentSize</Arg>
>>>>       <Arg>2000000</Arg>
>>>>     </Call>
>>>> ...
>>>>
>>>> But I still get the same error message. The configuration hasn't
>>>> changed. Am I doing this the wrong way?
>>>>
>>>> /Bengt
>>>>
>>>
>>>
>>>
>>> --
>>>
>>> Apache Karaf <http://karaf.apache.org/> Committer & PMC
>>> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer
>>> & Project Lead
>>> OPS4J Pax for Vaadin <http://team.ops4j.org/wiki/display/PAXVAADIN/Home>
>>> Commiter & Project Lead
>>> blog <http://notizblog.nierbeck.de/>
>>>
>>
>>
>
>
> --
>
> Apache Karaf <http://karaf.apache.org/> Committer & PMC
> OPS4J Pax Web <http://wiki.ops4j.org/display/paxweb/Pax+Web/> Committer &
> Project Lead
> OPS4J Pax for Vaadin <http://team.ops4j.org/wiki/display/PAXVAADIN/Home>
> Commiter & Project Lead
> blog <http://notizblog.nierbeck.de/>
>

Reply via email to