trying to refactor a osmfilter-processor to do better work

hello dear openstreetmap experts

new to the gis-technique: i am workin with the following tools:

this

    http://wiki.openstreetmap.org/wiki/DE:Osmconvert

and that


    http://wiki.openstreetmap.org/wiki/DE:Osmfilter

i run the following example:


    wget download.geofabrik.de/openstreetmap/europe/germany.osm.pbf
    osmconvert germany.osm.pbf --all-to-nodes -o=germany.o5m
    osmfilter germany.o5m --keep="amenity=shop or shop=*" -o=shops.o5m
    osmconvert shops.o5m --csv="@id @lon @lat shop name" --csv-headline -o=shops.csv

that runs fine - now i want to refine:

to get such a result- [made out of xslt]



    <node id="52768810" lat="48.2044749" lon="11.3249434" version="7" changeset="9490517" user="wheelmap_visitor" uid="290680" timestamp="2013-10-07T20:24:46Z">
    <tag k="addr:city" v="Olching" />
    <tag k="addr:country" v="DE" />
    <tag k="addr:housenumber" v="72" />
    <tag k="addr:postcode" v="82140" />
    <tag k="addr:street" v="Hauptstraße" />
    <tag k="amenity" v="restaurant" />
    <tag k="cuisine" v="mexican" />
    <tag k="email" v="info@cantina-olching.de" />
    <tag k="name" v="La Cantina" />
    <tag k="opening_hours" v="Mo-Su 17:00-01:00" />
    <tag k="phone" v="+49 (8142) 444393" />
    <tag k="website" v="http://www.cantina-olching.com/" />
    <tag k="wheelchair" v="no" />


doable!?

See my response to your other similar post which applies equally here.
http://forums.opensuse.org/showthread.php/497008-trying-to-refactor-a-xlst-processor-to-do-better-work

By using something like logstash, instead of a proprietary or semi-proprietary approach to parsing and tagging your data, Logstash enables you to do this in JSON (not too different than straight XSL) but with more defined hierarchy, structure and clarity, particularly if you are interested in processing your data through a nosql database like Elasticsearch (or for that matter, solr on hadoop). Of course, if you still want to export your parsed, tagged and transformed data in another format, Logstash can do that for you, too.

HTH,
TSU