You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Felix Meschberger (JIRA)" <ji...@apache.org> on 2009/11/27 10:22:39 UTC

[jira] Created: (JCR-2412) JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference

JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference
---------------------------------------------------------------------------------------

                 Key: JCR-2412
                 URL: https://issues.apache.org/jira/browse/JCR-2412
             Project: Jackrabbit Content Repository
          Issue Type: Bug
          Components: jackrabbit-core
    Affects Versions: 2.0-beta3
            Reporter: Felix Meschberger


The JackrabbitRepositoryStub added as part of JCR-2055 contains a reference to the org.apache.jackrabbit.test package.

This is IMHO a very bad dependency for a production library and should be removed.

(I stumbled upon it while trying to create an OSGi bundle for an embedded Jackrabbit Repository based on 2.0-beta3, so I can work around this. Nevertheless, it is IMHO bad practice and not a very good idea)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JCR-2412) JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference

Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JCR-2412?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783072#action_12783072 ] 

Felix Meschberger commented on JCR-2412:
----------------------------------------

When defining the bundle, I get an Import-Package statement for this package - as I said, I can work around this.

The problem is, that the JackrabbitRepositoryStub class uses three classes form the test package and from the POV of OSGi, this constitutes an required dependency to said package. Of course I can exclude the import of that package assuming this class will never be used in a production system.

But then: why including it in a production library in the first place ?

> JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference
> ---------------------------------------------------------------------------------------
>
>                 Key: JCR-2412
>                 URL: https://issues.apache.org/jira/browse/JCR-2412
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-core
>    Affects Versions: 2.0-beta3
>            Reporter: Felix Meschberger
>
> The JackrabbitRepositoryStub added as part of JCR-2055 contains a reference to the org.apache.jackrabbit.test package.
> This is IMHO a very bad dependency for a production library and should be removed.
> (I stumbled upon it while trying to create an OSGi bundle for an embedded Jackrabbit Repository based on 2.0-beta3, so I can work around this. Nevertheless, it is IMHO bad practice and not a very good idea)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JCR-2412) JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JCR-2412?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783068#action_12783068 ] 

Jukka Zitting commented on JCR-2412:
------------------------------------

As was discussed in JCR-2055, I don't see a problem with the optional dependency. What's the problem you see?


> JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference
> ---------------------------------------------------------------------------------------
>
>                 Key: JCR-2412
>                 URL: https://issues.apache.org/jira/browse/JCR-2412
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-core
>    Affects Versions: 2.0-beta3
>            Reporter: Felix Meschberger
>
> The JackrabbitRepositoryStub added as part of JCR-2055 contains a reference to the org.apache.jackrabbit.test package.
> This is IMHO a very bad dependency for a production library and should be removed.
> (I stumbled upon it while trying to create an OSGi bundle for an embedded Jackrabbit Repository based on 2.0-beta3, so I can work around this. Nevertheless, it is IMHO bad practice and not a very good idea)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (JCR-2412) JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference

Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-2412?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Felix Meschberger resolved JCR-2412.
------------------------------------

    Resolution: Won't Fix

I read the explanation. Still I think test dependencies have absolutely no place in a production library whatsoever and however optional the dependency may be.

But since I seem to be biting on granite and the workaround I did (which is actually preventing the import being generated for the package) does work I will close this issue.

> JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference
> ---------------------------------------------------------------------------------------
>
>                 Key: JCR-2412
>                 URL: https://issues.apache.org/jira/browse/JCR-2412
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-core
>    Affects Versions: 2.0-beta3
>            Reporter: Felix Meschberger
>
> The JackrabbitRepositoryStub added as part of JCR-2055 contains a reference to the org.apache.jackrabbit.test package.
> This is IMHO a very bad dependency for a production library and should be removed.
> (I stumbled upon it while trying to create an OSGi bundle for an embedded Jackrabbit Repository based on 2.0-beta3, so I can work around this. Nevertheless, it is IMHO bad practice and not a very good idea)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JCR-2412) JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JCR-2412?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12783078#action_12783078 ] 

Jukka Zitting commented on JCR-2412:
------------------------------------

Can't you use the resolution=optional setting for the dependency? Ideally I'd expect the bundle plugin to automatically add that to any dependencies that have been declared optional in the POM. 

The rationale for having the class in there is explained in JCR-2055.

> JackrabbitRepositoryStub in jackrabbit-core library class contains o.a.j.test reference
> ---------------------------------------------------------------------------------------
>
>                 Key: JCR-2412
>                 URL: https://issues.apache.org/jira/browse/JCR-2412
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-core
>    Affects Versions: 2.0-beta3
>            Reporter: Felix Meschberger
>
> The JackrabbitRepositoryStub added as part of JCR-2055 contains a reference to the org.apache.jackrabbit.test package.
> This is IMHO a very bad dependency for a production library and should be removed.
> (I stumbled upon it while trying to create an OSGi bundle for an embedded Jackrabbit Repository based on 2.0-beta3, so I can work around this. Nevertheless, it is IMHO bad practice and not a very good idea)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.