1 of 20
2 of 20
3 of 20
4 of 20
5 of 20
6 of 20
7 of 20
8 of 20
9 of 20
10 of 20
11 of 20
12 of 20
13 of 20
14 of 20
15 of 20
16 of 20
17 of 20
18 of 20
19 of 20
20 of 20

doc

Using Massive Redirect through Azion’s Marketplace

Overview

Massive Redirect is a serverless solution available at Azion’s Marketplace. This type of solution is mainly used for handling a massive quantity of domain redirects, such as domain migrations.

This solution permits you to control this domain redirection directly at the network’s edge, centralizing the management of several settings in one location. It also enables you to operate a variety of situations, such as CMS or e-commerce platform migration, website upgrades, and many other. No matter how many pages you have, you can configure all your redirects with the Massive Redirect solution.

Important: you have to observe the limit of 300kb for the JSON file.


1. Getting the solution
2. Using the solution
3. Configuring the Massive Redirect solution to be used with an Edge Application
4. Instantiating the Massive Redirect Edge Application
5. Defining the execution criteria and behavior at Rules Engine\


1. Getting the solution

To use the Massive Redirect solution provided by Azion’s Marketplace, you have to:

  1. Log in to your Real-Time Manager (RTM) account.
  2. On the upper-left corner of the page, select Products Menu > Marketplace.
  3. Select the search box and type “massive” or browse through the cards to find the Massive Redirect solution.
  4. Once you’ve found the Massive Redirect card, select it to go the solution page.
  5. On the solution page, look for the Subscribe for section on the bottom-right corner.
  6. Click the Get It Now button.

You’ll see a message indicating that your solution was successfully installed and is ready to use.

2. Using the solution

Once you’ve gotten your solution on Marketplace, it’ll be available at your Edge Functions list. To use the Massive Redirect solution, you’ll have to create a new Edge Application to use with the solution.

To learn how to create an Edge Application, visit the documentation on getting started. You can also create an Edge Application through RTM > Products Menu > Edge Application and follow the instructions.

3. Configuring the Massive Redirect solution to be used with an Edge Application

To configure your solution, proceed as follow:

  1. On upper-left corner, select Products Menu > Edge Applications.
  2. On the listing page of your Edge Applications, select the one you’ve created to use with the Massive Redirect solution.
  3. On the application page, on the Main Settings tab, locate the Edge Functions switch and turn it on.
  4. Click the Save button on the bottom-right corner.

You’ll receive a successful message indicating your Edge Application was updated. The use of Edge Functions is now enabled for your application.

4. Instantiating the Massive Redirect Edge Application

To enable this function:

  1. Select the Functions tab on the top list.
  2. Click the Add Function button.
  3. Choose a significant name for your function; it’ll be easier to remember it afterward.
  4. On the dropdown function menu, select the Massive Redirect [Global] function.

This will load the function, showing a box with the code of the function and two tabs: Code and Args.

If you click on the Code tab, you can navigate through the code to become familiar with how the code works, but you can’t change anything. The configuration of your Massive Redirect function will be made on the Args tab.

Click on the Args tab to open the code box for the Args where you’ll add the parameters to execute your application.

Note that you have several sections on the Args tab. This happens because you can configure several different redirections at the same time.

In the Args tab you have four keys to configure:

  1. from: this is where you’ll pass the previous URL, the one you want to redirect to a new one.
  2. moved: this is where you’ll pass the new URL, the one you want to be the target of your redirect rule. This URL will be used as a permanent redirect to the previous URL.
  3. from_regex: this option permits you to pass multiple redirections in one command, passing more than one address in one line.
  4. found: this is the same as moved, but in this case you have a temporary redirect to a URL.

Important: if you forgot to pass either the moved and/or found keys in the Args tab you’ll receive an error message with the code JA001.

Tip: you can find examples on how to configure your redirections on the example file provided at the Args tab.

5. Defining the execution criteria and behavior at Rules Engine

To instantiate and use your Massive Redirect solution, you have to create the condition needed to be met before the redirection occurs. You can leave the default criteria or configure your own criteria.

To do this, select the Rules Engine tab and proceed as follow:

  1. Add a new rule by clicking on the New Rule button and then selecting the Request Phase.
  2. Set a criteria for checking your domain. You’ll have something like if: ${domain} is equal xpto.com.
  3. On the behavior section, on Then, select Run a Function from the first dropdown menu and the Massive Redirect function from the second dropdown menu.

It’s important to notice that the function presented to you at the second dropdown menu will have the same name as the one you set at the instantiating section.

  1. Click the Save button on the lower-right corner.

You’ll see a successful message informing you that your Rules Engine was saved.


To get more information and detailed reference, you can read the Configuring the Massive Redirect function for Domain Migration documentation.


Didn’t find what you were looking for? Open a support ticket.