Ejemplo n.º 1
0
    def test_fetcher_service_only(self):
        raise unittest.SkipTest('Timing out on EC2')
        """
        Use fetcher service to get a complete dataset, try to decode the message
        fields once we get it.
        """
        services = [
            {
                'name': 'fetcher',
                'module': 'ion.services.sa.fetcher',
                'class': 'FetcherService'
            },
        ]

        sup = yield self._spawn_processes(services)

        fc = FetcherClient(proc=sup)
        dset = yield fc.get_dap_dataset(TEST_DSET)

        # decode fields as an integrity test
        dset['das'] = json.loads(dset['das'])
        dset['dds'] = json.loads(dset['dds'])
        dset['dods'] = base64.b64decode(dset['dods'])
        self.failUnlessEqual(dset['source_url'], TEST_DSET)
        self.failUnlessSubstring('COADSX', dset['das'])
        self.failUnlessSubstring('COADSY', dset['das'])
Ejemplo n.º 2
0
 def slc_init(self):
     """
     Service life cycle state. Initialize service here. Can use yields.
     @todo Create instances of clients here for later - fetcher, attr store, etc
     """
     logging.debug('Preservation coordinator SLC init')
     self.fc = FetcherClient(proc=self)
Ejemplo n.º 3
0
 def setUp(self):
     yield self._start_container()
     services = [
         {
             'name': 'fetcher',
             'module': 'ion.services.sa.fetcher',
             'class': 'FetcherService'
         },
     ]
     sup = yield self._spawn_processes(services)
     self.fc = FetcherClient(proc=sup)