Creating a View for Isolated Data

Create a view that uses one or more isolation keys to filter on specific data for queries or visualizations.

If you have object groups that use isolation keys (formerly called partition keys) to separate the indexed data for an object group into different slices, the Refinery views that you create can use those isolation keys to control the visibility of data for the view. Scoping the view to one or more isolation keys also offers a performance advantage for the users who query within that isolation slice, by eliminating work to scan any data associated with all other isolation slices.

To create a view with an isolation key visibility rule:

  1. Follow the standard instructions to create a view. Go to Refinery and then click Create View.
  2. Select the object group in the left frame, then click Next.
  1. In the Schema Transformation window, scroll to the cs_partition_key_0 column and click the filter icon on the right.


NOTE: You could use cs_partition_key, or a different column, to isolate data.

cs_partition_key_# is created by ChaosSearch during indexing when an object group is configured with an isolation key rule. The isolation key is based on values derived from a cloud-storage pathname regex. In some cases, the isolation keys are values or strings that are only used within file pathnames to organize files, and so the cs_partition_key_# field and column contains those isolation key values for use with views, queries, and visualizations. Sometimes the isolation keys are also values that can be found in a column inside the indexed data, and in that event, you could use the more familiar column as the isolation specifier for the view. See Using an Alternate View Column as the Isolation Key later in this topic.

  1. The Configure Filter window opens. You can specify an isolation key by using one of two methods:
  • You can type an isolation value defined in the object group into the Insert Filter field and click Create.
  • You can select Use isolation keys and the system displays a list of the available isolation keys. Select a key that you want to use for the view, and then click Create to save the setting.

NOTE: You can repeat this step to select more than one isolation key for a view if desired.

  1. The Schema Transformation window updates to show the selected isolation key value(s) for the ca_partition_key_0 field, as in the following example:
  1. Click Save Transform in the top right to save and close the window.
  2. Click Next in the Schema Transformation window and complete the view creation using the standard steps.

Users who have access to the view see only the indexed data related to the isolation key(s) that you specified. A sample Search Analytics > Discover window for a view that shows the ap-northeast-1 data follows:


Using an Alternate View Column as the Isolation Key

The cs_partition_key_# field is a custom field added to the object group to hold the isolation keys that are discovered using the cloud-storage pathname regex. The key values themselves might, or might not, be values found in the indexed data for the object group.

In most cases, but especially when the isolation key names are not values found inside a column of the indexed data, you use the cs_partition_key_# column to configure the isolation rules for the views of the object group, as shown in the steps earlier in this topic.

However, if your indexed data has a column that contains the identical isolation key values found in the cs_partition_key column, you could -- as an alternative to cs_partition_key -- use the more familiar column to configure the view data visibility. Sometimes the alternative column might have a more meaningful and recognizable name, and be easier to use for filtering and configuration.

For example, the object group in this example has isolation keys that are based on region values like ap-northeast-1 and ap-northeast-2 and so on. These are the values stored in cs_partition_key_0 for this view. In this example, the same isolation key values are also stored in the Records.awsRegion column. If Records.awsRegion is a more familiar column for your users, you can follow almost the same steps to configure your isolation rules using Records.awsRegion instead of cs_partition_key.

To use an alternate column for configuring isolation in a view:

  1. When you create the view, in the Schema Transformation window, scroll to the alternate column that you want to use, such as Records.awsRegion, and click the gear (Transform) icon on the right. The Schema Transformation window opens.

2.Click the Select Transformation list.

  1. Select the Treat as Isolation Key option to configure this column as an isolation key column.
  2. Optionally, verify that 0 is the correct number at the end of your cs_partition_key_# field. It is most likely 0, but it could be a different number in some cases.
  3. Click Save Transform. The Schema Transformation window closes and the main Schema Transformation window appears.
  4. Click the filter icon for your column (Records.awsRegion), to open the Filter window. Notice that the Filter window is for Records.awsRegion, and the drop-down list includes the same isolation key values as in cs_partition_key_#. (If the values of this column do not match the keys used in cs_partition_key_#, the alternate column will not work for isolation.)
  1. Select the one or more isolation key values, as in the earlier steps, to specify the isolation key(s) to use for this view, and click Create.

The Schema Transformation window updates to show the configuration for the Records.awsRegion column to be treated as an isolation key, and the filter for the ap-northeast-1 keys.

  1. Click Next and complete the steps to save the view.

In this example, the view is limited to only the indexed data associated with the specified ap-northeast-1 key selected for the Records.awsRegion column. This configuration is identical to the effect using the cs_partition_key_0 field.