sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread James Wright


   Please could anyone interested have a look at the following changes 
to the sysutils/apache-mesos regarding enabling Java bindings in libmesos;


Phabricator
https://reviews.freebsd.org/D25361


  One specific area of concern is dealing with the Maven dependencies 
fetched mid-way through the build phase. I thought I had a solution 
utilizing
the maven dependency plugin "go-offline" goal in the fetch phase and 
providing a skeleton POM to describe the dependencies required. However, 
there
is a question mark over where these dependencies should be downloaded 
during the fetch phase;


${HOME}/.m2  -- Won't work because not writeable when building with 
poudriere.
${TMPDIR}/.m2 -- Might work (haven't tested if writeable suring poudrier 
build yet)?
${DISTDIR}/.m2  -- Artifacts downloaded would need to be checksummed and 
added to distfile (don't think we have a good way of doing that for 
large number of deps)?



For more info please refer to the comments in the afore mentioned 
Phabricator review.



Many Thanks,
James
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread Jonathan Chen
On Sat, 20 Jun 2020 at 07:14, James Wright
 wrote:
[..]
>One specific area of concern is dealing with the Maven dependencies
> fetched mid-way through the build phase. I thought I had a solution
> utilizing
> the maven dependency plugin "go-offline" goal in the fetch phase and
> providing a skeleton POM to describe the dependencies required. However,
> there
> is a question mark over where these dependencies should be downloaded
> during the fetch phase;

One possible way to do this is to provide an offline maven repository
that has all the required dependencies pre-fetched. The pre-warmed
repo is static, and can be retrieved and extracted during the
fetch-phase. Your maven build can then specify
"-Dmaven.repo.local=${WRKDIR}/local-repo".

The java/eclipse port uses this strategy.

Cheers.
--
Jonathan Chen 
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread James Wright



On 19/06/2020 22:37, Jonathan Chen wrote:

On Sat, 20 Jun 2020 at 07:14, James Wright
 wrote:
[..]

One specific area of concern is dealing with the Maven dependencies
fetched mid-way through the build phase. I thought I had a solution
utilizing
the maven dependency plugin "go-offline" goal in the fetch phase and
providing a skeleton POM to describe the dependencies required. However,
there
is a question mark over where these dependencies should be downloaded
during the fetch phase;

One possible way to do this is to provide an offline maven repository
that has all the required dependencies pre-fetched. The pre-warmed
repo is static, and can be retrieved and extracted during the
fetch-phase. Your maven build can then specify
"-Dmaven.repo.local=${WRKDIR}/local-repo".

The java/eclipse port uses this strategy.

Cheers.
--
Jonathan Chen 


I have seen that method used in some Java ports, but thought it would be 
better to
download the dependencies from the offical maven repo directly, rather 
than a
bundled tarball hosted on a personal/private repo which seems a less 
reliable source?



___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread Jonathan Chen
On Sat, 20 Jun 2020 at 10:01, James Wright
 wrote:
>
>
> On 19/06/2020 22:37, Jonathan Chen wrote:
> > On Sat, 20 Jun 2020 at 07:14, James Wright
> >  wrote:
> > [..]
> >> One specific area of concern is dealing with the Maven dependencies
> >> fetched mid-way through the build phase. I thought I had a solution
> >> utilizing
> >> the maven dependency plugin "go-offline" goal in the fetch phase and
> >> providing a skeleton POM to describe the dependencies required. However,
> >> there
> >> is a question mark over where these dependencies should be downloaded
> >> during the fetch phase;
> > One possible way to do this is to provide an offline maven repository
> > that has all the required dependencies pre-fetched. The pre-warmed
> > repo is static, and can be retrieved and extracted during the
> > fetch-phase. Your maven build can then specify
> > "-Dmaven.repo.local=${WRKDIR}/local-repo".
> >
> > The java/eclipse port uses this strategy.
> >
> > Cheers.
> > --
> > Jonathan Chen 
>
> I have seen that method used in some Java ports, but thought it would be
> better to
> download the dependencies from the offical maven repo directly, rather
> than a
> bundled tarball hosted on a personal/private repo which seems a less
> reliable source?

Doing so violates the ports-build requirement that access to the 'Net
is only permitted during the fetch-phase.
-- 
Jonathan Chen 
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread James Wright



On 20/06/2020 01:16, Jonathan Chen wrote:

On Sat, 20 Jun 2020 at 10:01, James Wright
 wrote:


On 19/06/2020 22:37, Jonathan Chen wrote:

On Sat, 20 Jun 2020 at 07:14, James Wright
 wrote:
[..]

 One specific area of concern is dealing with the Maven dependencies
