Scala + PHP Project

Has anyone joined a php project using Scala? One of my projects at work is a help desk written in php, I still sometimes develop this project, but I would like to make some functions in Scala. I wonder if this is possible.

thanks

+6
source share
2 answers

You can use Quercus / Bianca .

This really works, I performed some selenium tests in a PHP application in a berth container. Mysql PDO uses JDBC drivers (faster).

You can easily call Java / Scala from PHP: http://www.caucho.com/resin-3.1/doc/quercus.xtp#CallingJavaMethods , the runtime is faster than the standard PHP runtime, and you can publish your application to WAR (sometimes it's better than just sources).

If you plan to industrialize some PHP applications, IMO is a good start.

(Example: https://github.com/un-jon/Code-review-Quercus/tree/democode/helloworld )

+13
source

The only true connections between two different programming languages โ€‹โ€‹are ABI or programming language bindings.

ABI and programming language bindings are low-level conventions regarding how a function or class defined in C can be accessed in PHP, for example.


Another connection between two different applications written in two different programming languages โ€‹โ€‹can be an API , which is a set of functions of one application (or both) that can be called via RPC .

Access to the open API can be obtained through a regular form, such as XML-RPC , SOAP , WSDL , etc., and can only access functions that the application developer decided to separate from the outside.

+2
source

Source: https://habr.com/ru/post/924993/


All Articles