Skip to Content.
Sympa Menu

perfsonar-dev - Re: [pS-dev] r1585

Subject: perfsonar development work

List archive

Re: [pS-dev] r1585


Chronological Thread 
  • From: Roman Lapacz <>
  • To:
  • Cc:
  • Subject: Re: [pS-dev] r1585
  • Date: Thu, 31 Aug 2006 14:53:25 +0200


wrote:
Hi all, Roman,
Hi

I guess this update was exactly what the SQL MA was needing. We made some modifications to the SQL MA so it could store/fetch OWAMP data. Roughly, the following steps were taken:

1. Create the ibatis map, sql database and database access files.
2. Modification of the eventType-map.xml file, adding two new classes to represent OWAMP data, namely OwampQueryGenerator and OwampResponseGenerator.
3. Added a storeOwamp function to SQLStorageManager
4. Modification of the SQLMAServiceEngine so it could call the appropriate store function (this diff can be at the end of the file)
5. Changed the startTime and endTime parameters in the fetch function of SQLStorageManager to type Long so it could use unix type time values (used by the CLMP tools)

We realize this was not the best way to make it work, but we needed it to be done in 2 days hehe. If you could please tell us what has changed with this new update in relation with what we need to make it work for OWAMP data (and I hope this update makes it generic enough so we dont have to do this many steps for al l the different types of data).


Take a look at src/org/perfsonar/service/measurementArchive/sqlType/store/. There are classes for utilization and L2 path status which take data from the request and put them in ibatis map structure. For example UtilizationStoreRequestProcess class has one method (invoked for each datum) which moves data from datum into ibatis map. In your case all you have to do is to implement such class for your datum elements and put the name of this class in conf/eventType-map.xml (storeRequestProcess element).

btw. I will change startTime and endTime to long type.


And between, is there an easy way to update the eXist database dinamically within execution time? Couldn't quite understand the ant process that did this (I tried setting static uri and src to the xmldb-store target and it gave me an exception).

You can use Ant script but you can also directly use client application from eXist

http://exist.sourceforge.net/client.html#N1027E

Roman




Guilherme Fernandes

--

diff SQLTypeMAServiceEngine.java SQLTypeMAServiceEngineOrig.java
15d14
< import org.ggf.ns.nmwg.base.v2_0.EventType;
149,150c148,149
< logger.debug("SQLTypeMAServiceEngine.storeData: start method");
< logger.debug("SQLTypeMAServiceEngine.storeData: mensagem: "+request);
---
//logger.debug("SQLTypeMAServiceEngine.storeData: start method");

166a166

186,194c186,188
< EventType event = meta.getEventType();
< if (event != null)
< if (event.getEventType().equals("owamp"))
< sqlStorageManager.storeOwamp(msg);
< else
< sqlStorageManager.store(msg);
< else
< sqlStorageManager.store(msg);
<
---

sqlStorageManager.store(msg);




----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.




--

// PSNC, Poland
// phone: (+48 61) 858 20 24
// http://www.man.poznan.pl




Archive powered by MHonArc 2.6.16.

Top of Page