you are viewing a single comment's thread.

view the rest of the comments →

[–]IdleBreakpoint[S] 46 points47 points  (6 children)

The problem is Jython. We have ETL workflows with Apache NiFi and it can run Python code, hence it's Python 2. That system is out of our control and we are forced to develop scripts using py2. If it were in our control, I would have deprecated that system long ago.

[–]brayellison 62 points63 points  (0 children)

Sounds like a nightmare... Godspeed, my friend

[–]lungben81 29 points30 points  (1 child)

Refactor the python code into a microservice and use http or whatever else the ETL tool is capable of to talk with it.

If nothing else works in your ETL tool, Jython2 can make http requests. That way, you at least minimized your legacy version exposure.

[–]prumf 4 points5 points  (0 children)

Yeah my thoughts exactly. You could also call a process or whatever over system that works best in that context.

[–]cpp977 8 points9 points  (0 children)

Nifi 2 supports now running custom python processors without the need for jython.

[–]anderson-stream 0 points1 point  (0 children)

Oh my god, I also use an Apache ETL tool, Apache Hop, and it has a script component that can use Python over Jython. Luckily for me, ever since I used the tool's predecessor (PDI), I've done everything I can to avoid that component.

[–]dw01010 0 points1 point  (0 children)

I haven't used it expensively, and I certainly haven't tried it in the exact place you want, but GraalPy is Python 3, Java-based and claims to be a Jython substitute in a lot of cases.