1

I have been working on an inherited code base that is a Java web app and just today it stopped compiling. I am getting errors that it can't find some classes that are declared in the code.

My code base is set up like this: I've got the main package and then, for some reason, both inside it and at the same level of it, I've got a .jar that holds a supplemental package, com.oreilly.servlet to be exact. I have some files in my main code base that import com.oreilly.servlet.MultipartRequest and utill today they had no problem finding them.

I have since wiped my local version and checked out the last revision which I know compiled last timed I made any changes to the java files, leading me to believe my issue is jdeveloper.

The errors I am getting are that package com.oreilly.servlet doesn't exist and subsequently that it cannot find class MultipartRequest.

I have also broken out the jar file (which by the way is included int he Libraries and Classpath section of jdev) into a package structure to no avail.

Any help would be much appreciated.

sgd
  • 31
  • 4

1 Answers1

1

Sounds like an opportunity to update and refactor to me. I stumbled across the com.oreilly package years ago, haven't seen it since. I say remove it from the code and upgrade to the more standard javax.servlet classes (usually found in a servlet-api.jar or something similarly named bundled with your web app server).

RichW
  • 2,004
  • 2
  • 15
  • 24
  • Thanks for the suggestion, maybe I'll tackle that eventually, but I'm not sure how much work that will take. I would rather find out what it is that actually caused jdev or the app to stop recognizing the com.oreilly.servlet files in the first place. Any other suggestions? – sgd Sep 19 '11 at 19:03
  • Are you certain that those two jar files are identical? Check their sizes, check their content. Perhaps one is an older version than the other? Perhaps once contains classes the other needs? Was there a build script provided that you can refer to? – RichW Sep 19 '11 at 19:18
  • Thanks for the help. I fixed it just by relinking to the library in JDeveloper. – sgd Sep 23 '11 at 15:48