You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@nutch.apache.org by Sami Siren <ss...@gmail.com> on 2008/08/21 17:13:17 UTC

directions for web ui? [was Re: web2 plugins compilation error]

Hi,

The web2 ui was originally an effort to make the web ui more modular and 
easier to customize. The architecture below the surface is mildly put 
outdated and it relies on a dirty trick that allows jsp's to be executed 
from inside .jar files.

If I would write it again today I would probably use webmacro or 
velocity instead to get rid of the hack that breaks on servlet 
containers with different versions of jsp api. My recommendation is: do 
not use it ;)

It has long been on my todo list to start discussion about the future of 
a end user interface in Nutch and possible future directions (where did 
all that time go?). I think that we need a simple to maintain ui that is 
easy to customize (both of the current ui fail to satisfy those 
requirements IMO).

What kind of thought do others have?

--
 Sami Siren



michos101 wrote:
> Hi,
> i am trying to enable the web2 plugins but i am get an issue on when i try
> to compile the plugins
>
> i get the following errors
>
> init:
>
> compile-plugins:
>
> deploy:
>
> init:
>
> init-plugin:
>
> compile:
>
> jar:
>       [jar] Warning: skipping jar archive
> /usr/local/mputa01/build/webui-extensionpoints/webui-extensionpoints.jar
> because no files were included.
>
> deps-test:
>
> deploy:
>
> init:
>
> init-plugin:
>      [echo] Copying UI configuration
>      [echo] Copying UI templates
>
> deps-jar:
>
> prepare-web:
>    [delete] Deleting directory
> /usr/local/mputa01/build/web-caching-oscache/tmp/_web
>      [copy] Copying 5 files to
> /usr/local/mputa01/build/web-caching-oscache/tmp/_web
>
> compile-jsp:
>
> compile:
>      [echo] Compiling plugin: web-caching-oscache
>     [javac] Compiling 4 source files to
> /usr/local/mputa01/build/web-caching-oscache/classes
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:32: 
> package org.apache.nutch.webapp.common does not exist
>     [javac] import org.apache.nutch.webapp.common.Search;
>     [javac]                                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:33: 
> package org.apache.nutch.webapp.common does not exist
>     [javac] import org.apache.nutch.webapp.common.ServiceLocator;
>     [javac]                                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:127: 
> cannot find symbol
>     [javac] symbol  : class ServiceLocator
>     [javac] location: class org.apache.nutch.webapp.CacheManager
>     [javac]   public Search getSearch(String id, ServiceLocator locator) 
> throws NeedsRefreshException  {
>     [javac]                                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:127: 
> cannot find symbol
>     [javac] symbol  : class Search
>     [javac] location: class org.apache.nutch.webapp.CacheManager
>     [javac]   public Search getSearch(String id, ServiceLocator locator) 
> throws NeedsRefreshException  {
>     [javac]          ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:162: 
> cannot find symbol
>     [javac] symbol  : class Search
>     [javac] location: class org.apache.nutch.webapp.CacheManager
>     [javac]   public void putSearch(String id, Search search){
>     [javac]                                    ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:27: 
> package org.apache.nutch.webapp.common does not exist
>     [javac] import org.apache.nutch.webapp.common.Search;
>     [javac]                                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:28: 
> package org.apache.nutch.webapp.common does not exist
>     [javac] import org.apache.nutch.webapp.common.ServiceLocator;
>     [javac]                                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:29: 
> package org.apache.nutch.webapp.common does not exist
>     [javac] import org.apache.nutch.webapp.common.Startable;
>     [javac]                                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:30: 
> cannot find symbol
>     [javac] symbol  : class SearchController
>     [javac] location: package org.apache.nutch.webapp.controller
>     [javac] import org.apache.nutch.webapp.controller.SearchController;
>     [javac]                                          ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:39: 
> cannot find symbol
>     [javac] symbol: class SearchController
>     [javac] public class CachingSearchController extends SearchController
> implements Startable {
>     [javac]                                              ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:39: 
> cannot find symbol
>     [javac] symbol: class Startable
>     [javac] public class CachingSearchController extends SearchController
> implements Startable {
>     [javac]      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:128: 
> cannot find symbol
>     [javac] symbol  : class Search
>     [javac] location: class org.apache.nutch.webapp.CacheManager
>     [javac]     Search search=null;
>     [javac]     ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/CacheManager.java:140: 
> cannot find symbol
>     [javac] symbol  : class Search
>     [javac] location: class org.apache.nutch.webapp.CacheManager
>     [javac]         search = new Search(locator);
>     [javac]                      ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:47: 
> cannot find symbol
>     [javac] symbol  : class ServiceLocator
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]     ServiceLocator locator = getServiceLocator(request);
>     [javac]     ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:47: 
> cannot find symbol
>     [javac] symbol  : method
> getServiceLocator(javax.servlet.http.HttpServletRequest)
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]     ServiceLocator locator = getServiceLocator(request);
>     [javac]                              ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:48: 
> cannot find symbol
>     [javac] symbol  : class Search
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]     Search search;
>     [javac]     ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:58: 
> cannot find symbol
>     [javac] symbol  : variable LOG
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]     if(LOG.isDebugEnabled()){
>     [javac]        ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:59: 
> cannot find symbol
>     [javac] symbol  : variable LOG
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]       LOG.debug("cache key:" + cacheKey);
>     [javac]       ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:64: 
> cannot find symbol
>     [javac] symbol  : variable Search
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]         request.setAttribute(Search.REQ_ATTR_SEARCH, search);
>     [javac]                              ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:65: 
> cannot find symbol
>     [javac] symbol  : variable LOG
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]         if(LOG.isDebugEnabled()) {
>     [javac]            ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:66: 
> cannot find symbol
>     [javac] symbol  : variable LOG
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]           LOG.debug("Using cached");
>     [javac]           ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:70: 
> cannot find symbol
>     [javac] symbol  : variable super
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]           super.nutchPerform(tileContext, request, response, 
> servletContext);
>     [javac]           ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:71: 
> cannot find symbol
>     [javac] symbol  : class Search
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]           search = (Search) locator.getSearch();
>     [javac]                     ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:75: 
> cannot find symbol
>     [javac] symbol  : variable LOG
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]           LOG.info("Cancelling update");
>     [javac]           ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:83: 
> cannot find symbol
>     [javac] symbol  : class ServiceLocator
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]     ServiceLocator locator=getServiceLocator(servletContext);
>     [javac]     ^
>     [javac]
> /usr/local/mputa01/contrib/web2/plugins/web-caching-oscache/src/java/org/apache/nutch/webapp/controller/CachingSearchController.java:83: 
> cannot find symbol
>     [javac] symbol  : method getServiceLocator(javax.servlet.ServletContext)
>     [javac] location: class
> org.apache.nutch.webapp.controller.CachingSearchController
>     [javac]     ServiceLocator locator=getServiceLocator(servletContext);
>     [javac]                            ^
>     [javac] Note: 
> /usr/local/mputa01/build/web-caching-oscache/tmp/_src/org/apache/nutch/web2/plugin/WEB_002dINF/jsp/common_jsp.java
> uses unchecked or unsafe operations.
>     [javac] Note: Recompile with -Xlint:unchecked for details.
>     [javac] 26 errors
>
> BUILD FAILED
> /usr/local/mputa01/contrib/web2/build.xml:140: The following error occurred
> while executing this line:
> /usr/local/mputa01/contrib/web2/plugins/build.xml:30: The following error
> occurred while executing this line:
> /usr/local/mputa01/contrib/web2/plugins/build-plugin.xml:126: Compile
> failed; see the compiler error output for details.
>
> Total time: 3 seconds
> [root@mputa-1 web2]#
>
>   


