• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How to create a jar file that suits this specification?

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am trying to add a customized provider to Axis. In the Axis code, it specifies:

/**
Look for file META-INF/services/org.apache.axis.deployment.wsdd.Provider in all the JARS, get the classes listed in those files and add them to providers list if they are valid providers.

Here is how the scheme would work.

A company providing a new provider will jar up their provider related
classes in a JAR file. The following file containing the name of the new
provider class is also made part of this JAR file.

META-INF/services/org.apache.axis.deployment.wsdd.Provider

By making this JAR part of the webapp, the new provider will be automatically discovered.
*/

So for example, if I have a new Provider called AAAProvider,
I have to put it under the "org.apache.axis.deployment.wsdd.Provider" package, right?

But I don't quite understand the "META-INF/services/" part. Does it means that I put the class file in a dir like the following?

services/org/apache/axis/deployment/wsdd/Provider/AAAProvider

 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It means this:

1. Create a file named org.apache.axis.deployment.wsdd.Provider (with dots, not a directory tree!).
2. In the file, add one line with the fully qualified class name of your implementation ("org.my.package.AAAProvider", for example).
3. Make sure the file you created in step 1 is in the directory META-INF/services in your JAR file (not in a directory services/org/... as you think!).
 
Yun Shang
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you, it works!
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic