mvn jetty:run

View: New views
4 Messages — Rating Filter:   Alert me  

mvn jetty:run

by Fernando Padilla :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi. So I got terracotta to run nicely with stand-alone jetty and tomcat.
  But for development we use "mvn jetty:run".

Has anyone tried to get terracotta to run within the Maven Jetty Plugin?
  Has anyone tried to get terracotta to run within the Eclipse Jetty Plugin?

This would be wonderful!!

fernando
_______________________________________________
tc-users mailing list
tc-users@...
http://lists.terracotta.org/mailman/listinfo/tc-users

Re: mvn jetty:run

by Eugene Kuleshov-6 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Fernando,

  Generally enabling DSO support it is just a matter of adding few
system properties to the JVM process. From the documentation it seems
Jetty plugin for Maven runs the server in the same process with Maven.
So, you would have to set the following java commands options when
launching Maven, eg. using MAVEN_OPTS, or better making a copy of mvn
script and adding those options in there (make sure you have the up to
date boot jar in there). Note that options aren't -D flags for mvn command:

-Xbootclasspath/p:"C:\temp\terracotta-2.4\bin\..\lib\dso-boot\dso-boot-hotspot_win32_160_02.jar"
-Dtc.install-root="C:\temp\terracotta-2.4\bin\.."
-Dtc.config="tc-config.xml"

  Same options should also work with Eclipse plugin, as long as you can
set those system options on a JVM used to launch Jetty.

  Also, if you are using Maven, I would strongly recommend to take a
look at Maven plugin for Terracotta [1]. It provides few convenient
goals to geenerate boot jar, launch DSO server and Terracotta admin
console without installing the DSO kit.
  Terracotta Maven plugin also have integration with Cargo (see project
web site for documentation and exemples), that allows to run supported
application servers with DSO and run integration tests across multiple
DSO-enabled web servers. I've been using this stuff with Tomcat, so
single command like "mvn tc:run" would download all required jars,
download and install tomcat, build bootjar for the current JVM, start
DSO server and then multiple tomcat nodes with DSO enabled.
  In theory this should work with Jetty too, assuming that you have
Jetty Terracotta integration module (TIM) in your tc-config.xml [2]

  regards,
  Eugene

[1] http://forge.terracotta.org/projects/tc-maven-plugin/
[2] http://forge.terracotta.org/projects/tim-jetty-6.1.4/


Fernando Padilla wrote:

> Hi. So I got terracotta to run nicely with stand-alone jetty and tomcat.
>   But for development we use "mvn jetty:run".
>
> Has anyone tried to get terracotta to run within the Maven Jetty Plugin?
>   Has anyone tried to get terracotta to run within the Eclipse Jetty Plugin?
>
> This would be wonderful!!
>
> fernando
>  

_______________________________________________
tc-users mailing list
tc-users@...
http://lists.terracotta.org/mailman/listinfo/tc-users

Re: mvn jetty:run

by Fernando Padilla :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

So the problem is that the command line parameters passed to "mvn" are
not simply passed through to the JVM.

So it looks like you have to place all of the Terracotta parameters into
MAVEN_OPTS.  Then it just works :)


Eugene Kuleshov wrote:

> Fernando,
>
>   Generally enabling DSO support it is just a matter of adding few
> system properties to the JVM process. From the documentation it seems
> Jetty plugin for Maven runs the server in the same process with Maven.
> So, you would have to set the following java commands options when
> launching Maven, eg. using MAVEN_OPTS, or better making a copy of mvn
> script and adding those options in there (make sure you have the up to
> date boot jar in there). Note that options aren't -D flags for mvn command:
>
> -Xbootclasspath/p:"C:\temp\terracotta-2.4\bin\..\lib\dso-boot\dso-boot-hotspot_win32_160_02.jar"
> -Dtc.install-root="C:\temp\terracotta-2.4\bin\.."
> -Dtc.config="tc-config.xml"
>
>   Same options should also work with Eclipse plugin, as long as you can
> set those system options on a JVM used to launch Jetty.
>
>   Also, if you are using Maven, I would strongly recommend to take a
> look at Maven plugin for Terracotta [1]. It provides few convenient
> goals to geenerate boot jar, launch DSO server and Terracotta admin
> console without installing the DSO kit.
>   Terracotta Maven plugin also have integration with Cargo (see project
> web site for documentation and exemples), that allows to run supported
> application servers with DSO and run integration tests across multiple
> DSO-enabled web servers. I've been using this stuff with Tomcat, so
> single command like "mvn tc:run" would download all required jars,
> download and install tomcat, build bootjar for the current JVM, start
> DSO server and then multiple tomcat nodes with DSO enabled.
>   In theory this should work with Jetty too, assuming that you have
> Jetty Terracotta integration module (TIM) in your tc-config.xml [2]
>
>   regards,
>   Eugene
>
> [1] http://forge.terracotta.org/projects/tc-maven-plugin/
> [2] http://forge.terracotta.org/projects/tim-jetty-6.1.4/
>
>
> Fernando Padilla wrote:
>> Hi. So I got terracotta to run nicely with stand-alone jetty and tomcat.
>>   But for development we use "mvn jetty:run".
>>
>> Has anyone tried to get terracotta to run within the Maven Jetty Plugin?
>>   Has anyone tried to get terracotta to run within the Eclipse Jetty Plugin?
>>
>> This would be wonderful!!
>>
>> fernando
>>  
>
> _______________________________________________
> tc-users mailing list
> tc-users@...
> http://lists.terracotta.org/mailman/listinfo/tc-users
_______________________________________________
tc-users mailing list
tc-users@...
http://lists.terracotta.org/mailman/listinfo/tc-users

