Twisted Python bridge from Unidata LDM (pqact).
Python
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
examples
pyldm
testdata
.gitignore
README
README.md
license.txt
release.py
setup.cfg
setup.py

README.md

pyLDM

This is a collection of Twisted Python code that connects you to LDM. At this time, the only available interface is an asynchronos PIPE to pqact. Here is an example pqact.conf entry.

IDS "/pTOR"
    PIPE python myingestor.py

and the associated myingestor file

from pyldm import ldmbridge
from twisted.internet import reactor

class MyIngestor(ldmbridge.LDMProductReceiver):
    def process_data(self, data):
        print 'I got product', data
    def connectionLost(self, reason):
        # Exit this program when pqact closes the STDIN PIPE
        reactor.stop()
        
ingest = MyIngestor()
ldm = ldmbridge.LDMProductFactory(ingest)
reactor.run()

The myingestor.py python script will keep running as long as pqact keeps the PIPE open to the process!