On Tue, Feb 12, 2013 at 7:10 PM, Parvathy J A <parvath...@suntecgroup.com>wrote:

> **
>
>
> Hi,
>
>    I have exposed a POJO class as webservice programatically using axis2
> and i tested the same using SimpleHTTPServer in Axis2, and im getting the
> wsdl correctly.
>
>    But when i tried to deploy the same in Jetty its throwing error as EPR
> not found.
>

This is probably because, the service is not correctly deployed.

> I dont have an axis .aar file .I just have the location of my class file.
>

What are errors did you see when the server is starting?

Can you try other options mentioned in here [1] and see? It basically says
about WAR based deployment of Axis2 on jetty.


Thanks,
Kishanthan.
[1] http://ssagara.blogspot.com/2009/10/axis2-on-embedded-jetty.html

>
>                Server server = new Server(8081);
>                 ConfigurationContext context =
> ConfigurationContextFactory.createConfigurationContextFromFileSystem(null,
> null);
>                 AxisConfiguration cfg = context.getAxisConfiguration();
>
>                 AxisService service =
> AxisService.createService(SampleServiceImpl.class.getName(), cfg, null, "",
> "http://samples";, SampleServiceImpl.class.getClassLoader());
>                 service.setScope("application");
>                 context.setContextRoot("");
>                 cfg.addService(service);
>
>
>                 WebAppContext webapp = new WebAppContext();
>                 webapp.setContextPath("/");
>                 webapp.setServer(server);
>
>                 FileResource basePath = new FileResource(new URL("
> file:E:\\Nuwaza\\workspace\\webservertest\\target\\test-classes"));//the
> place where my class is present
>                 webapp.setBaseResource(basePath);
>                 ServletHolder holder=new ServletHolder(new AxisServlet());
>                 holder.setInitParameter("axis2.repository.path",
> "C:\\Parvathy\\ServiceContainer\\axis2-1.6.2-bin\\axis2-1.6.2\\repository");
> //the default repository with axis library
>
>                 webapp.addServlet(holder, "/services/*");
>
>                 server.setHandler(webapp);
>                 server.start();
>                 server.join();
>
> Please guide
>
> Regards,
> Parvathy J A
>
>
>
>
> This electronic mail (including any attachment thereto) may be
> confidential and privileged and is intended only for the individual or
> entity named above. Any unauthorized use, printing, copying, disclosure or
> dissemination of this communication may be subject to legal restriction or
> sanction. Accordingly, if you are not the intended recipient, please notify
> the sender by replying to this email immediately and delete this email (and
> any attachment thereto) from your computer system...Thank You.
>

Reply via email to