Re: directions for web ui? [was Re: web2 plugins compilation error]

Posted by Andrzej Bialecki <ab...@getopt.org>.
Sami Siren wrote:
> Hi,
> 
> The web2 ui was originally an effort to make the web ui more modular and 
> easier to customize. The architecture below the surface is mildly put 
> outdated and it relies on a dirty trick that allows jsp's to be executed 
> from inside .jar files.
> 
> If I would write it again today I would probably use webmacro or 
> velocity instead to get rid of the hack that breaks on servlet 
> containers with different versions of jsp api. My recommendation is: do 
> not use it ;)
> 
> It has long been on my todo list to start discussion about the future of 
> a end user interface in Nutch and possible future directions (where did 
> all that time go?). I think that we need a simple to maintain ui that is 
> easy to customize (both of the current ui fail to satisfy those 
> requirements IMO).
> 
> What kind of thought do others have?

I agree that we have to keep things simple. Nutch is not about the shiny 
UI, but rather the down-to-earth functionality, and then users can put 
their own shiny UI on top of the platform.

If we can come up with something slightly better and easier to customize 
than a bunch of ugly jsp-s then we should do it.

IMHO web2 goes to far in this regard - it's too complex. Further, since 
it's not that well maintained and doesn't even compile, I'd be in favor 
of removing it completely.

-- 
Best regards,
Andrzej Bialecki     <><
  ___. ___ ___ ___ _ _   __________________________________
[__ || __|__/|__||\/|  Information Retrieval, Semantic Web
___|||__||  \|  ||  |  Embedded Unix, System Integration
http://www.sigram.com  Contact: info at sigram dot com