Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [lyo-dev] Issues getting Lab 6 working

Right -- now working -- thanks for help!

Rgs,

/N

On 28 nov 2012, at 18:33, Michael Fiedler <fiedler.mf@xxxxxxxxx> wrote:

Nils, this looks possibly related to:   https://bugs.eclipse.org/bugs/show_bug.cgi?id=392325.  

Can you try this for me?

1. Edit AbstractOslcRdfXmlProvider.java (in the OSLC4JJenaProvider project) and find this chunk of code in the writeTo() method:

            RDFWriter writer = null;
            if  (serializationLanguage.equals(FileUtils.langXMLAbbrev))
            {
                writer = new RdfXmlAbbreviatedWriter();
            }
            else
            {
                writer = model.getWriter(serializationLanguage);
            }

2. Comment out/change 
      writer = new RdfXmlAbbreviatedWriter();
to:
      writer = model.getWriter(serializationLanguage);

3. Do a Maven clean/Maven install on OSLC4JJenaProvider
4. Do a Maven clean/Maven install on Lab6 (or whichever project you are launching).

Let me know if this causes the problem to go away - if so, I will raise the priority of that bug and get it fixed.   I will also try to recreate using that same project on landfill.

Thanks for the help (and persistence) in debugging this.

Regards,
Mike




On Wed, Nov 28, 2012 at 12:07 PM, Nils Kronqvist <nissekronqvist@xxxxxxxxxxx> wrote:
Tried debugging … the Add Association dialog will make call eventually hitting RdfXmlAbbreviatedWriter::write. The rootResource will be the http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/catalog/singleton entry .. but looking quite odd as recursive structure; the rootResource is instance of ResourceImpl with attribute ring with value == the rootResource ..   

When trying access http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/catalog/singleton (using the Advanced Rest Client) using application/xml+rdf I get a OK response -- and not hitting my breakpoints in RdfXmlAbbreviatedWriter::write .. but if using same as RTC, i.e. application/xml .. I hit the breakpoint --> if I let it run, the Rest client crashes.

The rdf (incomplete …but can guess how it continues ..) when using the application/xml looking like:

<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF
    xmlns:dcterms="http://purl.org/dc/terms/"
    <dcterms:title rdf:datatype="http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral">OSLC Service Provider Catalog</dcterms:title>
    <oslc:serviceProvider>
        <dcterms:title rdf:datatype="http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral">MyOwnBadSelf</dcterms:title>
        <oslc:details>
          <oslc:ServiceProvider rdf:about="http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/serviceProviders/3">
            <dcterms:title rdf:datatype="http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral">MyOwnBadSelf</dcterms:title>
            <oslc:details>
              <oslc:ServiceProvider rdf:about="http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/serviceProviders/3">
                <dcterms:title rdf:datatype="http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral">MyOwnBadSelf</dcterms:title>
                <oslc:details>
                  <oslc:ServiceProvider rdf:about="http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/serviceProviders/3">
                    <dcterms:title rdf:datatype="http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral">MyOwnBadSelf</dcterms:title>
                    <oslc:details>
                      <oslc:ServiceProvider rdf:about="http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/serviceProviders/3">
                        <dcterms:title rdf:datatype="http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral">MyOwnBadSelf</dcterms:title>
                        <oslc:details>


Any tips?

Rgs,

/N

On 28 nov 2012, at 16:00, Michael Fiedler <fiedler.mf@xxxxxxxxx> wrote:

Looks like Rational Team Concert does not like something about the response.   I've recently tested against several versions successfully, so guessing it might be something in the content.   Can you expand the TypeError and see if that gives any clues.


On Wed, Nov 28, 2012 at 3:47 AM, Nils Kronqvist <nissekronqvist@xxxxxxxxxxx> wrote:

On 27 nov 2012, at 22:35, Michael Fiedler <fiedler.mf@xxxxxxxxx> wrote:

That older namespace is actually correct - the IBM Rational Jazz rootservices protocol still uses it for the cmServiceProviders predicate.  "http://open-services.net/xmlns/cm/1.0/" is correct, strange as it seems, so you will have to change it back.
[Nils] OK. When using it I got a "reasonable" response though .. as opposed to the loop below. But guess "reasonable" was due to quick fail ..


Things to check
   - are you being prompted for a login to the Bugzilla server when you select the friend in the associations dialog?   You should be.
[Nils] Yes.

Double check you are not getting a warning from your browser to accept popups from the OSLC4JBugzilla server.
   - are there any exceptions on the console?
[Nils] At some point I am getting *lots* of messages:
at org.eclipse.lyo.oslc4j.provider.jena.RdfXmlAbbreviatedWriter.serializeStatement(RdfXmlAbbreviatedWriter.java:469)
Seems likely related to issue described below … code at line 469:

while (statementIterator.hasNext()) {
---> serializeStatement(statementIterator.next(), xmlWriter, serializedResources);
}
Infinite loop ..?



Try these first.   If no luck, we might need to set a breakpoint on the OSLC4JBugzilla server to make sure it is returning a catalog to your consumer.
[Nils] I'll describe the exact steps ..

1) After selecting the application in the Add Association my breakpoint in ServerProviderCatalogService .. public ServiceProviderCatalog getServiceProviderCatalog()) is hit.
2) When continuing i notice in the "Network" view that a response is coming .. but a bit too large :) .. MBs keep ticking in ... (The type error was there before)


3) When going to the "Sources" tab and pausing the script, it's stuck at a function .. see below. To stop (as said transferred many MBs by then .. clearly not correct), I reloaded the page.




Attaching the response from calling http://nkronqvist.no-ip.org:8080/OSLC4JBugzilla/services/catalog/singleton with header Accept: application/rdf+xml



Any ideas what can be the issue?

Rgs,

/N



Regards,
Mike



On Tue, Nov 27, 2012 at 3:52 PM, Nils Kronqvist <nissekronqvist@xxxxxxxxxxx> wrote:
http://open-services.net/ns/cm#

_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/lyo-dev


_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/lyo-dev


_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/lyo-dev


_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/lyo-dev


_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/lyo-dev


Back to the top