1. Home
  2. Examples
  3. Redis Remove Example

Redis Remove Example

In this example we work through how to remove a data cache using the specified key from a Redis Database inside Warewolf.

For more information on how to add data into the cache check out Redis Cache Example

Follow these simple steps below:

1.Click New to create a new workflow.

New Workflow

2. Search for the Redis Remove tool in the Tool Box.

Redis Remove Tool

3.Drag and drop the Redis Remove onto the design surface. The tool will open in large view.

Redis Remove Tool

4. From the Source, select the Source that you want to connect to. You will have created the source in the steps above or check out Adding a New Redis Source

In this example we connect to an Example Redis Source.

Select Redis Source

5. Once you have selected your Source, enter the Key.
Enter Redis Remove Key

6. Enter [[Result]] into the Result.

Enter the Result variable

7. In the Variable list, mark it as output.

In the Variable list, mark it as output.

8. When you have configured the Redis Remove Tool, Click Done. It will now look like this:
Redis Remove Workflow

9. Click Save. Name your Workflow and save.

10. Execute the previous workflow we created with Redis Cache to write data into the key.

11. Once you have done that, come back to your Redis Remove workflow and execute.

You will see the following the outputs.

The [[Result]] variable returned Success which means the key was removed from the Redis Database.

Redis Remove Output from first execution

12. Execute the workflow again. The [[Result]] variable returned Failure which means the key did not exist in the Redis Database

Redis Remove output from 2nd execution

 

 

FacebookTwitterLinkedInGoogle+Email
Updated on July 6, 2020

Was this article helpful?

Related Articles

Enjoying Warewolf?

Write a review on G2 Crowd
Stars