problem with feeder plugin

View: New views
6 Messages — Rating Filter:   Alert me  

problem with feeder plugin

by Vicent Mas-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi,

In a recent post I've been suggested to have a look to the feeder plugin
(among others) as it could help me to deal with problems in a customised
contract. I've done it, but I cannot manage to get the plugin working in my
website. Following the instructions in the feeder plugin site,
http://forrest.apache.org/pluginDocs/plugins_0_80/org.apache.forrest.plugin.input.feeder/index.html:

- I've created a feedDescriptor.xml with the content

<document>
  <head>
    <title>Test</title>
  </head>
  <body>
    <feedDescriptor>
      <feed id="BBCSport_UK">
        <url>http://news.bbc.co.uk/rss/sportonline_uk_edition/front_page/rss.xml</url>
      </feed>
    </feedDescriptor>
  </body>
</document>

Nothing is said in the webpage about filename extension or format. I'm assuming
it has to be a xdoc document with .xml extension. The file lives in the xdocs
directory of my project (i.e. src/documentation/content/xdocs)

- In a page of my website I've added (inside a <p> element) the link:

<a href="./feedDescriptor.rss.html">BBC Sports UK</a>

- I've executed 'forrest run'

When I click over the rss link I get the following Internal Server Error:

Message: null

Description: No details available.

Sender: org.apache.cocoon.servlet.CocoonServlet

Source: Cocoon Servlet

cause

HIERARCHY_REQUEST_ERR: An attempt was made to insert a node where it is not
permitted.

Request URI

feedDescriptor.rss.html

request-uri

/feedDescriptor.rss.html

Could somebody tell me what am I doing wrong? TIA

Vicent
::

        Share what you know, learn what you don't



signature.asc (205 bytes) Download Attachment

Re: problem with feeder plugin

by Vicent Mas-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> Hi,

>
> In a recent post I've been suggested to have a look to the feeder plugin
> (among others) as it could help me to deal with problems in a customised
> contract. I've done it, but I cannot manage to get the plugin working in my
> website. Following the instructions in the feeder plugin site,
> http://forrest.apache.org/pluginDocs/plugins_0_80/org.apache.forrest.plugin
> .input.feeder/index.html:
>
> - I've created a feedDescriptor.xml with the content
>
> <document>
>   <head>
>     <title>Test</title>
>   </head>
>   <body>
>     <feedDescriptor>
>       <feed id="BBCSport_UK">
>        
>  <url>http://news.bbc.co.uk/rss/sportonline_uk_edition/front_page/rss.xml</
> url> </feed>
>     </feedDescriptor>
>   </body>
> </document>
>
> Nothing is said in the webpage about filename extension or format. I'm
>  assuming it has to be a xdoc document with .xml extension. The file lives
>  in the xdocs directory of my project (i.e.
>  src/documentation/content/xdocs)
>
This was wrong. The file has not xdoc format. Simply

<feedDescriptor>
   <feed id="BBCSport_UK">
  <url>http://news.bbc.co.uk/rss/sportonline_uk_edition/front_page/rss.xml</url>
</feed>
</feedDescriptor>

in a file named feedDescriptor.xml works.

Vicent
::

        Share what you know, learn what you don't



signature.asc (205 bytes) Download Attachment

Re: problem with feeder plugin

by rgardler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

2009/11/2 Vicent Mas <uvemas@...>:

...

> This was wrong. The file has not xdoc format. Simply
>
> <feedDescriptor>
>   <feed id="BBCSport_UK">
>  <url>http://news.bbc.co.uk/rss/sportonline_uk_edition/front_page/rss.xml</url>
> </feed>
> </feedDescriptor>
>
> in a file named feedDescriptor.xml works.


You mean exactly as documented in
http://forrest.apache.org/pluginDocs/plugins_0_80/org.apache.forrest.plugin.input.feeder/samples/singleFeed.html
(which you linked to)

Thanks for following up onlist, this makes it easier for those coming
after you. Clearly the documentation is not very clear, if you can
provide a patch for the plugins documentation that would be very much
appreciated.

Ross

Re: problem with feeder plugin

by Vicent Mas-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

> 2009/11/2 Vicent Mas <uvemas@...>:

>
> ...
>
> > This was wrong. The file has not xdoc format. Simply
> >
> > <feedDescriptor>
> >   <feed id="BBCSport_UK">
> >  <url>http://news.bbc.co.uk/rss/sportonline_uk_edition/front_page/rss.xml
> ></url> </feed>
> > </feedDescriptor>
> >
> > in a file named feedDescriptor.xml works.
>
> You mean exactly as documented in
> http://forrest.apache.org/pluginDocs/plugins_0_80/org.apache.forrest.plugin
> .input.feeder/samples/singleFeed.html (which you linked to)
>
Yes, the key word is *exactly* :-)

