This blog will be updated regularly with technical articles which should give you a little bit of insight in what we do at Modelit. The articles will focus on Modelit's activities to integrate Matlab with Java to build better desktop applications with rich interfaces and functionality not provided by standard Matlab. And also on the possibilities to integrate Matlab with Javascript to make it possible to use Matlab in Web Applications, for example in combination with frameworks such as React, Dojo and Angular and to use Matlab as a service in environments such as Docker. We love to hear from you so don't hesitate to contact us with comments, questions or topics you'd like to see on this blog.
The Modelit Embedded HTTP server for Matlab can be set up as an HTTPS server. This HTTPS server has the same functionality as the normal HTTP server. But has the advantage that it can be used to secure incoming and outgoing requests. This is useful when sensitive information is sent and received, or when the server needs to be protected with authentication.
To set up an HTTPS server, you’ll need an SSL certificate. You can use a free service, e.g. "Let’s Encrypt", or create a self-signed certificate using OpenSSL tool, or Java’s "keytool". In this article we will show how you can configure the Embedded Server with a self signed certificate generated by using the Java "keytool".
The Modelit Embedded Webserver Toolbox for Matlab makes it possible to use Matlab as an HTTP server. But it also contains methods to send HTTP requests, these methods are similar to the Matlab webread function. But the methods in the toolbox offer some extras.
One of these extras is to monitor the progress of a running HTTP request. In case a request takes a long time the user can be informed about the progress which will improve the overall user experience.
The Modelit Webserver Toolbox for Matlab makes it possible to use Matlab as an HTTP server. But it also contains methods to send HTTP requests. One of the advantages of using this toolbox is that Http requests can be sent asynchronously.
In this way the Matlab thread is not blocked and one can use fact that most servers can process multiple requests simultaneously. Modelit uses this for example in the MapViewer in which multiple map tiles are loaded simultaneously from an external server without blocking the Matlab application.
NodeJS is an open-source server environment. When installed NodeJS makes it possible to run JavaScript code outside a web browser. NodeJS is frequently used as the back-end of a webapp. In which complicated tasks can be executed. A popular framework to use NodeJS as the back-end of a webapp is Express.js. And in this article we will show how you can call Matlab from within a NodeJS express webserver.