You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Jan Høydahl (JIRA)" <ji...@apache.org> on 2011/05/03 13:35:03 UTC

[jira] [Created] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Do not include slf4j-jdk14 jar in WAR
-------------------------------------

                 Key: SOLR-2487
                 URL: https://issues.apache.org/jira/browse/SOLR-2487
             Project: Solr
          Issue Type: Improvement
          Components: Build
    Affects Versions: 3.2, 4.0
            Reporter: Jan Høydahl


I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.

It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Robert Muir (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052649#comment-13052649 ] 

Robert Muir commented on SOLR-2487:
-----------------------------------

Hoss, ok, I just was trying to figure out the expectations for testing.

Testing with a different classpath or whatever is more difficult than the other 'non-default' or 'conditional default' parameters that we randomize in Lucene to solve this issue (e.g. codecs, directories, locales, mergepolicies, ...), thats why I mentioned it.


> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (Commented JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13126246#comment-13126246 ] 

Jan Høydahl commented on SOLR-2487:
-----------------------------------

Yep, something like dist-war-no-logging would be fine.
And perhaps a build property "include.in.war" so people can package log4j if they wish by {{-Dinclude.in.war=log4j-1.2.16.jar,jcl-over-slf4j.jar}}

Feel free to give it a shot, I'll likely not get back to this issue before after Barcelona
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Updated] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (Updated JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jan Høydahl updated SOLR-2487:
------------------------------

    Fix Version/s: 4.0
                   3.6
         Assignee: Jan Høydahl

Planning to commit this in not too long
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13031364#comment-13031364 ] 

Hoss Man commented on SOLR-2487:
--------------------------------

bq. The novice users you're talking about are not likely to ever move past running Solr from the included Jetty in the example folder (I've seen such people). When you get to deploying to another servlet container, then you already know what a Java servlet container is. You also know about Java logging, setting Java Opts, and most importantly you read the install docs and understand how to copy a jar file into a folder.

just because there are people who never move past "java -jar start.jar" doesn't mean all novice users stick with "java -jar start.jar" forever -- Use of solr beyond "java -jar start.jar" does not mean people are experts in java/jars/wars/logging -- there is a middle ground between "i know nothing about java" and "i know enough to make a concious choice about an SLF4J implementation" and we shouldn't screw those people over and make their life more difficult.

we routinely get questions from users on the list about how to use solr in tomcat, or jetty (installed standalone), etc....  Either because they are dealing with a hosting provider (or IT department) that runs the servlet container for them, or because they want to use the servlet container installation provided by their OS distribution.

bq. SLF4j is now so common that the issue of having multiple crashing SLF4j bindings in your classpath will be more annoying to novice users than the opposite.

I have seen far more questions on the solr-user list about getting solr up and running in alternate servlet container then i have about dealing with SLF4j bindings.  


bq. From version 1.6 SLF4j will default to NOP binding if no binding is found

That, with out a doubt, would be the absolute worst possible situation i can imagine.  Under your proposal (in which no SLF4J imple would be provided in the war we ship) new users, with no solr/java experience, who are most in need of good log/debug messages telling them whats going on and what problems they might be having when they deploy solr, would get absolutely no log messages of any kind when deploying solr.war "as is" into a servlet container.

No, fucking, way.

* basic functionality (using solr) should be basic
* advanced functionality (customizing your logging impl) should be advanced

JDK Logging, whatever anyone may think about it from a feature standpoint, is 100% ubiquitious.  Every servlet container on the planet must provide some mechanism of dealing with JDK Logging, because the Java Spec requires it.  For that reason alone, regardless of how crapy anyone may think it is, it should be the default.


I'm not opposed to making life easier for people who want to use an alternate impl (if re-waring is deemed too muhc of a burden) -- but we should not screw over the majority of novice users (who already have a lot of differnet things to learn about) to make life a little easier for advanced users who care about their logging impl and can easily see what to do to change it.


Here are my counter proposals:

1) we parameterize the build, such that there is a "solr.slf4j.impl.path" property (that defaults to "./lib/slf4j-jdk14-1.6.1.jar") which is used by the "dist-war" target when building the war file.  People who build from src (and I think it's totally reasonable to assume anyone who cares about the SLF4J impl is likely already building form source, or could start doing so easily) can set that property to whatever impl they want included in the war, or set it to blank to not include anything (so they can have their servlet container load it at the system level)

2) ship two versions of the jar: one as it is today with the slf4j-jdk14-1.6.1.jar in place, and other "solr-minimal.war" that containly only the web.xml, JSPs, html, and images -- but no jars or other class files.  Advanced users that want total control over the jars used (but don't wnat to roll their own war file) can use this minimial war file in a servlet container where they have explicitly loaded the jars of their choosing (as you're suggesting people do with the slf4j binding of their choice)


