[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] How to specify JVM args?

Check if m2e passes jvm arguments to maven process, you can see actual
jvm execution command line by right-clicking on the jvm on Debug view,
then selecting Properties.

I doubt it's m2e problem, however. Most likely maven tests are executed
in a separate jvm, so you need to configure these in surefire/failsafe
configuration.

Also, do you really need to run mvn test from m2e? This is not
recommended and I should probably remove this shortcut from Run menu. I
suggest you either run tests as regular junit tests or as mvn test from
command line, although the latter will likely have the same problem with
jvm arguments.

--
Regards,
Igor

On 2013-08-29 12:52 PM, Keith Barlow wrote:
As an addon... I'd prefer not to have to modify settings.xml or the pom
since that would mean global changes or project changes respectively.  I
am looking for quick and simple local configuration.


On Thu, Aug 29, 2013 at 12:50 PM, Keith Barlow <kbarlow@xxxxxxxxx <mailto:kbarlow@xxxxxxxxx>> wrote:

    I am asking about JVMs started from Eclipse, via the launch
    configurations.  When I do Run->Java Application,  I can pass proxy
    parameters to the JVM by specifying them in the Launch Configuration
    on the "Arguments" tab in the "VM arguments" box as follows:

    -Dhttp.proxyHost=localhost
    -Dhttp.proxyPort=8889
    -Dhttps.proxyHost=localhost
    -Dhttps.proxyPort=8889

    If I put this same information into the m2e Launch Configuration on
    the "JRE" tab in the VM arguments box, and run my unit tests
    (Run->Maven test), the executed unit tests are not proxied.

    Keith


On Thu, Aug 29, 2013 at 11:54 AM, Igor Fedorenko <igor@xxxxxxxxxxxxxx <mailto:igor@xxxxxxxxxxxxxx>> wrote:

        Are you asking about Eclipse JVM or JVM started from Eclipse, using
        Run->MavenBuild or Run->JavaApplication?

        For Eclipse JVM you need to modify eclipse.ini or use -vmargs
        command
        line parameter. For JVMs started from Eclipse, most/all launch
        configuration dialogs will have a way to specify jvm arguments.

        Also note that Maven (and m2e) uses http proxy configuration
        specified
        in settings.xml file and this is what I recommend using for Maven.

        --
        Regards,
        Igor


On 2013-08-29 11:43 AM, Keith Barlow wrote:

            Hiyas,

            Quick Question:  What is the correct way to pass parameters
            to the JVM
            via build configurations in Eclipse?  I am trying to specify
            JVM proxy
            parameters:

            -Dhttp.proxyHost=localhost
            -Dhttp.proxyPort=8889

            I tried specifying them on the JRE tab but they don't see to
            get applied.

            Thanks.

            Keith
            --
            Keith Barlow

            /Software Engineer/
            *Dell Boomi*


_________________________________________________ m2e-users mailing list m2e-users@xxxxxxxxxxx <mailto:m2e-users@xxxxxxxxxxx> https://dev.eclipse.org/__mailman/listinfo/m2e-users <https://dev.eclipse.org/mailman/listinfo/m2e-users>

        _________________________________________________
        m2e-users mailing list
        m2e-users@xxxxxxxxxxx <mailto:m2e-users@xxxxxxxxxxx>
        https://dev.eclipse.org/__mailman/listinfo/m2e-users
        <https://dev.eclipse.org/mailman/listinfo/m2e-users>




-- Keith Barlow

    /Software Engineer/
    *Dell Boomi*




-- Keith Barlow

/Software Engineer/
*Dell Boomi*


_______________________________________________ m2e-users mailing list m2e-users@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/m2e-users