Scramjet Transform Hub Release 0.17

This is a small but important release that allows brings the Python runner nearly up to full functionality and an improvement to the client that allows calling Scramjet Transform Hub directly from the browser!

Python runner update

The Python runner now fully supports input and output data, stdio is well handled and well tested.

The new runner now supports:

  • Graceful stop - running si inst stop on a python instance no longer kills the sequence unconditionally
  • Health monitoring - now you can expose data for si inst health from Python!
  • Event handling - si inst event and similar operations will now allow event handling and messaging
  • Dependencies handling - now sequences can use proper PYTHONPATH dependency resolution.

So drop your index.py in your favorite flavor of vi and paste this:

from scramjet.streams import Stream def run(context, input): return Stream.read_from(input).map(lambda s: f"Hello {s}!")

We need to allow Python to work without Scramjet Framework, but this will come in an upcoming release.

Browser client

Previously the Scramjet API Client would work only from node.js. The main reason for this was using node-fetch as one of the dependencies. We do believe it's a fantastic module and one that should be included in the base Node API long time ago. Since we do want to support node.js 14 and 16 at least until the end of life we needed to find an alternative solution. We managed to find @sapphire-fetch - a simple way to support a proper W3C Fetch API without the hassle of having to deploy multiple modules.

Minor changes

  • Fixed identification failure when STH is started with existing sequences
  • New automated tests for Python runner have been added
  • API Docs improvements

Kubernetes!

I'm happy to announce that STH will gain a really important feature: you will be able to run stream processors on any Kubernetes cluster. We're working on proper documentation of how to start that up, but currently you will have access to the three execution adapters:

  • docker - the default for running sequences in a standard server space
  • process - the adapter running non-separated processes for simple deployments
  • kubernetes - for deployment in cloud environments and leverage multiple servers

The kubernetes adapter is expected to come early next week, so keep checking. :)

Photo by jggrz

Project co-financed by the European Union from the European Regional Development Fund under the Knowledge Education Development Program. The project is carried out as a part of the competition of the National for Research and Development: Szybka Ścieżka.

Author:

Michał Czapracki

Michał Czapracki

The CTO at Scramjet

JOIN OUR SCRAMJET CLOUD PLATFORM BETA PROGRAM

Get limited possibility to test our next generation 3-in-1 data processing platform! Be the first on our platform helping us shape the roadmap and having an influence on the product development.

JOIN BETA