fetched mid-way through the build phase. I thought I had a solution
utilizing
the maven dependency plugin "go-offline" goal in the fetch phase and
providing a skeleton POM to describe the dependencies required. However,
there
is a question mark over where these dependencies should be downloaded
during the fetch phase;

One possible way to do this is to provide an offline maven repository
that has all the required dependencies pre-fetched. The pre-warmed
repo is static, and can be retrieved and extracted during the
fetch-phase. Your maven build can then specify
"-Dmaven.repo.local=${WRKDIR}/local-repo".

The java/eclipse port uses this strategy.

Cheers.
--
Jonathan Chen 

I have seen that method used in some Java ports, but thought it would be
better to
download the dependencies from the offical maven repo directly, rather
than a
bundled tarball hosted on a personal/private repo which seems a less
reliable source?

Doing so violates the ports-build requirement that access to the 'Net
is only permitted during the fetch-phase.


Not in this case, all dependencies are downloaded during the fetch phase 
by invoking

maven dependency:go-offline goal to prefetch everything required into the
local repo before the build phase.


___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread Jonathan Chen
On Sat, 20 Jun 2020 at 12:39, James Wright
 wrote:
>
>
> On 20/06/2020 01:16, Jonathan Chen wrote:
> > On Sat, 20 Jun 2020 at 10:01, James Wright
> >  wrote:
> >>
> >> On 19/06/2020 22:37, Jonathan Chen wrote:
> >>> On Sat, 20 Jun 2020 at 07:14, James Wright
> >>>  wrote:
> >>> [..]
>   One specific area of concern is dealing with the Maven dependencies
>  fetched mid-way through the build phase. I thought I had a solution
>  utilizing
>  the maven dependency plugin "go-offline" goal in the fetch phase and
>  providing a skeleton POM to describe the dependencies required. However,
>  there
>  is a question mark over where these dependencies should be downloaded
>  during the fetch phase;
> >>> One possible way to do this is to provide an offline maven repository
> >>> that has all the required dependencies pre-fetched. The pre-warmed
> >>> repo is static, and can be retrieved and extracted during the
> >>> fetch-phase. Your maven build can then specify
> >>> "-Dmaven.repo.local=${WRKDIR}/local-repo".
> >>>
> >>> The java/eclipse port uses this strategy.
> >>>
> >>> Cheers.
> >>> --
> >>> Jonathan Chen 
> >> I have seen that method used in some Java ports, but thought it would be
> >> better to
> >> download the dependencies from the offical maven repo directly, rather
> >> than a
> >> bundled tarball hosted on a personal/private repo which seems a less
> >> reliable source?
> > Doing so violates the ports-build requirement that access to the 'Net
> > is only permitted during the fetch-phase.
>
> Not in this case, all dependencies are downloaded during the fetch phase
> by invoking
> maven dependency:go-offline goal to prefetch everything required into the
> local repo before the build phase.

Won't your distinfo file be amazingly large?
-- 
Jonathan Chen 
___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"


Re: sysutils/apache-mesos: Enable Java bindings request for review

2020-06-19 Thread James Wright




On 20/06/2020 02:03, Jonathan Chen wrote:

On Sat, 20 Jun 2020 at 12:39, James Wright
 wrote:


On 20/06/2020 01:16, Jonathan Chen wrote:

On Sat, 20 Jun 2020 at 10:01, James Wright
 wrote:

On 19/06/2020 22:37, Jonathan Chen wrote:

On Sat, 20 Jun 2020 at 07:14, James Wright
 wrote:
[..]

  One specific area of concern is dealing with the Maven dependencies
fetched mid-way through the build phase. I thought I had a solution
utilizing
the maven dependency plugin "go-offline" goal in the fetch phase and
providing a skeleton POM to describe the dependencies required. However,
there
is a question mark over where these dependencies should be downloaded
during the fetch phase;

One possible way to do this is to provide an offline maven repository
that has all the required dependencies pre-fetched. The pre-warmed
repo is static, and can be retrieved and extracted during the
fetch-phase. Your maven build can then specify
"-Dmaven.repo.local=${WRKDIR}/local-repo".

The java/eclipse port uses this strategy.

Cheers.
--
Jonathan Chen 

I have seen that method used in some Java ports, but thought it would be
better to
download the dependencies from the offical maven repo directly, rather
than a
bundled tarball hosted on a personal/private repo which seems a less
reliable source?

Doing so violates the ports-build requirement that access to the 'Net
is only permitted during the fetch-phase.

Not in this case, all dependencies are downloaded during the fetch phase
by invoking
maven dependency:go-offline goal to prefetch everything required into the
local repo before the build phase.

Won't your distinfo file be amazingly large?


yeah :-( Although I don't understand how Rust/Cargo ports manage this, 
can we

not have something similiar for Java/Maven ports?


___
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"