• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

slavaz/embedded-postgresql-maven-plugin: Embedded PostgreSQL Maven Plugin

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

slavaz/embedded-postgresql-maven-plugin

开源软件地址(OpenSource Url):

https://github.com/slavaz/embedded-postgresql-maven-plugin

开源编程语言(OpenSource Language):

Java 99.8%

开源软件介绍(OpenSource Introduction):

embedded-postgresql-maven-plugin

Build status

Description

Embedded PostgreSQL Maven Plugin provides a platform neutral way for running postgres server in integration tests. This plugin is based on Embedded PostgreSQL Server library

Configuration

pgServerVersion

The plugin currently supports next PostgreSQL versions: 9.5.7, 9.6.5, 10.0

You also may use aliases:

  • 9.5 -> 9.5.7
  • 9.6 -> 9.6.5
  • latest -> 10.0

pgDatabaseDir

Where server files will be plased. Default {project.build.directory}/pgdata

pgHost

Host(IP address) for listening incoming connections.

pgPort

Port for listening incoming connections.

pgLocale

Locale for embedded PostgreSQL server. Leave empty for running the server with system locale. Specify "no" to skip locale & charset definition.

pgCharset

Charset for embedded PostgreSQL server. Leave empty for running the server with system charset. Specify "no" to skip locale & charset definition.

dbName

Database name. Will be created

userName

User name. Will be created

password

User password for newly created user

Usage example

Starts PostgreSQL server, creates a database and a user with specified password

...
<build>
    ..
    <plugins>
      <plugin>
        <groupId>com.github.slavaz</groupId>
        <artifactId>embedded-postgresql-maven-plugin</artifactId>
        <configuration>
          <pgServerVersion>9.5</pgServerVersion>
          <pgServerPort>15432</pgServerPort>
          <dbName>testdb</dbName>
          <userName>testuser</userName>
          <password>userpass</password>
        </configuration>
        <executions>
          <execution>
            <id>start-pgsql</id>
            <phase>pre-integration-test</phase>
            <goals>
              <goal>start</goal>
            </goals>
          </execution>
          <execution>
            <id>stop-pgsql</id>
            <phase>post-integration-test</phase>
            <goals>
              <goal>stop</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
</build>

Goals

  1. start -- start the server
  2. stop -- stop the server



鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap