Deployer
Date: 2010-07-30

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

## org.postgresql.pljava.deploy
Class Deployer

    java.lang.Object
      org.postgresql.pljava.deploy.Deployer

    public class Deployer

extends java.lang.Object

When running the deployer, you must use a classpath that can see the deploy.jar found in the Pl/Java distribution and the postgresql.jar from the PostgreSQL distribution. The former contains the code for the deployer command and the second includes the PostgreSQL JDBC driver. You then run the deployer with the command:

> `java -cp <your classpath> org.postgresql.pljava.deploy.Deployer [ options ]`

It's recommended that create a shell script or a .bat script that does this for you so that you don't have to do this over and over again.

### Deployer options

> Option | Description
> -install | Installs the Java language along with the sqlj procedures. The deployer will fail if the language is installed already.
> -reinstall | Reinstalls the Java language and the sqlj procedures. This will effectively drop all jar files that have been loaded.
> -remove | Drops the Java language and the sqjl procedures and loaded jars
> -user <user name> | Name of user that connects to the database. Default is current user
> -password <password> | Password of user that connects to the database. Default is no password
> -database <database> | The name of the database to connect to. Default is current user
> -host <hostname> | Name of the host. Default is "localhost"
> -windows | Use this option if the host runs on a windows platform. Affects the name used for the Pl/Java dynamic library

Constructor Summary
`Deployer(java.sql.Connection c)`

Method Summary
`static void` | `checkIfConnectedAsSuperuser(java.sql.Connection conn)`
`void` | `createSQLJSchema()`
`void` | `dropSQLJSchema()`
`void` | `initializeSQLJSchema()`
`void` | `initJavaHandlers()`
`static void` | `main(java.lang.String[] argv)`
`static void` | `printUsage()`

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

Constructor Detail

### Deployer

    public Deployer(java.sql.Connection c)

Method Detail

### printUsage

    public static void printUsage()

### main

    public static void main(java.lang.String[] argv)

### checkIfConnectedAsSuperuser

    public static void checkIfConnectedAsSuperuser(java.sql.Connection conn)
                                            throws java.sql.SQLException

  Throws:
    `java.sql.SQLException`

### dropSQLJSchema

    public void dropSQLJSchema()
                        throws java.sql.SQLException

  Throws:
    `java.sql.SQLException`

### createSQLJSchema

    public void createSQLJSchema()
                          throws java.sql.SQLException

  Throws:
    `java.sql.SQLException`

### initializeSQLJSchema

    public void initializeSQLJSchema()
                              throws java.sql.SQLException

  Throws:
    `java.sql.SQLException`

### initJavaHandlers

    public void initJavaHandlers()
                          throws java.sql.SQLException

  Throws:
    `java.sql.SQLException`

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

Copyright (c) 2003, 2004, 2005 TADA AB - Taby Sweden. \ Distributed under the terms shown in COPYRIGHT