[Mulgara-general] Not yet for newbie
Guojun Zhu
shmilylemon at yahoo.com
Tue Nov 21 08:22:28 UTC 2006
It does not work. I got such problem. I got it around
with itqlinterpreterbean though. Thanks for your
help.
javax.servlet.ServletException
org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:858)
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:791)
org.apache.jsp.index_jsp._jspService(index_jsp.java:107)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
root cause
java.lang.NoClassDefFoundError
sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native
Method)
sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
java.lang.reflect.Constructor.newInstance(Constructor.java:494)
java.lang.Class.newInstance0(Class.java:350)
java.lang.Class.newInstance(Class.java:303)
org.apache.jasper.runtime.TagHandlerPool.get(TagHandlerPool.java:116)
org.apache.jsp.index_jsp._jspx_meth_mulgara_init_0(index_jsp.java:119)
org.apache.jsp.index_jsp._jspService(index_jsp.java:88)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)
--- David Wood <dwood at softwarememetics.com> wrote:
> Hi Guojin,
>
> Thanks for your description of our documentation
> problems. We can
> use your mail to address the documentation before
> the next Mulgara
> release.
>
> It is unfortunate that you are trying to use the JSP
> library with
> Mulgara. I do not believe that the JSP library has
> been touched in
> years and it is only tested via the unit tests. You
> are therefore
> probably right about Java 1.5. classes causing
> problems with it.
>
> These directions should get you going, but I HAVE
> NOT TRIED THEM.
> Let me know if you continue to have trouble and I
> will see if I can
> give you confirmed directions. Please make sure you
> give me the
> details of your environment if that becomes
> necessary.
>
> The JSP library uses the SOAP endpoint in the API.
> It depends on a
> servlet container that supports the JavaServer Pages
> Specification,
> version 1.1 or higher.
>
> In Mulgara, the JSP library JAR has been moved to
> <install_dir>/bin/
> tag-base-1.1.0.jar - that may be been enough to
> confuse you if you
> were looking at the JSP directions on the old Kowari
> documentation
> site (at http://kowari.org/oldsite/485.htm).
>
> You will have to copy .../bin/tag-base-1.1.0.jar and
> .../bin/
> taglib.tld to the /WEB-INF/lib directory of your Web
> application server.
>
> Then, add a <taglib> element to your Web application
> deployment
> Descriptor in /WEB-INF/web.xml:
>
> <taglib>
>
>
<taglib-uri>http://www.mulgara.org/mulgara/taglibs/mulgara</taglib-
>
> uri>
>
>
<taglib-location>/WEB-INF/lib/tag-base-1.1.0.jar</taglib-location>
> </taglib>
>
> NB: Note that the URI and JAR file names are
> different than for Kowari!
>
> Next, add this directive to the top of each of your
> JSP pages:
>
> <%@ taglib prefix="mulgara"
> uri="http://www.mulgara.org/mulgara/
> taglibs/mulgara"%>
>
>
> The JSP tags you will then have available are:
> init - Initializes the Mulgara JSP tag environment
> by setting the
> SOAP endpoint of the Mulgara server
> render - Renders an XML document using a supplied
> stylesheet
> statement - Sends queries to a Mulgara server
> query - Adds an iTQL query to a statement
> execute - Executes queries in a statement
> answer - Retrieves query answers from a statement
>
>
> An example JSP page would work like this, if you
> change the init tag
> to point to your Mulgara instance:
>
> <%-- initialise the environment with the SOAP
> endpoint's URL--%>
> <mulgara:init
> server="http://mysite.com:8080/webservices/services/
>
> ItqlBeanService"/>
> <%-- render the results of a query --%>
> <mulgara:render stylesheet="/default.xsl">
>
> <%-- execute a statement --%>
> <mulgara:statement>
>
> <mulgara:query>
> select $subj $pred $obj from
> rmi://localhost/server1#foo where
> $subj $pred $obj ;
> </mulgara:query>
>
> <%-- execute the query --%>
> <mulgara:execute/>
>
> </mulgara:statement>
> </mulgara:render>
>
>
> Regards,
> Dave
>
>
> On 20 Nov2006, at 05:02, Guojun Zhu wrote:
> > Hi,
> >
> > I am a newbie for the rdf. I know fairly amount
> about
> > java and sql though. Kowari and Mulgara are great
> > stuff. The tutorial of itql is also very nice. I
> > admire your hard work. However, I would express
> some
> > frustration on these especially, the
> documentation.
> >
> > I guess you have already see my message about
> weird
> > problem with kowari-1.2. It works on and off with
> my
> > jsp codes on tomcat 5.5. I highly suspect it is
> > because of some java 1.5 class in my codes. And I
> > suspected some bugs of packaging problem with it.
> >
> > One thing I am sure is that the javadoc with it is
> > non-synchronized. One class mentioned in the jrdf
> > tutorial of wiki, AbstractGraphFactory for
> client-side
> > model is not in the jar file while it is in the
> > javadoc.
> >
> > The non-existing documentation really gives me
> > headache. I have a running kowari server and
> would
> > like to access it from a web application of jsp in
> > tomcat. The Tag part is not completed in the
> wiki.
> > The jrdf tutorial use this non-existing class. And
> > jrdf has almost no documents itself. Jena's
> tutorial
> > is quite short and
> > jena's own site is not that clear either.
> >
> > Also, the example class mentioned in the tutorial
> > exists in the jar as class but I just cannot find
> them
> > in the source package.
> >
> > Can anyone give me a simple example to access the
> > database please? I only need to access it from a
> java
> > class with jsp in the tomcat. I do not need to
> > perform any advance function. The only type of
> the
> > queries I would like to perform is "select $o
> from
> > <rmi://localhost:test#test> where <hfk>
> <jfkd:title>
> > $o".
>
____________________________________________________________________________________
Sponsored Link
Compare mortgage rates for today.
Get up to 5 free quotes.
Www2.nextag.com
More information about the Mulgara-general
mailing list