Menu

Compiling TJWS

Help
Anonymous
2011-09-25
2012-10-08
  • Anonymous

    Anonymous - 2011-09-25

    I'm trying to use TJWS as an embedded Servlet webserver for a project that
    uses Maven (https://github.com/FrozenCow/dynmap/tree/servlets). I found that TJWS was in the Maven-
    repository of JBoss (https://repository.jboss.org/nexus/content/groups/public
    /tjws/),
    but had some trouble with that package and thought it would be better to
    just include Serve.java (and related files) from a official release to the
    source of my project.

    However, when I try to do this I can't compile the project. It seems that a
    lot of the methods that are in the interfaces of Servlet-spec (3.0) are not
    implemented. One example is 'addFilter'. I think I'm missing something, but
    I'm not a Java expert. Do you know what is wrong?

     
  • Д Рогаткин

    It is mostly legacy stuff I am trying to resolve now. The methods with pattern addServlet were introduced by Jef Poskanzer in original version of TJWS. These methods didn't conflict with servlet specifications until version 3.0 where they were introduced in slightly different purpose. I use servlet specification 2.3 to compile main module and specification 3.0 for the rest. So here is the trick. You need to carry two versions of servlet.jar. If I overwrite the methods accordingly servelt specification, then certain applications used them in old notation can break. So I am thinking to introduce TJWS version 2.0 which will be pure servlet specification 3.x capable. So older application need either stick with TJWS 1.x, or do some code migration.

     

Log in to post a comment.