You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)" <jp...@cisco.com> on 2007/02/27 02:55:53 UTC

system scope dependency

 
I read somewhere, system scoped dependencies are not recommended.
 
Do you have any point or details on that.
 
Thanks
 
 

Re: system scope dependency

Posted by Wayne Fay <wa...@gmail.com>.
I've seen people use it to include the JDK tools.jar as a dependency
but that's it. Many of us would probably argue that's one of the
"only" proper uses of system scope, though lots of people will abuse
it as they are comfortable with their Ant builds and their /lib
directories. and don't want to move to Maven's repo etc.

I've personally never needed to use system scope thus far so other
than tools.jar, I can't tell you any valid cases.

Wayne

On 2/27/07, Thierry Lach <th...@gmail.com> wrote:
> OK then what would be the purpose for using a system scoped dependency?
>
> On 2/27/07, Wayne Fay <wa...@gmail.com> wrote:
> >
> > System scoped dependencies are not handled as you might expect by
> > various packaging plugins ie EAR, WAR etc. They are not bundled into
> > the package like other dependency Jars -and- they are not mentioned in
> > the Manifest file. So you can easily build a "broken" distribution of
> > your compiled code/project rather easily with system scoped artifacts.
> >
> > For these reasons and others, you are strongly encouraged to avoid
> > system scoped dependencies.
> >
> > Wayne
> >
> > On 2/26/07, jiangshachina <ji...@gmail.com> wrote:
> > >
> > > Hi,
> > > > What if the artifact doesn't have to be shared with others.
> > > > Is it ok to use system scope
> > > If you work a project with other mates,
> > > I think it's necessary to share your artifacts with your mates.
> > > Then your team may need a remote repository.
> > >
> > > If you just do something by yourself, I think repository still is
> > necessary.
> > > Because the repository can be used by you in later projects.
> > >
> > > I think a great advantage of Maven(repository) is that we don't care any
> > > path of jars(artifaces).
> > > Because they are in repository, Maven can find them automatically.
> > > If you use system scope, you have to use absolute path.
> > > Then the pom file must be modified, when you move the artifacts.
> > >
> > > Of course, now that Maven provides the scope, maybe there are some
> > reasons.
> > > Then we may use it at some "special" cases.
> > >
> > > a cup of Java, cheers!
> > > Sha Jiang
> > >
> > >
> > > Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
> > > wrote:
> > > >
> > > >
> > > > What if the artifact doesn't have to be shared with others.
> > > > Is it ok to use system scope
> > > >
> > > > Is there any advantage in copying to repository than storing it in
> > > > clearcase and use system scope
> > > >
> > > > Thanks
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: jiangshachina [mailto:jiangshachina@gmail.com]
> > > > Sent: Monday, February 26, 2007 6:11 PM
> > > > To: users@maven.apache.org
> > > > Subject: Re: [m2] system scope dependency
> > > >
> > > >
> > > > Hello,
> > > > All of artifacts would be in repository(local or remote).
> > > > That's the standard way on manipulating jars(or other artifacts) by
> > > > Maven.
> > > > Deploying artifacts to remote repository, then they could be shared by
> > > > more guys.
> > > >
> > > > a cup of Java, cheers!
> > > > Sha Jiang
> > > >
> > > >
> > > > Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at
> > Cisco)
> > > > wrote:
> > > >>
> > > >>
> > > >> I read somewhere, system scoped dependencies are not recommended.
> > > >>
> > > >> Do you have any point or details on that.
> > > >>
> > > >> Thanks
> > > >>
> > > >>
> > > >>
> > > >>
> > > >
> > > > --
> > > > View this message in context:
> > > >
> > http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a917381
> > > > 6
> > > > Sent from the Maven - Users mailing list archive at Nabble.com.
> > > >
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > > For additional commands, e-mail: users-help@maven.apache.org
> > > >
> > > > ---------------------------------------------------------------------
> > > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > > For additional commands, e-mail: users-help@maven.apache.org
> > > >
> > > >
> > > >
> > >
> > > --
> > > View this message in context:
> > http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a9174250
> > > Sent from the Maven - Users mailing list archive at Nabble.com.
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > For additional commands, e-mail: users-help@maven.apache.org
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: system scope dependency

Posted by Thierry Lach <th...@gmail.com>.
OK then what would be the purpose for using a system scoped dependency?

