views:

40

answers:

1

Hi guys,

I want to run "mvn tomcat:run" from the command line, but how can I edit the server.xml to set maxHttpHeaderSize="65536" in the connectors? Or can I configure the connectors in the pom.xml?

Cheers

Nik

+2  A: 

Unfortunately, after doing some research, I don't think there's a way to edit server.xml's connectors. mvn tomcat:run uses an embedded Tomcat.

Unless someone finds something, it seems like your best bet will be to move to the maven cargo plugin and ZIP up your own Tomcat installation with your custom server.xml.

<cargo containerId="tomcat7x" [...]>
  <zipUrlInstaller
      installUrl="file://tomcat-custom.zip",
      installDir="target/installs"/>
  [...]
</cargo>

Or something of the sort...

The Alchemist
It seems you're right, there is no way to do that at the moment other than rolling my own hack, such as through the cargo plugin.
niklassaers