> ## Documentation Index
> Fetch the complete documentation index at: https://doc.lucidworks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Solr Pro

> The Solr Pro connector pulls documents from an external standalone Apache Solr instance or Apache SolrCloud cluster using Solr's javabin response type and streaming response parser.

export const schema = {
  "type": "object",
  "title": "Solr Pro",
  "description": "The Solr Connector for indexing document from external solr clusters.",
  "required": ["id", "properties", "pipeline"],
  "properties": {
    "parserId": {
      "type": "string",
      "title": "Parser ID",
      "description": "Override and hide the parser ID for this connector",
      "hints": ["readonly", "hidden"]
    },
    "id": {
      "type": "string",
      "title": "Configuration ID",
      "description": "A unique identifier for this Configuration.",
      "minLength": 1,
      "pattern": "^[a-zA-Z0-9_-]+$"
    },
    "pipeline": {
      "type": "string",
      "title": "Pipeline ID",
      "description": "Name of the IndexPipeline used for processing output.",
      "minLength": 1,
      "pattern": "^[a-zA-Z0-9_-]+$"
    },
    "description": {
      "type": "string",
      "title": "Description",
      "description": "Optional description",
      "hints": ["lengthy"],
      "maxLength": 125
    },
    "modified": {
      "type": "string",
      "title": "Date Modified",
      "description": "The date at which this Configuration was last modified.",
      "hints": ["readonly", "hidden"]
    },
    "created": {
      "type": "string",
      "title": "Date Created",
      "description": "The date at which this Configuration was created.",
      "hints": ["readonly", "hidden"]
    },
    "type": {
      "type": "string",
      "title": "Type",
      "description": "A type ID for this connector.",
      "hints": ["readonly", "hidden"]
    },
    "collection": {
      "type": "string",
      "title": "Collection ID",
      "description": "The associated content Collection.",
      "hints": ["readonly", "hidden"],
      "minLength": 1,
      "pattern": "^[a-zA-Z0-9_-]+$"
    },
    "diagnosticLogging": {
      "type": "boolean",
      "title": "Diagnostic Logging",
      "description": "[Deprecated] Enables verbose diagnostic logging for troubleshooting. May increase log volume. Disabled by default.",
      "default": false
    },
    "type_description": {
      "type": "string",
      "title": "Type Description",
      "default": "The Solr Connector for indexing document from external solr clusters.",
      "hints": ["hidden", "readonly"]
    },
    "category": {
      "type": "string",
      "title": "Category",
      "default": "The Solr Connector for indexing document from external solr clusters.",
      "hints": ["hidden", "readonly"]
    },
    "connector": {
      "title": "Connector Type",
      "description": "Connector type.",
      "minLength": 1,
      "type": "string",
      "hints": ["hidden"]
    },
    "properties": {
      "type": "object",
      "title": "Solr Connector properties",
      "description": "Plugin specific properties.",
      "required": ["query", "connection", "advancedConnection", "advancedQuery"],
      "properties": {
        "connection": {
          "type": "object",
          "title": "Connection Settings",
          "description": "Configuration for connecting to Solr",
          "required": ["collection", "connectionType"],
          "properties": {
            "connectionType": {
              "type": "string",
              "title": "Connection Type",
              "description": "Type of Solr connection - SolrCloud (recommended) or Standalone",
              "enum": ["SOLRCLOUD", "STANDALONE"],
              "default": "SOLRCLOUD"
            },
            "zkHosts": {
              "type": "string",
              "title": "ZooKeeper Hosts",
              "description": "Comma-separated list of ZooKeeper hosts for SolrCloud (e.g., zk1:2181, zookeeper:2182, zk2:2181). Required for SolrCloud connections.",
              "maxLength": 1000
            },
            "solrUrl": {
              "type": "string",
              "title": "Solr Base URL",
              "description": "Base URL for standalone Solr instance (e.g., http://example.com:8983/solr/). Required for Standalone connections.",
              "maxLength": 500
            },
            "collection": {
              "type": "string",
              "title": "Collection Name",
              "description": "Name of the Solr collection/core to connect to",
              "maxLength": 100
            }
          }
        },
        "advancedConnection": {
          "type": "object",
          "title": "Advanced Connection Settings",
          "description": "Advanced configuration options for Solr connection",
          "required": [],
          "properties": {
            "connectionTimeoutMs": {
              "type": "number",
              "title": "Connection Timeout (ms)",
              "description": "Connection timeout in milliseconds",
              "default": 10000,
              "maximum": 300000,
              "exclusiveMaximum": false,
              "minimum": 1000,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "socketTimeoutMs": {
              "type": "number",
              "title": "Socket Timeout (ms)",
              "description": "Socket timeout in milliseconds",
              "default": 30000,
              "maximum": 600000,
              "exclusiveMaximum": false,
              "minimum": 1000,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "maxConnectionsPerHost": {
              "type": "number",
              "title": "Max Connections Per Host",
              "description": "Maximum number of HTTP connections per host",
              "default": 20,
              "maximum": 500,
              "exclusiveMaximum": false,
              "minimum": 1,
              "exclusiveMinimum": false,
              "multipleOf": 1
            }
          },
          "hints": ["advanced"]
        },
        "query": {
          "type": "object",
          "title": "Query Settings",
          "description": "Configuration for Solr queries and pagination",
          "required": ["requestHandler", "query"],
          "properties": {
            "query": {
              "type": "string",
              "title": "Query String",
              "description": "Solr query string to select documents (use '*:*' for all documents)",
              "default": "*:*",
              "maxLength": 2000
            },
            "filterQueries": {
              "type": "array",
              "title": "Filter Queries",
              "description": "List of filter queries to apply (fq parameters). Each filter query further restricts the result set.",
              "default": [],
              "items": {
                "type": "string",
                "maxLength": 1000
              }
            },
            "sort": {
              "type": "string",
              "title": "Sort Specification",
              "description": "Sort specification for result ordering. Supports multiple fields separated by commas. Examples: 'price desc', 'score desc, id asc', 'timestamp asc'. When using cursor mark pagination (default), connector automatically appends 'id asc' if not present.",
              "maxLength": 200
            },
            "fieldList": {
              "type": "string",
              "title": "Field List To Retrieve",
              "description": "Comma-separated list of fields to return. Leave EMPTY for all fields or specify fields like 'id,title,content'.",
              "maxLength": 2000
            },
            "requestHandler": {
              "type": "string",
              "title": "SOLR Request Handler",
              "description": "Solr request handler to use for queries",
              "default": "/select",
              "maxLength": 100
            },
            "batchSize": {
              "type": "number",
              "title": "Batch Size",
              "description": "Number of documents to fetch per request. Higher values improve performance but use more memory. Recommended: 500-1000",
              "default": 500,
              "maximum": 10000,
              "exclusiveMaximum": false,
              "minimum": 1,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "queryParser": {
              "type": "string",
              "title": "Query Parser",
              "description": "A specific query parser to use for the request (e.g., 'lucene', 'complexphrase', 'edismax'). When using relevance-based parsers such as edismax include 'score' in the Sort Specification to preserve relevance ranking (e.g., 'score desc').",
              "maxLength": 50
            }
          }
        },
        "advancedQuery": {
          "type": "object",
          "title": "Advanced Query Settings",
          "description": "Advanced configuration options for Solr queries",
          "required": [],
          "properties": {
            "queryTimeoutMs": {
              "type": "number",
              "title": "Query Timeout (ms)",
              "description": "Timeout for individual query requests in milliseconds. Default is 30 seconds for faster failure detection with retry logic.",
              "default": 30000,
              "maximum": 600000,
              "exclusiveMaximum": false,
              "minimum": 1000,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "useCursorMark": {
              "type": "boolean",
              "title": "Use Cursor Mark",
              "description": "Use cursor mark pagination for efficient deep paging (requires Solr 4.7+). Disable only if offset-based paging is specifically desired.",
              "default": true
            },
            "maxDocuments": {
              "type": "number",
              "title": "Maximum Documents",
              "description": "Maximum number of documents to process (0 = unlimited)",
              "default": 0,
              "maximum": 100000000,
              "exclusiveMaximum": false,
              "minimum": 0,
              "exclusiveMinimum": false,
              "multipleOf": 1
            }
          },
          "hints": ["advanced"]
        }
      }
    },
    "coreProperties": {
      "type": "object",
      "title": "Core Properties",
      "description": "Common behavior and performance settings.",
      "required": [],
      "properties": {
        "fetchSettings": {
          "type": "object",
          "title": "Fetch Settings",
          "description": "System level settings for controlling fetch behavior and performance.",
          "required": [],
          "properties": {
            "numFetchThreads": {
              "type": "number",
              "title": "Fetch Threads",
              "description": "Maximum number of fetch threads; defaults to 5.This setting controls the number of threads that call the Connectors fetch method.Higher values can, but not always, help with overall fetch performance.",
              "default": 5,
              "maximum": 500,
              "exclusiveMaximum": false,
              "minimum": 1,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "indexingThreads": {
              "type": "number",
              "title": "Index Subscription Threads",
              "description": "Maximum number of indexing threads; defaults to 4.This setting controls the number of threads in the indexing service used for processing content documents emitted by this datasource.Higher values can sometimes help with overall fetch performance.",
              "default": 4,
              "maximum": 10,
              "exclusiveMaximum": false,
              "minimum": 1,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "pluginInstances": {
              "type": "number",
              "title": "Number of plugin instances for distributed fetching",
              "description": "Maximum number of plugin instances for distributed fetching. Only specified number of plugin instanceswill do fetching. This is useful for distributing load between different instances.",
              "default": 0,
              "maximum": 500,
              "exclusiveMaximum": false,
              "minimum": 0,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "fetchItemQueueSize": {
              "type": "number",
              "title": "Fetch Item Queue Size",
              "description": "Size of the fetch item queue.Larger values result in increased memory usage, but potentially higher performance.Default is 10k.",
              "default": 10000,
              "hints": ["hidden"],
              "maximum": 500000,
              "exclusiveMaximum": false,
              "minimum": 1,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "fetchRequestCheckInterval": {
              "type": "number",
              "title": "Fetch request check interval(ms)",
              "description": "The amount of time to wait before check if a request is done",
              "default": 15000,
              "hints": ["hidden"],
              "maximum": 500000,
              "exclusiveMaximum": false,
              "minimum": 1000,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "fetchResponseScheduledTimeout": {
              "type": "number",
              "title": "Fetch response scheduled timeout(ms)",
              "description": "The maximum amount of time for a response to be scheduled. The task will be canceled if this setting is exceeded.",
              "default": 300000,
              "maximum": 500000,
              "exclusiveMaximum": false,
              "minimum": 1000,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "fetchResponseCompletedTimeout": {
              "type": "number",
              "title": "Fetch response completion timeout(ms)",
              "description": "The maximum amount of time for a response to be completed. If exceeded, the task will be retried if the job is still running",
              "default": 300000,
              "hints": ["hidden"],
              "maximum": 600000,
              "exclusiveMaximum": false,
              "minimum": 1,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "indexingInactivityTimeout": {
              "type": "number",
              "title": "Indexing inactivity timeout(seconds)",
              "description": "The maximum amount of time to wait for indexing results (in seconds). If exceeded, the job will fail with an indexing inactivity timeout.",
              "default": 86400,
              "maximum": 691200,
              "exclusiveMaximum": false,
              "minimum": 60,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "pluginInactivityTimeout": {
              "type": "number",
              "title": "Plugin inactivity timeout(seconds)",
              "description": "The maximum amount of time to wait for plugin activity (in seconds). If exceeded, the job will fail with a plugin inactivity timeout.",
              "default": 600,
              "maximum": 691200,
              "exclusiveMaximum": false,
              "minimum": 60,
              "exclusiveMinimum": false,
              "multipleOf": 1
            },
            "indexMetadata": {
              "type": "boolean",
              "title": "Index metadata",
              "description": "When enabled the metadata of skipped items will be indexed to the content collection.",
              "default": false
            },
            "indexContentFields": {
              "type": "boolean",
              "title": "Index content fields",
              "description": "When enabled, content fields will be indexed to the crawl-db collection.",
              "default": false
            },
            "asyncParsing": {
              "type": "boolean",
              "title": "Async Parsing",
              "description": "When enabled, content will be indexed asynchronously.",
              "default": false
            }
          }
        },
        "skipConfigValidation": {
          "type": "boolean",
          "title": "Skip Validation",
          "description": "Enable to skip configuration validation when it takes too long and causes timeout issue",
          "default": false
        }
      },
      "hints": ["advanced"]
    }
  },
  "category": "Repository",
  "categoryPriority": 1
};

export const SchemaParamFields = ({schema}) => {
  const sanitize = str => {
    if (typeof str !== "string") return str;
    return str.replace(/^"(.*)"$/s, "$1").replace(/\\/g, "").replace(/"/g, "'");
  };
  const formatDescription = str => {
    const s = sanitize(str);
    return (/[.!?]\)*$/).test(s) ? s : `${s}.`;
  };
  const {description, properties = {}, required: requiredProps = []} = schema;
  const visibleProps = useMemo(() => Object.entries(properties).filter(([, prop]) => !prop.hints?.includes("hidden")), [properties]);
  return <div>
      {description && <p>{formatDescription(description)}</p>}

      {visibleProps.map(([name, prop]) => {
    const isRequired = requiredProps.includes(name);
    const hasDefault = prop.default !== undefined;
    const rawDefault = prop.default;
    const isComplexDefault = hasDefault && (typeof rawDefault === "object" || typeof rawDefault === "string" && (rawDefault.length > 20 || rawDefault.includes('"')));
    const fieldProps = {
      key: name,
      body: prop.title || name,
      type: prop.type,
      ...prop.title && ({
        post: [<><span className="text-stone-400 dark:text-stone-500">API property: </span>{name}</>]
      }),
      ...isRequired && ({
        required: true
      }),
      ...!isComplexDefault && hasDefault ? {
        default: sanitize(String(rawDefault))
      } : {}
    };
    const isObject = prop.type === "object" && prop.properties;
    const isArrayOfObjects = prop.type === "array" && prop.items?.type === "object" && prop.items.properties;
    return <ParamField {...fieldProps}>
            {prop.description && <p>{formatDescription(prop.description)}</p>}

            {isComplexDefault && <div className="flex">
                <p>
                  <strong>Default:</strong>
                </p>
                <pre className="!my-0">
                  <code>
                    {JSON.stringify(rawDefault, null, 2)}
                  </code>
                </pre>
              </div>}

            {isArrayOfObjects && <div className="flex">
              <p>
                <strong>Object attributes:</strong>
              </p>
              <pre className="!my-0">
                <code>
                  {'{\n'}
                  {Object.entries(prop.items.properties).map(([iname, iprop]) => <>
                      {`  ${iname}`}
                      {prop.items?.required?.includes(iname) && <span style={{
      color: 'red'
    }}> required</span>}
                      {`: {\n    display name: ${sanitize(iprop.title || '')}\n    type: ${iprop.type}\n  }\n`}
                    </>)}
                  {'}'}
                </code>
              </pre>
              </div>}

            {isObject && <Expandable title="properties">
                <SchemaParamFields schema={{
      properties: prop.properties,
      required: prop.required
    }} />
              </Expandable>}
          </ParamField>;
  })}
    </div>;
};

export const LwTemplate = ({title = "Key questions to get you started", icon = "sparkles", cta = "Powered by Agent Studio", linkHref = "https://lucidworks.com/demo/?utm_source=docs&utm_medium=referral&utm_campaign=docs_cta_ai"}) => {
  const [isLoaded, setIsLoaded] = useState(false);
  useEffect(() => {
    const timer = setTimeout(() => {
      setIsLoaded(true);
    }, 500);
    return () => clearTimeout(timer);
  }, []);
  return <div className="lw-template-container">
      <Card title={title} icon={icon}>
        {isLoaded && <span dangerouslySetInnerHTML={{
    __html: `<lw-template id="a029c1a9-28be-427e-b0e1-5d918920246a"></lw-template
            >`
  }} />}
        <Link href={linkHref} className="agent-studio-link text-left text-gray-600 gap-2 dark:text-gray-400 text-sm font-medium flex flex-row items-center hover:text-primary dark:hover:text-primary-light group-hover:text-primary group-hover:dark:text-primary-light">Powered by Lucidworks Agent Studio</Link>
      </Card>
    </div>;
};

[localhost link]: http://localhost:3000/docs/fusion-connectors/connectors/solr-pro

[mintlify link]: https://doc.lucidworks.com/docs/fusion-connectors/connectors/solr-pro

<Callout icon="plug" color="#A4C6F7" iconType="solid">
  * **Latest version:** v1.0.1
  * **Compatible with Fusion version:** 5.9.0 and later
</Callout>

The Solr Pro connector reindexes content that is managed in an external Solr core or collection and make it searchable within Fusion.
Use this connector to migrate content from an external Solr instance to Fusion for a unified search across multiple Solr-based apps and to enable the use of Fusion's query pipelines and analytics on Solr-managed data.

Download this connector from the [V2 and Pro connectors download page](/docs/fusion-connectors/downloads/v2-connectors-downloads).

<Danger>
  The Solr Pro connector indexes content from external Solr collections into Fusion. It does **not** support indexing content from Fusion.
</Danger>

<LwTemplate />

## What are Pro connectors?

Pro connectors are built on the same framework as V2 connectors but meet higher internal standards for stability, reliability, and production readiness. If you’re currently using other V2 connectors, the process for installing and upgrading a Pro connector remains the same.

## Solr Pro connector features

The following Solr components and parameters can be configured:

* collection/core (also allows default/empty core)
* query (`*:*` by default)
* filter queries
* query parser
* request handler (defaults to `/select`)
* stored fields to retrieve

Also, since cursorMark deep paging should be used when possible:

* sort spec (default: `id asc`)

This connector can be configured to store information about datasources and the data ingested in a ConnectorDB crawldb instance.

## Comparison to the Solr V1 connector

The Solr Pro connector retains the functionality from the Solr V1 connector. Two new fields have been added:

`querytimeoutms` - the individual query timeout, set in milliseconds. The default value is 30000, or 30 seconds.

`useCursorMark` - Enable or disable the cursor mark, which is used for pagination. This field is enabled by default. If this field is not enabled, then offset pagination is used.

The existing fields and values in the V1 connector carry over to the Pro connector. Additionally, some advanced connection settings and fetch settings that were hard-coded into the V1 connector are now exposed and configurable.

<Frame caption="Solr Pro advanced connection settings">
  <img src="https://mintcdn.com/lucidworks/nSpFApMGvbGVqHP1/assets/images/connectors/solr-pro-adv-connection-settings.png?fit=max&auto=format&n=nSpFApMGvbGVqHP1&q=85&s=12ce96b8bd4119905280c864a6fee801" width="1610" height="270" data-path="assets/images/connectors/solr-pro-adv-connection-settings.png" />
</Frame>

<Frame caption="Solr Pro fetch settings">
  <img src="https://mintcdn.com/lucidworks/nSpFApMGvbGVqHP1/assets/images/connectors/solr-pro-fetch-settings.png?fit=max&auto=format&n=nSpFApMGvbGVqHP1&q=85&s=8f35d1555683c597003ac685434fec38" width="1744" height="792" data-path="assets/images/connectors/solr-pro-fetch-settings.png" />
</Frame>

To transform data after it leaves the Solr Pro connector, use the Index Pipeline stages.

## Migrate from the Solr V1 connector

We strongly encourage migrating from the Solr V1 connector to the Solr Pro connector. If you are currently using the [Solr V1 connector](/docs/fusion-connectors/connectors/v1/solr) and want to migrate your existing connector settings, consult the [general migration guide](/docs/fusion-connectors/migration-guide) and the [Solr-specific migration guide](/docs/fusion-connectors/migration-solr-pro) in the Migration Guide series for instructions.

## Prerequisites

Before using the Solr Pro connector, ensure that you are using Solr 8 or later or later for your Solr environment. Your Fusion environment must be using Fusion 5.9.0 or later.

### Confirm Solr availability

You need to have an accessible external standalone Apache Solr or SolrCloud deployment, as Fusion must be able to reach Solr over HTTP/S. For SolrCloud, make sure the Solr Node endpoint is reachable from Fusion and not just Zookeeper.

The connector uses Solr's `/select` endpoint to pull documents. Ensure `/select` is enabled and not blocked by security rules or proxies.

The Solr instance should return standard `response.docs` JSON.

* For incremental crawling, enable delta indexing.
  * Solr documents must include a timestamp field  such as `last_modified` with a format of ISO-8601 or Solr-readable datetime.
    * Example: `"timestampField": "last_modified"`
* To enforce document-level security, your Solr docs must include user/group fields mapped to Fusion's access control list (ACL) fields like `_lw_acl_read`.

### Write valid queries

You must have a valid Solr query to extract data. When writing queries or filter query, the prefixes of `q` and `fq` are already appended.

* For queries, use `*:*` to fetch all documents.
* You can use filters such as `type:product`.
* Test your query in the Solr Admin UI before using it in your datasource settings.

To use field mapping, know which Solr fields to extract:

* Unique ID field such as `id`
* Optional timestamp field for incremental crawl
* Any custom metadata fields

The Solr Pro connector validates queries before you start a job by executing the query against your Solr environment in a controlled way. If the query generates an error from the server in the validation process, the connector includes detailed and actionable error messages so you can identify and fix errors quickly.

## Authentication

Currently, the Solr Pro connector supports connections to unencrypted, public Solr endpoints, so no authentication is needed.

## Troubleshooting

This section outlines some common troubleshooting topics.

### Query timeout exceeded

If you consistently see the "Query timeout exceeded" error in the Solr connector, your query timeout is likely too low. Increase the **Query Timeout** value or reduce the **Batch Size** so the connector can process a batch in a timely manner.

### Cursor mark not supported

If the Solr connector returns the "Cursor mark not supported" error, you are using a Solr environment earlier than Solr 4.7. Cursor mark pagination is not supported in Solr versions earlier than Solr 4.7. Set **Use cursor mark** to false, and the Solr connector will use offset pagination.

<Note>
  The Solr Pro connector has been tested on Solr 8 and 9, which support cursor mark pagination.
</Note>

### Slow ingestion

If the Solr connector is ingesting documents slowly, there are several fields to check.

If you are indexing many small documents, increase the value of **Batch Size** to process more documents in one match. Alternately, if you are increasing large documents, decrease this value. You can also edit the value of **Max connections per host** to a value that suits your needs.

## Configuration

<Tip>
  When entering configuration values in the UI, use *unescaped* characters, such as `\t` for the tab character. When entering configuration values in the API, use *escaped* characters, such as `\\t` for the tab character.
</Tip>

<SchemaParamFields schema={schema} />
