• Webinars
  • Docs
  • Download
  • Blogs
  • Contact Us
Try Free
Show / Hide Table of Contents

Create a NoSQL Database

This section will demonstrate how you can create a NoSQL database through the NCache Web Manager and PowerShell.

Note

NoSQL database supports only partitioned topologies and local (OutProc) caches.

Using NCache Web Manager

  • Launch NCache Web Manager by browsing to http://localhost:8251 or <server-ip>:8251 on Windows and Linux.

  • In the left navigation bar, click on Clustered Caches. This opens up the Clustered Caches page at <server-ip>:8251/ClusteredCaches/.

  • To create a new NoSQL database, click on New.

Create NoSQL Database Web

  • From the In-Memory Store Type dropdown menu, select NoSQL Database and specify the name of your cache. Click Next.
Note

NoSQL database supports JSON serialization only.

Create NoSQL Database Web

  • Select the caching topology and advanced options like Operation timeout and Statistic replication interval. Click Next.
Note

NoSQL database supports the Partitioned and Partition-Replica Topologies only.

Select Caching Topology Web

  • Specify the Cache Partition Size and add your cluster nodes by providing the Server Node IP or Host Name and clicking on +. To add more nodes, click +. Once all the required nodes are added, click Next.

Specify Size NoSQL Database Web

  • On the NoSQL database provider settings page you can choose from the NCache supported NoSQL database providers (NCache Persistence, Microsoft SQL Server, MongoDB). You can see the create new nosql database for using different providers. Here, we create NoSQL database with NCache Persistence.
Note

NCache Persistence requires a shared path that is accessible from all nodes. User Name, and Password are required if authentication is enabled on that file share.

  • Specify the NoSQL database provider settings with Create new database option selected. Provide the Database name if you have to change the default name Cache Name_db. From the Persistence Provider dropdown menu, select NCache Persistence. For NCache persistence settings, provide the UNC Path, User Name, and Password. Once done, click on Test Connection. If the connection to the NoSQL database provider is tested successfully, you will be prompted with a success notification. Click Next.
Warning

Unless the connection to the NoSQL database provider has been tested successfully, you can not proceed further with the cache creation process.

Verify Connection Web

  • Change the Cluster Port and Port Range if required. Enable pipelining for the cache if required by checking the Enable Pipelining checkbox. Set the Batch Interval (in microseconds) for the duration after which the commands will be transmitted over the network. Click Next.

Specify TCP Parameters for NoSQL Database Web

  • If you want to enable encryption and compression, check the Enable Encryption and Enable Compression checkboxes. If enabled, set the Providers and Key for encryption and Threshold Size for compression. Click Next.

Encryption and Compression for NoSQL Database Web

  • In the Advanced Options page, Eviction is disabled by default and can not be configured. You can choose to Start this cache on finish and Auto start this cache on service startup by checking corresponding checkboxes. This cache will start automatically after service restart if you check the Auto start this cache on service startup option.
Note

Eivction is not supported for NoSQL database.

Warning

The cache will not start on the node on which the NoSQL database provider is inaccessible.

Eviction for NoSQL Database Web

  • Click Finish to complete the process. Your created cache will appear in Clustered Caches page with the server nodes and their status and a success notification will be displayed in the notification panel.
Warning

If the database with the specified name already exists, you will be prompted with an error message.

Create NoSQL Database Web

Using PowerShell

You can also use the PowerShell to manage NoSQL database by using the NCache supported PowerShell cmdlets.

Create Cache

The New-Cache PowerShell cmdlet is responsible for creating new caches.

Note

NCache Persistence requires a shared path that is accessible from all nodes. User Name, and Password are required if authentication is enabled on that file share. You can also provide domain name along with user name as domain_name\user_name.

The following command creates a NoSQLDatabase named demoNoSqlCache with provider type NCachePersistence on the server nodes 20.200.20.40 and 20.200.20.39. New NCache Persistence database named no_sql_db is created on the path \\Fileserver\database\ using the provided connection string. The topology is PartitionedOfReplica and cache size is 1024MB.

Warning

The cache creation process will fail if the connection to the NoSQL database provider is unsuccessful.

New-Cache -Name demoNoSqlCache -Server "20.200.20.40,20.200.20.39" -InMemoryStoreType NoSQLDatabase -NoSQLDatabaseName "no_sql_db" -NoSQLProviderType NCachePersistence -NoSQLDatabaseConnectionString "\\Fileserver\database;domain_name\user_name;password" -NewDatabase -Topology PartitionedOfReplica -Size 1024

Start Cache

Start-Cache cmdlet enables the user to start the registered cache. If the server nodes are specified, the Cache process is started on the specified nodes.

Warning

The cache will not start on the node on which NoSQL database provider is inaccessible.

Perform this step on all server nodes to start the previously created demoNoSqlCache.

Start-Cache -Name demoNoSqlCache

See Also

Create New NoSQL Database
Add Local Remote Clients
NCache Programmer's Guide
NCache PowerShell Guide

Back to top Copyright © 2017 Alachisoft