I would vote for #1 ... but if people really feel that asking people to build there own war file to customize the slf4j binding jar is a burden on advanced users, then i don't see why SLF4J should be special -- we should go with option #2 to let every jar be customizable in this way.

(Option #2 may also be preferable to some distro repackagers (like debian, redhat) that want to be able to have a single copy of every jar on the system (instead of being baked into the war)


> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036819#comment-13036819 ] 

Jan Høydahl commented on SOLR-2487:
-----------------------------------

@Hoss, I like your option #1 with an ant option; no need to increase the size of the distro.

That would also solve the need for those that want no binding or another binding.

In addition, it is perfectly possible to write a new ANT target which creates a new dist/apache-solr-3.1.0-no-slf4j-bindings.war based on the default dist/apache-solr-3.1.0.war. This can then also be run from the binary distribution!

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036812#comment-13036812 ] 

Jan Høydahl commented on SOLR-2487:
-----------------------------------

Poll results from solr-user:
{code}
[3]  I always use the JDK logging as bundled in solr.war, that's perfect
[6]  I sometimes use log4j or another framework and am happy with re-packaging solr.war
[5]  Give me solr.war WITHOUT an slf4j logger binding, so I can choose at deploy time
[4]  Let me choose whether to bundle a binding or not at build time, using an ANT option
[1]  What's wrong with the "solr/example" Jetty? I never run Solr elsewhere!
[ ]  What? Solr can do logging? How cool!

[1]  Please, better logging documentation!
{code}

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13266919#comment-13266919 ] 

Jan Høydahl commented on SOLR-2487:
-----------------------------------

Neil, I don't think we as a project will upload multiple war's to Maven. You'll have to build your own using ant dist-war-excl-slf4j. Perhaps if you have a local repo such as Artifactory you can put a copy there, or upload it to some other repo that you can access.
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Resolved] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (Resolved JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jan Høydahl resolved SOLR-2487.
-------------------------------

    Resolution: Fixed

Fixed in 3.x and trunk
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Hoss Man (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13163224#comment-13163224 ] 

Hoss Man commented on SOLR-2487:
--------------------------------

Jan: +1
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "David Smiley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13028243#comment-13028243 ] 

David Smiley commented on SOLR-2487:
------------------------------------

I like it Jan!  JDK14 logging sucks, any way.

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Robert Muir (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052456#comment-13052456 ] 

Robert Muir commented on SOLR-2487:
-----------------------------------

Without knowing anything about logging, I just want to say its a bit scary
to parameterize the build in any way:
* how are the different possibilities going to be tested?
* are all possibilities supported, or is only the default/tested parameter the one we officially support?


> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Issue Comment Edited] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Greg Pendlebury (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13084967#comment-13084967 ] 

Greg Pendlebury edited comment on SOLR-2487 at 8/15/11 5:22 AM:
----------------------------------------------------------------

"At the moment there is no way in Maven to have it exclude the jdk14 JAR"... Hmm, I shouldn't have stated an absolute like that. I eventually got a script building today that dropped the WAR as a dependency, unpacked it to a '/solr' context folder, then nuked the jdk14 JAR only, leaving the rest in place.

I'd still prefer a skinny WAR, since it would be a much cleaner build script, and allow me to eliminate duplicate/conflicting JARs on the classpath with greater ease. It would also be more in line with the spirit of how Maven is intended to work... but I have a workaround, and don't expect the world to conform to my wishes :)

      was (Author: greg.pendlebury):
    "At the moment there is no way in Maven to have it exclude the jdk14 JAR"... Hmm, I shouldn't have stated an absolute like that. I eventually got a script building today that dropped the WAR as a dependency, unpacked it to a '/solr' context folder, then nuked the jdk14 JAR only, leaving the rest in place.

I'd still prefer a skinny WAR, since it would be a much cleaner build script, and allow me to eliminate duplicate JARs on the classpath with greater ease. It would also be more in line with the spirit of how Maven is intended to work... but I have a workaround, and don't expect to world to conform to my wishes :)
  
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Neil Hooey (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13267037#comment-13267037 ] 

Neil Hooey commented on SOLR-2487:
----------------------------------

If you're using Maven to build a Solr project, you can add these lines to the {{<plugins>}} section to eliminate slf4j bindings that come from Solr dependencies:

{code}
<plugin>
  <artifactId>maven-war-plugin</artifactId>
  <version>2.2</version>
  <configuration>
    <packagingExcludes>WEB-INF/lib/slf4j-jdk14-1.6.4.jar</packagingExcludes>
  </configuration>
</plugin>
{code}

If you have the setting {{<packaging>war</packaging>}}, Maven will strip the slf4j jar from the built war in {{target/}} and should clear the way for your logback or other loggers to function properly.
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Lance Norskog (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13266848#comment-13266848 ] 

Lance Norskog commented on SOLR-2487:
-------------------------------------

What if instead the distribution included an ant file for these various changes people want to make?
* Change the logger
* Change logger properties
* Remove esoteric contribs
* change web.xml file
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "David Smiley (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13126870#comment-13126870 ] 

David Smiley commented on SOLR-2487:
------------------------------------

Hoss: right; the user could simply expand the .war themselves and then customize. I think most webapp deployments would want some sort of customization, the most common of which is logging but there are others. Perhaps a different build.xml option might deploy an expanded WAR to the example jetty webapps dir--just an idea.  I admit my first comment on this issue was "I like it Jan!" but there are so many things a user might do to customize the app that I'm not sure if it's worthwhile to add build.xml targets for these things when there is no telling what the user will need to customize. We can just make it easy for them to get going on that customization and the first step is having an exploded deployment so they need not expand a war file.  But that's not a big deal.
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Updated] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (Updated JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jan Høydahl updated SOLR-2487:
------------------------------

    Attachment: SOLR-2487.patch

This patch attempts a solution which hopefully solves all needs. It adds a new ant target "dist-war-minimal" which creates a minimal Solr WAR Distribution file, without slf4j jars, except for the slf4j-api itself.

The target is not included in the "dist" task, so the minimal war will not be packaged redundantly. However, being an explicit target it is more easily understood and discoverable than a build parameter. Users packaging the war using this target must supply the relevant slf4j jars elsewhere on their classpath.

This minimal war could be a candidate for uploading to maven.
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "David Smiley (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13126731#comment-13126731 ] 

David Smiley commented on SOLR-2487:
------------------------------------

How about simply adding an expanded WAR deployment option and then the user can customize the libs or web.xml as they please?  I always prefer an expanded WAR because I'm always going to customize it.
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052643#comment-13052643 ] 

Hoss Man commented on SOLR-2487:
--------------------------------

"supported" is always a vague term, but like with every other ant property in our build file, the default is the "supported" one that we test, and if you override a property when building from source that's a customization and we won't promise that it will always work.

it's no different then if they override the "javac.source" property, or "build.encoding", etc...




> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Hoss Man (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13126844#comment-13126844 ] 

Hoss Man commented on SOLR-2487:
--------------------------------

David: I don't really understand what you mean by "adding an expanded WAR deployment option" ... nothing in the solr build system handles "deployment" we just generate artifacts, and one of those artifacts is a war - if you want to expand that war (to customize it) it's trivial to run "jar xf solr.war"


                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Hoss Man (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13028283#comment-13028283 ] 

Hoss Man commented on SOLR-2487:
--------------------------------

bq. It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

Personally, that sounds like a terrible idea to me.

Novice users would try the demo, see that it works, then try deploying to some other servlet container and suddenly get errors unless the servlet container had already explicitly loaded some slf4j binding jar?

we already have plenty of users who get confused about how (and even *why*) they configure the solr home dir when deploying solr to a servlet container -- this would make it ever harder for beginners.

simple things should be simple -- novice users should be able to copy a jar, and copy configs, and be good to go.

for a user who cares about jdk14 logging vs log4j vs whatever, the task of customizing the war is simple and straightforward to understand -- but for a solr user who doesn't know anything about java, picking an slf4j binding and configuring their servlet container to load could easily appear like a daunting burden that will make them turn away from even using solr past the tutorial stage.

this really seems like a no brainer to me

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Neil Hooey (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13266742#comment-13266742 ] 

Neil Hooey commented on SOLR-2487:
----------------------------------

Can someone upload the excl-slf4j war to Maven as Jan Høydahl mentioned?
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Issue Comment Edited] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13036819#comment-13036819 ] 

Jan Høydahl edited comment on SOLR-2487 at 5/20/11 6:59 PM:
------------------------------------------------------------

@Hoss, I like your option #1 with an ant option; no need to increase the size of the distro.

That would also solve the need for those that want no binding or another binding.

Alternatively we could also include a script in the binary distro which creates a war without a binding.

      was (Author: janhoy):
    @Hoss, I like your option #1 with an ant option; no need to increase the size of the distro.

That would also solve the need for those that want no binding or another binding.

In addition, it is perfectly possible to write a new ANT target which creates a new dist/apache-solr-3.1.0-no-slf4j-bindings.war based on the default dist/apache-solr-3.1.0.war. This can then also be run from the binary distribution!
  
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Updated] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (Updated JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jan Høydahl updated SOLR-2487:
------------------------------

    Attachment: SOLR-2487.patch

Same patch with CHANGES.txt entry
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13028300#comment-13028300 ] 

Jan Høydahl commented on SOLR-2487:
-----------------------------------

@Hoss
Your concerns are easily solved by documentation.

The novice users you're talking about are not likely to ever move past running Solr from the included Jetty in the example folder (I've seen such people). When you get to deploying to another servlet container, then you already know what a Java servlet container is. You also know about Java logging, setting Java Opts, and most importantly you read the install docs and understand how to copy a jar file into a folder.

SLF4j is now so common that the issue of having multiple crashing SLF4j bindings in your classpath will be more annoying to novice users than the opposite.

>From version 1.6 SLF4j will default to NOP binding if no binding is found, so users will still be able to use Solr: http://www.slf4j.org/codes.html#StaticLoggerBinder

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13028316#comment-13028316 ] 

Uwe Schindler commented on SOLR-2487:
-------------------------------------

+1 +1 +1 +1 ...

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Hoss Man (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13125990#comment-13125990 ] 

Hoss Man commented on SOLR-2487:
--------------------------------

Jan: looks fine to me

I'm not a huge fan of the name "dist-war-minimal" since it's only excluding log related jars (a truly minimal war might eliminate *all* jars and let you add the ones you need to the classpath) but functionally it seems fine.  (maybe "dist-war-no-slf4j")

Even with the explicit ant target, it still seems like making the properties overridable at runtime would be helpful for people who care about this sort of war customization/minimalization ... it looks like the patch would let you do this if you run "cd solr/webapp && ant dist -Dsolr.war.suffix=-micro -Dexclude.from.war=\*.jar" but not if you just run "cd solr/ && ant dist -Dsolr.war.suffix=-micro -Dexclude.from.war=\*.jar" 

... but i dunno, maybe it doesn't matter.  In any situation where i would consider customizing the war in *any* of the ways we're talking about in this issue i would do it in my own build.xml anyway, so maybe it's not worth the extra complexity to the solr build.xml (i would argue that about the entire issue -- but i get that slf4j is a particular pain point for some people)

                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Greg Pendlebury (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13267045#comment-13267045 ] 

Greg Pendlebury commented on SOLR-2487:
---------------------------------------

@Neil, that's way better then the way I do things now. Thanks.

Maven continues to surprise me.
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>            Assignee: Jan Høydahl
>              Labels: logging, slf4j
>             Fix For: 3.6, 4.0
>
>         Attachments: SOLR-2487.patch, SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Greg Pendlebury (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13084928#comment-13084928 ] 

Greg Pendlebury commented on SOLR-2487:
---------------------------------------

It would be great to have a skinny WAR available as a Maven artifact. At the moment there is no way in Maven to have it exclude the jdk14 JAR short of rebuilding and rehosting the WAR elsewhere. eg: http://www.jarvana.com/jarvana/browse/org/dspace/dependencies/solr/dspace-solr-webapp/1.4.1.0/

And to my knowledge at the moment, there is nothing like this available for v3.3.0

With a skinny WAR in Maven listing all the currently bundled dependencies the end result for most users would be identical, since Maven will go get them all for you anyway. Then people that don't want jdk14 can add this to their own project and they will get everything but that single dependency:
<dependency>
  <groupId>org.slf4j</groupId>
  <artifactId>slf4j-jdk</artifactId>
  <version>1.6.1</version>
  <scope>provided</scope>
</dependency>


> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Greg Pendlebury (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13084967#comment-13084967 ] 

Greg Pendlebury commented on SOLR-2487:
---------------------------------------

"At the moment there is no way in Maven to have it exclude the jdk14 JAR"... Hmm, I shouldn't have stated an absolute like that. I eventually got a script building today that dropped the WAR as a dependency, unpacked it to a '/solr' context folder, then nuked the jdk14 JAR only, leaving the rest in place.

I'd still prefer a skinny WAR, since it would be a much cleaner build script, and allow me to eliminate duplicate JARs on the classpath with greater ease. It would also be more in line with the spirit of how Maven is intended to work... but I have a workaround, and don't expect to world to conform to my wishes :)

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Commented] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052400#comment-13052400 ] 

Jan Høydahl commented on SOLR-2487:
-----------------------------------

Objections to choosing to parameterize the build like Hoss suggests?

> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


[jira] [Updated] (SOLR-2487) Do not include slf4j-jdk14 jar in WAR

Posted by "Jan Høydahl (Updated JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-2487?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jan Høydahl updated SOLR-2487:
------------------------------

    Attachment: SOLR-2487.patch

New patch with target name "dist-war-excl-slf4j". Now the exclude.from.war param also works across the whole war.

I tested the params with the dist target and it also works equivalently:
{noformat}
ant -Dexclude.from.war=*over-slf4j*,slf4j-jdk14* -Dsolr.war.suffix=--excl-slf4j clean dist
{noformat}
                
> Do not include slf4j-jdk14 jar in WAR
> -------------------------------------
>
>                 Key: SOLR-2487
>                 URL: https://issues.apache.org/jira/browse/SOLR-2487
>             Project: Solr
>          Issue Type: Improvement
>          Components: Build
>    Affects Versions: 3.2, 4.0
>            Reporter: Jan Høydahl
>              Labels: logging, slf4j
>         Attachments: SOLR-2487.patch, SOLR-2487.patch
>
>
> I know we've intentionally bundled slf4j-jdk14-1.5.5.jar in the war to help newbies get up and running. But I find myself re-packaging the war for every customer when adapting to their choice of logger framework, which is counter-productive.
> It would be sufficient to have the jdk-logging binding in example/lib to let the example and tutorial still work OOTB but as soon as you deploy solr.war to production you're forced to explicitly decide what logging to use.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

       

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org