Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2006 BEA Systems, Inc. All Rights Reserved
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bea.content.indexer
Class IndexerRunner

    java.lang.Object
      com.bea.content.indexer.IndexerRunner

    public class IndexerRunner

extends Object

The IndexRunner provides client side access to the indexing methods of the `ISearchManager`. Content nodes can be indexed starting with a path or all nodes of a given type can be indexed.

- `path` - All content nodes starting at this path will be indexed. The repository is assumed to be the first part of this path. If `path` is set then `type` should not be set.
- `type` - When set all content nodes of this type will be indexed. When the type is specified be sure to also specify the `repository` parameter indicating in which repository the type resides. If the type is set then the path should not be set.
- `repository` - The name of the repository. This attribute is used in conjunction with the `type` attribute.

Communications with the running server are provided by the Indexer EJB. The following information is necessary to make obtain the Indexer EJB.

- `user` - This is the user name used during a JNDI lookup of the Indexer EJB. Default: `""`. The `ejb-jar.xml` descriptor file defines the user roles allowed to access the Indexer EJB. By default these roles are `Admin` and `PortalSystemAdministrator`.
- `password` - This is the password for the user. Default: `""`. NOTE: Supply clear password as command line argument is not secure! Use -userconfigfile and -userkeyfile options instead.
- `userconfigfile` - File generate from weblogic.Admin contains encrypted username and password used during a JNDI lookup of the Indexer EJB. Default: `null`.
- `keyconfigfile` - File generate from weblogic.Admin contains client key for encryption/decryption Default: `null`.
- `url` - The url used to lookup the Indexer EJB. Default: `"t3://localhost:7001"`.
- `application` - This is the name of the enterpise application. If this value is set it will be combined to the `jndiName` in the form `{application}.{jndiName} to create an application specific JNDI name used to look up the Indexer EJB. For example, by default the `jndiName` is "BEA_content.IndexerHome". If the `application` was set to "portalApp" the resulting JNDI name would be "portalApp.BEA_content.IndexerHome". If the `application` is not specified then only the value of `jndiName` will be used to find the Indexer EJB.`
- `jndiName` - The JNDI name used to lookup the Indexer EJB. By default it is "BEA_content.IndexerHome". If the application name has been provided then it will be combined with the `jndiName` in the form of `{application}.{jndiName}`.

The IndexRunner can be run from the command line. Please use the -help option for usage options. The IndexRunner can also be used programatically within other client side code.

Field Summary
`static String` | `JNDI_FACTORY` Defines the JNDI context factory used when loading the Indexer EJB.
`protected static IndexerExceptionTextFormatter` | `textFormatter`

Constructor Summary
`IndexerRunner()`

Method Summary
`String` | `getApplication()` Gets the name of the enterprise application.
`String` | `getJndiName()` Gets the JNDI name used to look up the Indexer EJB.
`String` | `getPassword()` Gets the password that is used when looking up the Indexer EJB.
`String` | `getPath()` Gets the node path.
`String` | `getRepository()` Gets the repository name.
`String` | `getType()` Gets the type name.
`String` | `getUrl()` URL used to lookup the Indexer EJB.
`String` | `getUser()` Gets the user name that is used when looking up the Indexer EJB.
`void` | `index()` Performs indexing based on the parameters set on this IndexerRunner.
`void` | `info(String mesg)` Output an info message.
`static void` | `main(String[] args)`
`void` | `setApplication(String application)` Sets the name of the enterprise application.
`void` | `setJndiName(String jndiName)` Sets the JNDI name used to look up the Indexer EJB.
`void` | `setPassword(String password)` Sets the password that is used when looking up the Indexer EJB.
`void` | `setPath(String path)` Sets the node path.
`void` | `setRepository(String repository)` Sets the repository name.
`void` | `setType(String type)` Sets the type name.
`void` | `setUrl(String url)` URL used to lookup the Indexer EJB.
`void` | `setUser(String user)` Sets the user name that is used when looking up the Indexer EJB.
`void` | `usage()` Print the usage of the application.
`void` | `usage(PrintWriter out)` Print the usage of the application.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### textFormatter

    protected static final IndexerExceptionTextFormatter textFormatter

### JNDI_FACTORY

    public static final String JNDI_FACTORY

  Defines the JNDI context factory used when loading the Indexer EJB.

  See Also
    Constants Summary

Constructor Detail

### IndexerRunner

    public IndexerRunner()

Method Detail

### getUser

    public String getUser()

  Gets the user name that is used when looking up the Indexer EJB.

  Returns
    the user name

### setUser

    public void setUser(String user)

  Sets the user name that is used when looking up the Indexer EJB.

  Parameters
    `user` - the user name

### getPassword

    public String getPassword()

  Gets the password that is used when looking up the Indexer EJB.

  Returns
    the password.

### setPassword

    public void setPassword(String password)

  Sets the password that is used when looking up the Indexer EJB.

  Parameters
    `password` -

### getUrl

    public String getUrl()

  URL used to lookup the Indexer EJB.

  Returns
    the URL

### setUrl

    public void setUrl(String url)

  URL used to lookup the Indexer EJB.

  Parameters
    `url` - the URL

### getApplication

    public String getApplication()

  Gets the name of the enterprise application.

  Returns
    the enterprise application name

### setApplication

    public void setApplication(String application)

  Sets the name of the enterprise application.

  Parameters
    `application` - the enterprise application name

### getJndiName

    public String getJndiName()

  Gets the JNDI name used to look up the Indexer EJB.

  Returns
    the JNDI name

### setJndiName

    public void setJndiName(String jndiName)

  Sets the JNDI name used to look up the Indexer EJB.

  Parameters
    `jndiName` -

### getRepository

    public String getRepository()

  Gets the repository name.

  Returns
    the repository name.

### setRepository

    public void setRepository(String repository)

  Sets the repository name.

  Parameters
    `repository` - the repository name.

### getType

    public String getType()

  Gets the type name.

  Returns
    the type name.

### setType

    public void setType(String type)

  Sets the type name.

  Parameters
    `type` - the type name.

### getPath

    public String getPath()

  Gets the node path.

  Returns
    the node path.

### setPath

    public void setPath(String path)

  Sets the node path.

  Parameters
    `path` - the node path.

### index

    public void index()
               throws IndexerRunnerException

  Performs indexing based on the parameters set on this IndexerRunner.

  Throws
    `org.apache.tools.ant.BuildException`
    `IndexerRunnerException`

### usage

    public void usage()

  Print the usage of the application.

### usage

    public void usage(PrintWriter out)

  Print the usage of the application.

### info

    public void info(String mesg)

  Output an info message.

### main

    public static void main(String[] args)

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006 BEA Systems, Inc. All Rights Reserved