IBM Support

Attempts to build application with older version of servlet specification causes compile errors

Troubleshooting


Problem

Attempts to build an application with older version of servlet specification causes compile errors on IBM Rational Application Developer for WebSphere Software, when project's targeted WebSphere Application Server supports newer version of servlet specification.

Symptom

In case there is a ClassA implements the HttpServletRequest in the servlet 2.3 web project and its target runtime was V6.0, if changing the target runtime to V8.0, the compile errors occurs due to not implementing the abstract methods which introduced in servlet 2.4 or later despite the actual servlet version is 2.3. Errors will be detected on the methods like #getPart(String), #login(Stirng, String), #logout(),,,etc. in this case.

Common error messages on this issue is following:


The type Xxx must implement the inherited abstract method Yyy

Steps to reproduce:

  1. Create a "Dynamic Web project"
    - Setting target WebSphere Application Server runtime as v6.0
    - Setting the servlet facet version as 2.3
  2. Create a class (ex, ClassA) and implement interface HttpServletResponse, with "Create inherited abstract method" option
  3. Change the target WebSphere Application Server runtime to v8.0
  4. You will see compile errors on ClassA due to not implementing the inherited abstract methods introduced in servlet 2.4/2.5/3.0
[{"Product":{"code":"SSRTLW","label":"Rational Application Developer for WebSphere Software"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Component":"Server Tooling","Platform":[{"code":"PF033","label":"Windows"}],"Version":"7.5;7.5.1;7.5.2;7.5.3;7.5.4;7.5.5;7.5.5.1;7.5.5.2;7.5.5.3;7.5.5.4;8.0;8.0.1;8.0.2;8.0.3","Edition":"","Line of Business":{"code":"LOB77","label":"Automation Platform"}}]

Log InLog in to view more of this document

This document has the abstract of a technical article that is available to authorized users once you have logged on. Please use Log in button above to access the full document. After log in, if you do not have the right authorization for this document, there will be instructions on what to do next.

Document Information

More support for:
Rational Application Developer for WebSphere Software

Software version:
7.5, 7.5.1, 7.5.2, 7.5.3, 7.5.4, 7.5.5, 7.5.5.1, 7.5.5.2, 7.5.5.3, 7.5.5.4, 8.0, 8.0.1, 8.0.2, 8.0.3

Operating system(s):
Windows

Document number:
427817

Modified date:
16 June 2018

UID

swg21507291

Manage My Notification Subscriptions