Re: mvn jetty:run

by Eugene Kuleshov-6 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi Fernando,

  Right. That is what I meant, you have to either edit mvn script or put
those settings into MAVEN_OPTS environment variable (e.g. using a
wrapper script).

  I also spent some time to verify that Jetty is working with Terracotta
plugin for Maven [1]. I've had to make some minor fixes in plugin and we
sorted some compatibility issues with Terracotta integration module
(TIM) for Jetty. Today's nightly build will have those fixes and you
could pick it up from the Terracotta Maven repository.

  Please take a look at sample projects [1] and check out integration
with Cargo [2].

  regards,
  Eugene

[1] http://forge.terracotta.org/projects/tc-maven-plugin/examples.html
[2] http://forge.terracotta.org/projects/tc-maven-plugin/cargo.html



Fernando Padilla wrote:

> So the problem is that the command line parameters passed to "mvn" are
> not simply passed through to the JVM.
>
> So it looks like you have to place all of the Terracotta parameters into
> MAVEN_OPTS.  Then it just works :)
>
>
> Eugene Kuleshov wrote:
>  
>> Fernando,
>>
>>   Generally enabling DSO support it is just a matter of adding few
>> system properties to the JVM process. From the documentation it seems
>> Jetty plugin for Maven runs the server in the same process with Maven.
>> So, you would have to set the following java commands options when
>> launching Maven, eg. using MAVEN_OPTS, or better making a copy of mvn
>> script and adding those options in there (make sure you have the up to
>> date boot jar in there). Note that options aren't -D flags for mvn command:
>>
>> -Xbootclasspath/p:"C:\temp\terracotta-2.4\bin\..\lib\dso-boot\dso-boot-hotspot_win32_160_02.jar"
>> -Dtc.install-root="C:\temp\terracotta-2.4\bin\.."
>> -Dtc.config="tc-config.xml"
>>
>>   Same options should also work with Eclipse plugin, as long as you can
>> set those system options on a JVM used to launch Jetty.
>>
>>   Also, if you are using Maven, I would strongly recommend to take a
>> look at Maven plugin for Terracotta [1]. It provides few convenient
>> goals to geenerate boot jar, launch DSO server and Terracotta admin
>> console without installing the DSO kit.
>>   Terracotta Maven plugin also have integration with Cargo (see project
>> web site for documentation and exemples), that allows to run supported
>> application servers with DSO and run integration tests across multiple
>> DSO-enabled web servers. I've been using this stuff with Tomcat, so
>> single command like "mvn tc:run" would download all required jars,
>> download and install tomcat, build bootjar for the current JVM, start
>> DSO server and then multiple tomcat nodes with DSO enabled.
>>   In theory this should work with Jetty too, assuming that you have
>> Jetty Terracotta integration module (TIM) in your tc-config.xml [2]
>>
>>   regards,
>>   Eugene
>>
>> [1] http://forge.terracotta.org/projects/tc-maven-plugin/
>> [2] http://forge.terracotta.org/projects/tim-jetty-6.1.4/
>>
>>
>> Fernando Padilla wrote:
>>    
>>> Hi. So I got terracotta to run nicely with stand-alone jetty and tomcat.
>>>   But for development we use "mvn jetty:run".
>>>
>>> Has anyone tried to get terracotta to run within the Maven Jetty Plugin?
>>>   Has anyone tried to get terracotta to run within the Eclipse Jetty Plugin?
>>>
>>> This would be wonderful!!
>>>
>>> fernando
>>>  
>>>      
>> _______________________________________________
>> tc-users mailing list
>> tc-users@...
>> http://lists.terracotta.org/mailman/listinfo/tc-users
>>    
> _______________________________________________
> tc-users mailing list
> tc-users@...
> http://lists.terracotta.org/mailman/listinfo/tc-users
>  

_______________________________________________
tc-users mailing list
tc-users@...
http://lists.terracotta.org/mailman/listinfo/tc-users
LightInTheBox - Buy quality products at wholesale price