On 2/27/07, Wayne Fay <wa...@gmail.com> wrote:
>
> System scoped dependencies are not handled as you might expect by
> various packaging plugins ie EAR, WAR etc. They are not bundled into
> the package like other dependency Jars -and- they are not mentioned in
> the Manifest file. So you can easily build a "broken" distribution of
> your compiled code/project rather easily with system scoped artifacts.
>
> For these reasons and others, you are strongly encouraged to avoid
> system scoped dependencies.
>
> Wayne
>
> On 2/26/07, jiangshachina <ji...@gmail.com> wrote:
> >
> > Hi,
> > > What if the artifact doesn't have to be shared with others.
> > > Is it ok to use system scope
> > If you work a project with other mates,
> > I think it's necessary to share your artifacts with your mates.
> > Then your team may need a remote repository.
> >
> > If you just do something by yourself, I think repository still is
> necessary.
> > Because the repository can be used by you in later projects.
> >
> > I think a great advantage of Maven(repository) is that we don't care any
> > path of jars(artifaces).
> > Because they are in repository, Maven can find them automatically.
> > If you use system scope, you have to use absolute path.
> > Then the pom file must be modified, when you move the artifacts.
> >
> > Of course, now that Maven provides the scope, maybe there are some
> reasons.
> > Then we may use it at some "special" cases.
> >
> > a cup of Java, cheers!
> > Sha Jiang
> >
> >
> > Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
> > wrote:
> > >
> > >
> > > What if the artifact doesn't have to be shared with others.
> > > Is it ok to use system scope
> > >
> > > Is there any advantage in copying to repository than storing it in
> > > clearcase and use system scope
> > >
> > > Thanks
> > >
> > >
> > > -----Original Message-----
> > > From: jiangshachina [mailto:jiangshachina@gmail.com]
> > > Sent: Monday, February 26, 2007 6:11 PM
> > > To: users@maven.apache.org
> > > Subject: Re: [m2] system scope dependency
> > >
> > >
> > > Hello,
> > > All of artifacts would be in repository(local or remote).
> > > That's the standard way on manipulating jars(or other artifacts) by
> > > Maven.
> > > Deploying artifacts to remote repository, then they could be shared by
> > > more guys.
> > >
> > > a cup of Java, cheers!
> > > Sha Jiang
> > >
> > >
> > > Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at
> Cisco)
> > > wrote:
> > >>
> > >>
> > >> I read somewhere, system scoped dependencies are not recommended.
> > >>
> > >> Do you have any point or details on that.
> > >>
> > >> Thanks
> > >>
> > >>
> > >>
> > >>
> > >
> > > --
> > > View this message in context:
> > >
> http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a917381
> > > 6
> > > Sent from the Maven - Users mailing list archive at Nabble.com.
> > >
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > For additional commands, e-mail: users-help@maven.apache.org
> > >
> > > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > > For additional commands, e-mail: users-help@maven.apache.org
> > >
> > >
> > >
> >
> > --
> > View this message in context:
> http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a9174250
> > Sent from the Maven - Users mailing list archive at Nabble.com.
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: system scope dependency

Posted by Wayne Fay <wa...@gmail.com>.
System scoped dependencies are not handled as you might expect by
various packaging plugins ie EAR, WAR etc. They are not bundled into
the package like other dependency Jars -and- they are not mentioned in
the Manifest file. So you can easily build a "broken" distribution of
your compiled code/project rather easily with system scoped artifacts.

For these reasons and others, you are strongly encouraged to avoid
system scoped dependencies.

Wayne

On 2/26/07, jiangshachina <ji...@gmail.com> wrote:
>
> Hi,
> > What if the artifact doesn't have to be shared with others.
> > Is it ok to use system scope
> If you work a project with other mates,
> I think it's necessary to share your artifacts with your mates.
> Then your team may need a remote repository.
>
> If you just do something by yourself, I think repository still is necessary.
> Because the repository can be used by you in later projects.
>
> I think a great advantage of Maven(repository) is that we don't care any
> path of jars(artifaces).
> Because they are in repository, Maven can find them automatically.
> If you use system scope, you have to use absolute path.
> Then the pom file must be modified, when you move the artifacts.
>
> Of course, now that Maven provides the scope, maybe there are some reasons.
> Then we may use it at some "special" cases.
>
> a cup of Java, cheers!
> Sha Jiang
>
>
> Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
> wrote:
> >
> >
> > What if the artifact doesn't have to be shared with others.
> > Is it ok to use system scope
> >
> > Is there any advantage in copying to repository than storing it in
> > clearcase and use system scope
> >
> > Thanks
> >
> >
> > -----Original Message-----
> > From: jiangshachina [mailto:jiangshachina@gmail.com]
> > Sent: Monday, February 26, 2007 6:11 PM
> > To: users@maven.apache.org
> > Subject: Re: [m2] system scope dependency
> >
> >
> > Hello,
> > All of artifacts would be in repository(local or remote).
> > That's the standard way on manipulating jars(or other artifacts) by
> > Maven.
> > Deploying artifacts to remote repository, then they could be shared by
> > more guys.
> >
> > a cup of Java, cheers!
> > Sha Jiang
> >
> >
> > Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
> > wrote:
> >>
> >>
> >> I read somewhere, system scoped dependencies are not recommended.
> >>
> >> Do you have any point or details on that.
> >>
> >> Thanks
> >>
> >>
> >>
> >>
> >
> > --
> > View this message in context:
> > http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a917381
> > 6
> > Sent from the Maven - Users mailing list archive at Nabble.com.
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
> >
>
> --
> View this message in context: http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a9174250
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: system scope dependency

