Yop perhaps.

But all the code of the Mojo is build to use these fields (tomeeHttpPort
for example).
I writed my code while trying to let all other things working.
Le 11 août 2015 16:17, "Romain Manni-Bucau" <[email protected]> a
écrit :

> if you pass system variable run should get them automatically, that said
> the gain for run is ver poor since you already have the http port maven
> property to switch it.
>
>
> Romain Manni-Bucau
> @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> <http://rmannibucau.wordpress.com> | Github <
> https://github.com/rmannibucau> |
> LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
> <http://www.tomitribe.com>
>
> 2015-08-11 7:13 GMT-07:00 Yann Blazart <[email protected]>:
>
> > Yep, but with tomee:run ?
> >
> > I think this code was here for this goal, typically to get back the
> > communications ports in the Mojo.
> > For example, in  AbstractCommandMojo, and run goal in AbstractTomEEMojo.
> >
> > My patch is working in theses cases.
> > Le 11 août 2015 16:09, "Romain Manni-Bucau" <[email protected]> a
> > écrit :
> >
> > > Think we will just use strings for ports, using placeholders is not
> > needed
> > > at build time since you can already force the ports on mvn command
> line.
> > > But using placeholder filled at run time does :).
> > >
> > >
> > > Romain Manni-Bucau
> > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > <http://rmannibucau.wordpress.com> | Github <
> > > https://github.com/rmannibucau> |
> > > LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
> > > <http://www.tomitribe.com>
> > >
> > > 2015-08-11 6:51 GMT-07:00 Yann Blazart <[email protected]>:
> > >
> > > > Check my patch :  TOMEE-1626.
> > > >
> > > > With it, it will be cool with tomee:run for dev and tomee:exec for
> > > > delivering.
> > > > Le 11 août 2015 15:49, "Romain Manni-Bucau" <[email protected]>
> a
> > > > écrit :
> > > >
> > > > > Ah yeah, ports should be strings.
> > > > > Le 11 août 2015 06:37, "Yann Blazart" <[email protected]> a
> > > écrit :
> > > > >
> > > > > > well romain,  I think I wasn't enought clear about what I did
> mean.
> > > > > >
> > > > > > Ok, the problem come from AbstractTomEEMojo,  in the
> > > > > > alignConfigOnServerXmlCurrentConfig.
> > > > > >
> > > > > > The goal of this method, call in exec(), is to get values from
> the
> > > > > > generated server.xml to get it back in fields of the mojo. I
> think
> > > this
> > > > > is
> > > > > > certainly for RunMojo, but the Integer.parseInt of ${http.port}
> of
> > > > course
> > > > > > failed ! :)
> > > > > >
> > > > > > Well, I worked on it, I'm about to post a patch on ASF JIRA, I
> you
> > > > would
> > > > > > like to check it as soon as possible ;)
> > > > > > No but used only in java mode. In script - catalina.sh|bat you
> can
> > > ude
> > > > > env
> > > > > > var CATALINA_OPTS or setenv.sh|bat
> > > > > > Le 11 août 2015 00:53, "Yann Blazart" <[email protected]> a
> > > > écrit :
> > > > > >
> > > > > > > hmmm.  this option seems to have disapperead in tomee 7
> > > > > > > Le 10 août 2015 19:21, "Romain Manni-Bucau" <
> > [email protected]
> > > >
> > > > a
> > > > > > > écrit :
> > > > > > >
> > > > > > > > use keepServerXmlAsthis I think during build phase
> > > > > > > >
> > > > > > > >
> > > > > > > > Romain Manni-Bucau
> > > > > > > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > > > > > > <http://rmannibucau.wordpress.com> | Github <
> > > > > > > > https://github.com/rmannibucau> |
> > > > > > > > LinkedIn <https://www.linkedin.com/in/rmannibucau> |
> > Tomitriber
> > > > > > > > <http://www.tomitribe.com>
> > > > > > > >
> > > > > > > > 2015-08-10 10:19 GMT-07:00 Yann Blazart <
> > [email protected]
> > > >:
> > > > > > > >
> > > > > > > > > it does'nt work.  it's before.  i can't provide server.xml
> > with
> > > > > vars.
> > > > > > > > > tomee:exec fail.
> > > > > > > > > Le 10 août 2015 19:11, "Romain Manni-Bucau" <
> > > > [email protected]
> > > > > >
> > > > > > a
> > > > > > > > > écrit :
> > > > > > > > >
> > > > > > > > > > Hi Yann,
> > > > > > > > > >
> > > > > > > > > > you should be able to use
> > > > > > > > "-DadditionalSystemProperties=-Dhttp.port=1080
> > > > > > > > > > -Dhttps.port=1443"
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > Romain Manni-Bucau
> > > > > > > > > > @rmannibucau <https://twitter.com/rmannibucau> |  Blog
> > > > > > > > > > <http://rmannibucau.wordpress.com> | Github <
> > > > > > > > > > https://github.com/rmannibucau> |
> > > > > > > > > > LinkedIn <https://www.linkedin.com/in/rmannibucau> |
> > > > Tomitriber
> > > > > > > > > > <http://www.tomitribe.com>
> > > > > > > > > >
> > > > > > > > > > 2015-08-10 10:08 GMT-07:00 Yann Blazart <
> > > > [email protected]
> > > > > >:
> > > > > > > > > >
> > > > > > > > > > > Hello, currently I'm trying to make packing to deliver
> > > TomEE
> > > > > and
> > > > > > > Apps
> > > > > > > > > in
> > > > > > > > > > > production as One Jar to run with tomee:exec.
> > > > > > > > > > > The only way I found to permit to the production team
> to
> > > > > > configure
> > > > > > > > > > > resources is to make them write a tomee.xml and provide
> > its
> > > > > path
> > > > > > by
> > > > > > > > > using
> > > > > > > > > > > the
> -DadditionalSystemProperties=-Dopenejb.conf.file=...
> > > > > > > > > > >
> > > > > > > > > > > Well done, but to configure the http listening port, I
> > > > > followed a
> > > > > > > > blog
> > > > > > > > > > post
> > > > > > > > > > > from Romain.
> > > > > > > > > > >
> > > > > > > > > > > in the blog article 50 shades of tomee, Romain has
> > written
> > > > that
> > > > > > we
> > > > > > > > > could
> > > > > > > > > > > use tomee:exec to generate the big jar and pass some
> vars
> > > to
> > > > > the
> > > > > > > next
> > > > > > > > > > java
> > > > > > > > > > > command, to launch tomee, to override some values. In
> his
> > > > > example
> > > > > > > he
> > > > > > > > > say
> > > > > > > > > > > that he can override the http.port in server.xml.
> Great !
> > > > > > > > > > >
> > > > > > > > > > > But in fact, while I'm providing a server.xml with the
> > > > > > ${http.port}
> > > > > > > > in
> > > > > > > > > > the
> > > > > > > > > > > connector for the tomcat, the tomee:exec fail because
> of
> > an
> > > > > > > > > > > NumberFormatException.
> > > > > > > > > > >
> > > > > > > > > > > The plugin tomee try to get the value from  the
> provided
> > > > > > > server.xml,
> > > > > > > > > with
> > > > > > > > > > > pain of course in this case.
> > > > > > > > > > >
> > > > > > > > > > > Is it possible to fix it ? I can't clearly see the
> > impacts
> > > on
> > > > > the
> > > > > > > > other
> > > > > > > > > > > goals of the mojo if I change the code.
> > > > > > > > > > >
> > > > > > > > > > > Does anybody have an idea ?
> > > > > > > > > > >
> > > > > > > > > > > Thanks a lot.
> > > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>

Reply via email to