This post is to show how easy it is to migrate to different infrastructure with Djuno. It’s so easy, that even a business person like myself can do it. In fact, the process of actually doing it won’t take any more time and effort than reading this post. Definitely less than writing this post… 😉
Here are the steps:
Make sure your services are running in Global Mode.
Create new nodes on the new infrastructure of your choice (on or off premise servers, any private or public cloud).
Delete the nodes on the old infrastructure that you don’t want to use anymore.
That’s it! Enjoy the live, on-the-fly, near zero downtime, near zero cost migration with Djuno!
Currently the main use cases include Web Development and Mobile Development (React Native, Ionic).
It is a general-purpose language used on the backend of web applications. Because of its simplicity, flexibility, versatility, and other useful features, Python is growing and becoming one of the most popular programming languages around.
5. Server Load
6. Rich Interfaces
7. Extended Functionality
9. Less Overhead
Data science is a field in which specialists analyse and manipulate raw or structured data. Data scientists usually use several programming languages together (one of them being Python).
It offers visualization with its D3.js, Plotly.js, and other libraries. By using them, it is easier to create impressive data visualization and dashboards.
People interested in machine learning, data science, and neural networks should consider learning Python.
Kanboard (https://kanboard.org/) – I love it! It’s a free, Open Source, professional and easy to use project management software with a clean and readable code. Thank You Dear Contributors! I use it both for managing my own projects and as a code base for creating new solutions.
Today I planned to add some extra fields to subtasks of the Kanboard service that is used for the VCfund.me project we’re currently working on. We’re using the Kanboard APIs to populate data in boards, tasks and subtasks.
So, we have two steps:
– Add fields to DB and make Kanboard to view this fields
– Change the `createSubtask` method of API to fill this new column
Adding field into DB:
Kanboard can use several types of relational DBs. We are using SQLite because it’s easy and lightweight. So, follow these steps to add a field to `subtasks` table:
– Login to Kanboard as admin
– Go to setting: http://<YOUR_KANBOARD_ROOT>/?controller=ConfigController&action=index
– Click `Download the database` and save it
– Extract downloaded file
– Open the SQLite with a DB client (I use DBeaver)
– Run `ALTER TABLE subtasks ADD my_new_field TEXT(2000);`
– Now compress the SQLite file to a .gz file (Ex: gzip db.sqlite)
– Upload the compressed DB by clicking `Upload the database` in http://<YOUR_KANBOARD_ROOT>/?controller=ConfigController&action=index
Now the field is added to the subtask table. If you have any other RDBMS you can connect to it and alter the `subtasks` table to add you new field.
If you want to change the default schema of DB you should change this file: `app/Schema/Sqlite.php` . But we just wanted to add fields to the existing Kanboard.
View the new field in Subtasks:
Subtask view PHP file is in `app/Template/subtask/table.php`. add a new `<th>` in `<thead><tr>` and a new `<td>` in `<tbody>` like this:
<?= $subtask['image'] ?>
Now save the file and check the web page: http://<YOUR_KANBOARD_ROOT>/?controller=TaskViewController&action=show&task_id=<TASK_ID>&project_id=<PROJECT_ID>
Change `createSubtask` and `updateSubtask` methods of the API
A few month ago, there was a requirement to use some R lang code in production. Porting it to other languages (c#) was not only time consuming but not reliable to be used in production, because we were worried new code may generate different result. Here is my solution, hope it helps you as it did help me.
#plumberapi #rlanguage #dockerfile
imagine you have an peice of code developed by your data scientist/ Mathematician/Statistician or whoever else that is happy to work with R, now your devs are required to plug in that peice of code to your project. i do not need to imagine it cuz it happened for me and this is how i solved it
lets start from creating a folder for this project
$ mkdir exposemyRcodeasAPI
$ cd exposemyRcodeasAPI/
now everything should be fine, you can dockerise your code and ship it anywhere you want
$ touch Dockerfile
append following lines
#to install packages uncoment following line
#RUN R -e "install.packages('whatever it is used in the code')"
#for apt-get uncomment & modify following line
#RUN apt-get update -qq && apt-get install whatever is needed
#expose a port
#make a folder and copy your files
RUN mkdir /app
COPY funcs.R /app
COPY plumber.R /app
ENTRYPOINT ["R", "-e", "pr <- plumber::plumb('plumber.R'); pr$run(host='0.0.0.0', port=8000,swagger=TRUE)"]
build your docker and forward port 8000 from your container to any port you want on host