provide a metacat client library with a standard API
Need to be able to call metacat directly from another servlet or from within a
client app (using it for local metadat storage), so need to make it into a
library that can be called this way, rather than passing params via an
inefficient http mechanism when it isn't needed. Owne and John agreed to
collaborate on this.
#3 Updated by Matt Jones almost 18 years ago
I implemented a functional metacat client API that can be used on both the
client and server. The interface is defined in "Metacat.java". It can be built
using "ant clientjar". To use it in another application, make sure that both
metacat-client.jar and utilities.jar are on your classpath.
Some issues remain. In paticular:
1) The HttpMessage code uses static cookies. This is bad and should be changed.
2) Most of the APIs return Readers. In some cases we may also want InputStream
in order to deal with binary data (including ZIP data). Returning Strings would
be reasonable for some methods and would provide a simpler interface for some
types of clients (such as SOAP).
3) The exceptions used are rich, but difficult to deal with in some environments
such as SOAP.
4) The current client uses HTTP. There may be clients that exist on the same
server for which we would want to use some direct IPC channel, or direct method
calls for efficiency.
An example of using the client library is in the tests directory as