Hi Hugues ,

Thanks for the reply .

I did not get your statement 'Maybe you could turn on the directory listing
of the default servlet or use an absolute path to define the base ?' .
Maybe i can give you the dir structure of the project and wanted your inputs
whether  the declaration which i did in jetty.xml is valid or not

BundleName (myapplication)
--->src folder
      ---------->com.test (package name under src folder)
                  HelloServlet.java
--->Meta-INF folder
     ------------>MANIFEST.MF
--->jetty.xml (located in same hierachy with src folder )

Questions : 1) Is the location of jetty.xml is in correct folder structure?
                   2) Now do i need to address HelloServlet in jetty .xml
somewhere ??? if yes how it can be incorporated in jetty.xml ? if no the how
the default servlet decalration i.e "  <Set
name="className">org.eclipse.jetty.servlet.DefaultServlet</Set> " wil point
to required servlet i.e HelloServlet ??

No i did apply break points in resource resolver :(


Also how can i achive HttpService in jetty7.2.2 so that i can register my
servlet on dynamically ??

Best Regards,
Mitul






On Tue, Feb 8, 2011 at 1:34 PM, Hugues Malphettes
<[email protected]>wrote:

> Hi Mitul,
> Looking at the jetty.xml file, I am not sure that the issue is OSGi
> specific although I could be mistaken.
> Maybe you could turn on the directory listing of the default servlet or use
> an absolute path to define the base ?
>  Have you tried placing breakpoints inside the resource resolver?
> Let us know,
> Hugues
>
> On Tue, Feb 8, 2011 at 2:14 PM, Mitul Adhia <[email protected]>wrote:
>
>> Hi All,
>>
>> I am using Jetty 7.2.2 embedded in my application . It is an osgi based
>> application running on equinox. Now my requirement is to run jetty server
>> using the configuration file . below is the snippet which i have used to
>> read the configuration file . The execution goes fine w/o any exception but
>> when i open the URL *http://localhost:50099/timeline* it says *no
>> resource found error 404.*
>> *
>> *
>> I have written one servlet and now i wanted to register that servlet with
>> the connector so that i can run the servlet from the broswer. To incorporate
>> this did necessary changes in jetty.xml.
>>
>> Resource fileserver_xml;
>> try {
>> // http://dev.eclipse.org/mhonarc/lists/jetty-users/msg00075.html
>>
>> Thread.currentThread().setContextClassLoader(Activator.class.getClassLoader());
>> fileserver_xml = Resource.newResource("newWP/testapplication/jetty.xml");
>>  XmlConfiguration configuration = new
>> XmlConfiguration(fileserver_xml.getInputStream());
>>         Server server = (Server)configuration.configure();
>>         server.start();
>>         server.join();
>> } catch (IOException e) {
>> // TODO Auto-generated catch block
>>  e.printStackTrace();
>> } catch (SAXException e) {
>> // TODO Auto-generated catch block
>>  e.printStackTrace();
>> } catch (Exception e) {
>> // TODO Auto-generated catch block
>>  e.printStackTrace();
>> }
>>
>>
>> Attached is the jetty .xml file attached for reference.
>> Could you please let me know what went wrong in this ?
>>
>> Best Regards,
>> mitul
>>
>>
>> _______________________________________________
>> jetty-users mailing list
>> [email protected]
>> https://dev.eclipse.org/mailman/listinfo/jetty-users
>>
>>
>
> _______________________________________________
> jetty-users mailing list
> [email protected]
> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
>
_______________________________________________
jetty-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/jetty-users

Reply via email to