[ 
https://issues.apache.org/jira/browse/SLING-3512?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13979490#comment-13979490
 ] 

Konrad Windszus commented on SLING-3512:
----------------------------------------

In Eclipse the TEI cannot be instanciated if the referenced classes are not in 
the Maven classpath. The according warning message is not very descriptive 
though: "The TagExtraInfo class for "sling:defineObjects" 
(org.apache.sling.scripting.jsp.taglib.DefineObjectsTEI) 
 could not be instantiated". It is hard to derive from that message, which 
class is missing from the classpath. In my regard all necessary classes should 
be loaded by Maven (even the transitive ones). It is very cumbersome to add 
dependencies manually to the project, just for the IDE to be able to 
instanciate the TEI class.

> All dependencies referenced from TEI classes should have "compile" scope
> ------------------------------------------------------------------------
>
>                 Key: SLING-3512
>                 URL: https://issues.apache.org/jira/browse/SLING-3512
>             Project: Sling
>          Issue Type: Bug
>          Components: Scripting
>    Affects Versions: Scripting JSP-Taglib 2.2.0
>            Reporter: Konrad Windszus
>
> Currently some classes which are referenced from TEI classes (e.g. 
> DefineObjectsTEI) cannot be resolved within an IDE, because the according 
> dependency is given with scope "provided". Since provided dependencies are 
> not evaluated if given in a transitive way [0], the classpath of the 
> referencing JSP does not necessarily contain those transitive dependencies, 
> but they are necessary for the TEI to be instanciated within the IDE.
> For example the DefineObjectsTEI references classes from org.apache.sling.api 
> and slf4j-api. Therefore both dependencies should have the "compile" scope.
> [0] - 
> http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html#Dependency_Scope



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to