RCAP 0.4 Released

The Common Alerting Protocol is a lightweight standard to facilitate
the distribution of alerting data. RCAP is an implementation of the
CAP in Ruby. It allows for the creation of RCAP messages from Ruby
applications and the parsing of external messages.

RCAP currently supports only CAP Version 1.1.

0.4 - 6th March 2011

* Implemented Hash generation and parsing
* Implemented JSON generation and parsing
* Circle is now a subclass of Point

Farrel L.

On Sun, Mar 6, 2011 at 11:05 AM, Farrel L.
[email protected]wrote:

  • Implemented JSON generation and parsing
  • Circle is now a subclass of Point

This is rather fascinating. How exactly does the JSON generation and
parsing
work.
As I understand the CAP , it is an xml based protocol.
Does this simply do a xml to json conversion? I see in the api spec this
appears to be the case.
http://en.wikipedia.org/wiki/Common_Alerting_Protocol

Also, can this gem pull in xml data from other sources using cap and
repeat
it back to json?

Also, is this something you would want to put into a background process/
queue system?
In otherwords, how performant is it?

When you say this only supports version 1.1, how is that different from
version 1.0?
Is it worth supporting 1.0.

Thanks.

Respectfully,
Anderw McElroy

On 6 March 2011 19:40, andrew mcelroy [email protected] wrote:

Does this simply do a xml to json conversion? I see in the api spec this
appears to be the case.
http://en.wikipedia.org/wiki/Common_Alerting_Protocol

The JSON addition is purely for my own usage. I read and parse the CAP
message and store it in an internal collection of Ruby objects from
that I can generate out a JSON or XML representation.

Also, can this gem pull in xml data from other sources using cap and repeat
it back to json?

If the source is 1.1 compliant it should not be a problem.

Also, is this something you would want to put into a background process/
queue system?
In otherwords, how performant is it?

I have not done any performance testing. I am using REXML which is not
the fastest XML API out there. I am planning on a migration to
Nokogiri in the future.

When you say this only supports version 1.1, how is that different from
version 1.0?
Is it worth supporting 1.0.

The differences were not major as far as I can recall. I’m planning on
adding support for CAP 1.2 first before I add in support for 1.0.

Farrel

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs