Profound API CI/CD

Use this board to ask questions or have discussions with other Profound.js users.
pgauthier
New User
Posts: 2
Joined: Mon Jul 19, 2021 8:39 am
First Name: Paul
Last Name: Gauthier
Company Name: ICG
Phone: 6152135542
Address 1: 1 Ingram Blvd
City: La Vergne
State / Province: Tennessee
Zip / Postal Code: 37086
Country: United States
Contact:

Profound API CI/CD

Post by pgauthier »

Are there any established/tested patterns for implementing an automated approach to deploying and promoting changes to Profound APIs? Ideally, we want to avoid anti-patterns like copy/paste deployment. We have the git-based source control piece of the equation working. Now, we'd like to be able to automate the move of changes to a pre-prod environment on the dev LPAR and promote those same changes to our production LPAR, once they have been tested and approved. We'll be using Azure DevOps, but it can pretty much do anything that another CI/CD tool can do.

We can obviously start by just trying to automate manual activities, but I was curious if others have been down this road and might have any guidance to share.

Thanks for any advice you can offer.
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Profound API CI/CD

Post by Scott Klement »

Hi!

Currently Profound API does not automatically detect changes to the code. So if you use Git to pull the deploy the latest changes to your box, you'll need to restart the server to make it reload the files. This can all be automated into your CD script -- after it pulls the changes to the server, it can just stop/start the Profound API server, and you'll be running with the updated code.

With standard Profound.js code, however, it will detect those code changes and automatically reload the code. We will consider adding the same functionality to Profound API to make this easier.

There's also a special feature that not too many customers use that can turn off the auto-reload of the changed files. This is called the --optimize feature, and is only used in very high-volume scenarios. If you are using that, there's no help for it, you'll always need to restart the server.

Aside from that, its no different than any other CI/CD scenario.
pgauthier
New User
Posts: 2
Joined: Mon Jul 19, 2021 8:39 am
First Name: Paul
Last Name: Gauthier
Company Name: ICG
Phone: 6152135542
Address 1: 1 Ingram Blvd
City: La Vergne
State / Province: Tennessee
Zip / Postal Code: 37086
Country: United States
Contact:

Re: Profound API CI/CD

Post by pgauthier »

Thanks Scott!

I was thinking more along of the lines of:

- Code stored in a git repo
- Dev creates feature branch and makes changes
- Dev creates pull request from feature branch to master
- Merge of PR triggers identification of changed objects and deployment of those changed objects to non-prod
- After code is tested, the same changed objects are promoted to production

In this case, the actual deploy would probably be FTP or something like that, unless you have another mechanism to accomplish this. Also, because we'd be pushing the new files, I'd expect that Profound would detect the change and a server restart would not be needed.

Thanks again for your help.
Scott Klement
Experienced User
Posts: 2711
Joined: Wed Aug 01, 2012 8:58 am
First Name: Scott
Last Name: Klement
Company Name: Profound Logic
City: Milwaukee
State / Province: Wisconsin

Re: Profound API CI/CD

Post by Scott Klement »

Unfortunately, as I said earlier, Profound API will not detect the changes to the files.

When your CD process deploys the changed objects to the "non-prod" environment, the script could be updated to restart the server. That way your non-prod would pick up the changes.

For the additional process to send to the production server -- this is your own script, so I don't know anything about how it works. But. in any case Profound API won't pick up the changes unless you do something to trigger them. You could go into the IDE and reload them by hand, or restart the server to make it pick up the changes, but they won't happen automatically.

We'll look into detecting these changes in future releases.
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests