NIFIREG-272 Signed release tag for approved release of NiFi Registry 0.4.0
-----BEGIN PGP SIGNATURE-----

iQJGBAABCAAwFiEEXSd8h+MSs7tzikB2oN2p7VBxHDkFAlzkP6oSHGJiZW5kZUBh
cGFjaGUub3JnAAoJEKDdqe1QcRw5C2sP/3e8BHAkY272GcwPtNtMCGyNZLzapzn9
Tr37fsHFCKIHvEg8tHa+VAARqmnTFASE6iCvvxV9lgqBIbqHxrYCWUIAapAhJ0Kh
KJOlbUKfkdc5rdXrPxr7JoSaDnppZd1HA8bpFEhox069/X4l4n5pNd36Z7ErLkRI
apPGB+x2ltrc92tqAltUFHVmrl/7TsHYkTsPNUtbphNBMPeiyfZfTOV4CPCtCQ6f
VLUrSxcUesYfR8nCMiuwkdTQc9zu08Yp48b+dITLDIqe/Yl02YWMZmSCgvwf2Rka
V/VO8MKwJDbjiFbwTqcVnpXi8GdZLSWMY7hHJ1uwhBSXDBo9yOjpyJPSiqN4CVRZ
a3WJwfM59PXc+wNvTXQ+Y5mLQwYI8hfLzkAxCuQvJDIkFUFsCaYiMAEQvvXIR28N
HHzNJLXxbePNQI9IjWoMCouRYpMdte8TzZY7Ujcdq358py1uQhaq3bjHIBb06Sdj
yxgowZ3E1DvfDZwQ37Dc/jeO+n+oy8M2Qr+AKvXq2GE7M2bx51bBenQDNDRWdspa
nqDmVWcGSxGOee7y4H/MA9aab0N5qQexUYWXu2E6Xy0QIY3sAZGqp0eiYidLMnIU
KjII49E6ANVB0eHGaH6rCQ5sC9V1+akOS4m84GAGZe82BKtCp48gGM/iTe61It3S
c2ihAWL43ix/
=vO9d
-----END PGP SIGNATURE-----
NIFIREG-272-RC1 prepare release nifi-registry-0.4.0-RC1
34 files changed
tree: 1caec2b3358bb49cd2ec7acae6e3728be0034d61
  1. .gitignore
  2. .travis-output-filters
  3. .travis.yml
  4. LICENSE
  5. NOTICE
  6. README.md
  7. build-and-run.sh
  8. nifi-registry-assembly/
  9. nifi-registry-core/
  10. nifi-registry-extensions/
  11. nifi-registry-toolkit/
  12. pom.xml
  13. stop.sh
README.md

Apache NiFi Registry Build Status

Registry—a subproject of Apache NiFi—is a complementary application that provides a central location for storage and management of shared resources across one or more instances of NiFi and/or MiNiFi.

Table of Contents

Getting Started

Requirements

  • Java 1.8 (above 1.8.0_45)
  • Maven 3.1.0, or newer
  • Recent git client
  1. Clone the repo

     git clone https://git-wip-us.apache.org/repos/asf/nifi-registry.git
     git checkout master
    
  2. Build the project

     cd nifi-registry
     mvn clean install
    

    If you wish to enable style and license checks, specify the contrib-check profile:

     mvn clean install -Pcontrib-check
    

    If you wish to run integration tests and contrib-check, specify both profiles:

     mvn clean install -Pcontrib-check,integration-tests
    
  3. Start the application

     cd nifi-registry-assembly/target/nifi-registry-<VERSION>-bin/nifi-registry-<VERSION>/
     ./bin/nifi-registry.sh start
    

    Note that the application web server can take a while to load before it is accessible.

  4. Accessing the application web UI

    With the default settings, the application UI will be available at http://localhost:18080/nifi-registry

  5. Accessing the application REST API

    If you wish to test against the application REST API, you can access the REST API directly. With the default settings, the base URL of the REST API will be at http://localhost:18080/nifi-registry-api. A UI for testing the REST API will be available at http://localhost:18080/nifi-registry-api/swagger/ui.html

  6. Accessing the application logs

    Logs will be available in logs/nifi-registry-app.log

Database Testing

In order to ensure that NiFi Registry works correctly against different relational databases, the existing integration tests can be run against different databases by leveraging the Testcontainers framework.

Spring profiles are used to control the DataSource factory that will be made available to the Spring application context. DataSource factories are provided that use the Testcontainers framework to start a Docker container for a given database and create a corresponding DataSource. If no profile is specified then an H2 DataSource will be used by default and no Docker containers are required.

Assuming Docker is running on the system where the build is running, then the following commands can be run:

  • H2 (default)

    mvn clean install -Pcontrib-check,integration-tests
    
  • Postgres

    mvn clean install -Pcontrib-check,integration-tests -Dspring.profiles.active=postgres
    
  • MySQL 5.6

    mvn clean install -Pcontrib-check,integration-tests -Dspring.profiles.active=mysql-56
    
  • MySQL 5.7

    mvn clean install -Pcontrib-check,integration-tests -Dspring.profiles.active=mysql-57
    
  • MySQL 8.0

    mvn clean install -Pcontrib-check,integration-tests -Dspring.profiles.active=mysql-8
    

When one of the Testcontainer profiles is activated, the test output should show logs that indicate a container has been started, such as the following:

2019-05-15 16:14:45.078  INFO 66091 --- [           main] 🐳 [mysql:5.7]                           : Creating container for image: mysql:5.7
2019-05-15 16:14:45.145  INFO 66091 --- [           main] o.t.utility.RegistryAuthLocator          : Credentials not found for host (index.docker.io) when using credential helper/store (docker-credential-osxkeychain)
2019-05-15 16:14:45.646  INFO 66091 --- [           main] 🐳 [mysql:5.7]                           : Starting container with ID: ca85c8c5a1990d2a898fad04c5897ddcdb3a9405e695cc11259f50f2ebe67c5f
2019-05-15 16:14:46.437  INFO 66091 --- [           main] 🐳 [mysql:5.7]                           : Container mysql:5.7 is starting: ca85c8c5a1990d2a898fad04c5897ddcdb3a9405e695cc11259f50f2ebe67c5f
2019-05-15 16:14:46.479  INFO 66091 --- [           main] 🐳 [mysql:5.7]                           : Waiting for database connection to become available at jdbc:mysql://localhost:33051/test?useSSL=false&allowPublicKeyRetrieval=true using query 'SELECT 1'

The Flyway connection should also indicate the given database:

2019-05-15 16:15:02.114  INFO 66091 --- [           main] o.a.n.r.db.CustomFlywayConfiguration     : Determined database type is MYSQL
2019-05-15 16:15:02.115  INFO 66091 --- [           main] o.a.n.r.db.CustomFlywayConfiguration     : Setting migration locations to [classpath:db/migration/common, classpath:db/migration/mysql]
2019-05-15 16:15:02.373  INFO 66091 --- [           main] o.a.n.r.d.CustomFlywayMigrationStrategy  : First time initializing database...
2019-05-15 16:15:02.380  INFO 66091 --- [           main] o.f.c.internal.license.VersionPrinter    : Flyway Community Edition 5.2.1 by Boxfuse
2019-05-15 16:15:02.403  INFO 66091 --- [           main] o.f.c.internal.database.DatabaseFactory  : Database: jdbc:mysql://localhost:33051/test (MySQL 5.7)

For a full list of the available DataSource factories, consult the nifi-registry-test module.

License

Except as otherwise noted this software is licensed under the Apache License, Version 2.0

Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.