Posted by jiangshachina <ji...@gmail.com>.
Hi,
> What if the artifact doesn't have to be shared with others.
> Is it ok to use system scope
If you work a project with other mates,
I think it's necessary to share your artifacts with your mates.
Then your team may need a remote repository.

If you just do something by yourself, I think repository still is necessary.
Because the repository can be used by you in later projects.

I think a great advantage of Maven(repository) is that we don't care any
path of jars(artifaces).
Because they are in repository, Maven can find them automatically.
If you use system scope, you have to use absolute path.
Then the pom file must be modified, when you move the artifacts.

Of course, now that Maven provides the scope, maybe there are some reasons.
Then we may use it at some "special" cases.

a cup of Java, cheers!
Sha Jiang


Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
wrote:
> 
> 
> What if the artifact doesn't have to be shared with others.
> Is it ok to use system scope
> 
> Is there any advantage in copying to repository than storing it in
> clearcase and use system scope
> 
> Thanks
>  
> 
> -----Original Message-----
> From: jiangshachina [mailto:jiangshachina@gmail.com] 
> Sent: Monday, February 26, 2007 6:11 PM
> To: users@maven.apache.org
> Subject: Re: [m2] system scope dependency
> 
> 
> Hello,
> All of artifacts would be in repository(local or remote).
> That's the standard way on manipulating jars(or other artifacts) by
> Maven.
> Deploying artifacts to remote repository, then they could be shared by
> more guys.
> 
> a cup of Java, cheers!
> Sha Jiang
> 
> 
> Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
> wrote:
>> 
>>  
>> I read somewhere, system scoped dependencies are not recommended.
>>  
>> Do you have any point or details on that.
>>  
>> Thanks
>>  
>>  
>> 
>> 
> 
> --
> View this message in context:
> http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a917381
> 6
> Sent from the Maven - Users mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a9174250
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


RE: [m2] system scope dependency

Posted by "Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)" <jp...@cisco.com>.
What if the artifact doesn't have to be shared with others.
Is it ok to use system scope

Is there any advantage in copying to repository than storing it in
clearcase and use system scope

Thanks
 

-----Original Message-----
From: jiangshachina [mailto:jiangshachina@gmail.com] 
Sent: Monday, February 26, 2007 6:11 PM
To: users@maven.apache.org
Subject: Re: [m2] system scope dependency


Hello,
All of artifacts would be in repository(local or remote).
That's the standard way on manipulating jars(or other artifacts) by
Maven.
Deploying artifacts to remote repository, then they could be shared by
more guys.

a cup of Java, cheers!
Sha Jiang


Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
wrote:
> 
>  
> I read somewhere, system scoped dependencies are not recommended.
>  
> Do you have any point or details on that.
>  
> Thanks
>  
>  
> 
> 

--
View this message in context:
http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a917381
6
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: [m2] system scope dependency

Posted by jiangshachina <ji...@gmail.com>.
Hello,
All of artifacts would be in repository(local or remote).
That's the standard way on manipulating jars(or other artifacts) by Maven.
Deploying artifacts to remote repository, then they could be shared by more
guys.

a cup of Java, cheers!
Sha Jiang


Jagan Padmanabha Pillai -X (jpadmana - Insight Solutions, Inc. at Cisco)
wrote:
> 
>  
> I read somewhere, system scoped dependencies are not recommended.
>  
> Do you have any point or details on that.
>  
> Thanks
>  
>  
> 
> 

-- 
View this message in context: http://www.nabble.com/system-scope-dependency-tf3297614s177.html#a9173816
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org