> Thanks for following up onlist, this makes it easier for those coming
> after you. Clearly the documentation is not very clear, if you can
> provide a patch for the plugins documentation that would be very much
> appreciated.
>
> Ross
>

Well, I cannot do it for the pluginS but I can for the feeder plugin :-). When
doing it I've realized that in page

http://forrest.apache.org/pluginDocs/plugins_0_90/index.html

most of plugin links (including the feeder plugin) are pointing to 0_80 docs.
I've done a patch for the current revision of trunk, r832303. The patch has to
be applied to feeder_dir/src/documentation/content/xdocs/index.xml

I also dowloaded the current official release tarball for linux but I cannot find
the plugin sources there. So I've not pached it for the 0.80 version.

Vicent
::

        Share what you know, learn what you don't


[index_patch]

--- index.xml 2009-11-03 08:27:20.000000000 +0100
+++ index_new.xml 2009-11-03 08:49:14.000000000 +0100
@@ -53,6 +53,13 @@
         </feedDescriptor>
             ]]>
             </source>
+
+            <p>
+              Note that the <code>feedDescriptor</code> file has <strong>not</strong>
+              xdoc format. A file named <code>feedDescriptor.xml</code> with exactly the
+              above content should just work.
+            </p>
+
             <p>
               In order to embed the data from the <code>planetApache</code> feed you
               create a link in the following form:
@@ -66,9 +73,9 @@
               want the feed to be delivered in (i.e. html, pdf etc.)
             </p>
           <ul>
-            <li><a href="samples/singleFeed.rss">As RSS</a></li>
-            <li><a href="samples/singleFeed.rss.xml">As XDoc</a></li>
-            <li><a href="samples/singleFeed.rss.html">As HTML</a></li>
+            <li><a href="samples/singleFeed.rss">As RSS</a> (no EXTENSION)</li>
+            <li><a href="samples/singleFeed.rss.xml">As XDoc</a> (xml EXTENSION)</li>
+            <li><a href="samples/singleFeed.rss.html">As HTML</a> (html EXTENSION)</li>
           </ul>
         </section>
       </section>



signature.asc (205 bytes) Download Attachment

Re: problem with feeder plugin

by rgardler :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

2009/11/3 Vicent Mas <uvemas@...>:
>> 2009/11/2 Vicent Mas <uvemas@...>:

...

> I've done a patch for the current revision of trunk, r832303. The patch has to
> be applied to feeder_dir/src/documentation/content/xdocs/index.xml
>
> I also dowloaded the current official release tarball for linux but I cannot find
> the plugin sources there. So I've not pached it for the 0.80 version.

Excellent - thank you so much.

Can you please attach your patch to an issue at
https://issues.apache.org/jira/browse/FOR

The reason is so that it does not get lost in mail (I've not got a
checkout on this machine and will not be back in the office for a week
- others may not pick it up).

The other reason is so that we can do proper tracking of your
contribution and ensure you are correctly credited.

Thanks again for you contributions - they are very much appreciated.

Ross

Re: problem with feeder plugin

by David Crossley :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Vicent Mas wrote:

> > Vicent Mas wrote:
> >
> > Thanks for following up onlist, this makes it easier for those coming
> > after you. Clearly the documentation is not very clear, if you can
> > provide a patch for the plugins documentation that would be very much
> > appreciated.
>
> Well, I cannot do it for the pluginS but I can for the feeder plugin :-). When
> doing it I've realized that in page
>
> http://forrest.apache.org/pluginDocs/plugins_0_90/index.html

That is a generated page.

> most of plugin links (including the feeder plugin) are pointing to 0_80 docs.

Yes, only plugins that require 0.9-dev (trunk) functionality are
deployed to the 0_90 space. Otherwise the 0_80 will work
with both.

See the "forrestVersion" attribute in
$FORREST_HOME/plugins/plugins.xml
$FORREST_HOME/whiteboard/plugins/whiteboard-plugins.xml
which is reflected in "Minimum Forrest version required" rows
in the table at http://forrest.apache.org/pluginDocs/plugins_0_90/

> I've done a patch for the current revision of trunk, r832303. The patch has to
> be applied to feeder_dir/src/documentation/content/xdocs/index.xml
>
> I also dowloaded the current official release tarball for linux but I cannot find
> the plugin sources there. So I've not pached it for the 0.80 version.

That is because code for all plugins is in the SVN trunk,
and installations based on releases will download the plugins from
apache.org as required.

So you did patch the correct source. When the changes are applied
and the plugin "deployed", then that will update the plugin docs
at the 0_80 space (as explained above).

-David