Managed document type

Contents

Diving into the topic of embedding document types with your collector.

Introduction

Document types are used to control indexing of content. Applications may optionally include one or more document types. These are referred to as "managed", as opposed to document types that are edited directly from the Explorer admin UI.

Whenever a new verion of the collector app is deployed, the manage document types will be updated to the new version.

Bundling

When installing an application that contains document types, Explorer will automatically pick up and register them.

All you need to do is adding a file called documentTypes.json in your app.

Below is what the document type bundled with the starter looks like:

src/main/resources/documentTypes.json:
[{
	"_name": "starter_doctype",
	"addFields": false,
	"properties": [{
		"active": true,
		"enabled": true,
		"fulltext": true,
		"includeInAllText": true,
		"max": 0,
		"min": 0,
		"name": "text",
		"nGram": true,
		"path": false,
		"valueType": "string"
	},{
		"active": true,
		"enabled": true,
		"fulltext": true,
		"includeInAllText": true,
		"max": 0,
		"min": 0,
		"name": "title",
		"nGram": true,
		"path": false,
		"valueType": "string"
	},{
		"active": true,
		"enabled": true,
		"fulltext": true,
		"includeInAllText": false,
		"max": 0,
		"min": 1,
		"name": "url",
		"nGram": false,
		"path": false,
		"valueType": "string"
	}]
}]
Each document type must have a globaly unique name to avoid conflicting with other document types. As such prefixing is highly recommended - i.e. mycompany_doctypename

With the document types sorted out, let’s find out how you can configure your collector through a form.


Contents

Contents

AI-powered search

Juke AI