Repository: incubator-nifi
Updated Branches:
  refs/heads/develop a69ed6bae -> 997ed9465


http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserGroupResource.java
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserGroupResource.java
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserGroupResource.java
index f7b2009..3a0b596 100644
--- 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserGroupResource.java
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserGroupResource.java
@@ -16,6 +16,12 @@
  */
 package org.apache.nifi.web.api;
 
+import com.wordnik.swagger.annotations.Api;
+import com.wordnik.swagger.annotations.ApiOperation;
+import com.wordnik.swagger.annotations.ApiParam;
+import com.wordnik.swagger.annotations.ApiResponse;
+import com.wordnik.swagger.annotations.ApiResponses;
+import com.wordnik.swagger.annotations.Authorization;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Map;
@@ -44,12 +50,12 @@ import org.apache.commons.lang3.StringUtils;
 import org.apache.nifi.web.NiFiServiceFacade;
 import org.apache.nifi.web.api.dto.RevisionDTO;
 import org.apache.nifi.web.api.dto.UserGroupDTO;
-import org.codehaus.enunciate.jaxrs.TypeHint;
 import org.springframework.security.access.prepost.PreAuthorize;
 
 /**
  * RESTful endpoint for managing this Controller's user groups.
  */
+@Api(hidden = true)
 public class UserGroupResource extends ApplicationResource {
 
     /*
@@ -69,11 +75,15 @@ public class UserGroupResource extends ApplicationResource {
      * Updates a new user group.
      *
      * @param httpServletRequest request
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
-     * @param userIds A collection of user ids to include in this group. If a 
user already belongs to another group, they will be placed in this group 
instead. Existing users in this group will remain
-     * in this group.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
+     * @param userIds A collection of user ids to include in this group. If a
+     * user already belongs to another group, they will be placed in this group
+     * instead. Existing users in this group will remain in this group.
      * @param group The name of the group.
-     * @param rawAuthorities Array of authorities to assign to the specified 
user.
+     * @param rawAuthorities Array of authorities to assign to the specified
+     * user.
      * @param status The status of the specified users account.
      * @param formParams form params
      * @return A userGroupEntity.
@@ -83,7 +93,6 @@ public class UserGroupResource extends ApplicationResource {
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @Path("/{group}")
     @PreAuthorize("hasRole('ROLE_ADMIN')")
-    @TypeHint(UserGroupEntity.class)
     public Response updateUserGroup(
             @Context HttpServletRequest httpServletRequest,
             @PathParam("group") String group,
@@ -138,10 +147,33 @@ public class UserGroupResource extends 
ApplicationResource {
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @Path("/{group}")
     @PreAuthorize("hasRole('ROLE_ADMIN')")
-    @TypeHint(UserGroupEntity.class)
+    @ApiOperation(
+            value = "Updates a user group",
+            response = UserGroupEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 404, message = "The specified resource 
could not be found."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
     public Response updateUserGroup(
             @Context HttpServletRequest httpServletRequest,
+            @ApiParam(
+                    value = "The name of the user group.",
+                    required = true
+            )
             @PathParam("group") String group,
+            @ApiParam(
+                    value = "The user group configuration details.",
+                    required = true
+            )
             UserGroupEntity userGroupEntity) {
 
         if (userGroupEntity == null || userGroupEntity.getUserGroup() == null) 
{
@@ -229,23 +261,55 @@ public class UserGroupResource extends 
ApplicationResource {
     }
 
     /**
-     * Deletes the user from the specified group. The user will not be 
removed, just the fact that they were in this group.
+     * Deletes the user from the specified group. The user will not be removed,
+     * just the fact that they were in this group.
      *
      * @param httpServletRequest request
      * @param group The user group.
      * @param userId The user id to remove.
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
      * @return A userGroupEntity.
      */
     @DELETE
+    @Consumes(MediaType.WILDCARD)
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @Path("/{group}/users/{userId}")
     @PreAuthorize("hasRole('ROLE_ADMIN')")
-    @TypeHint(UserGroupEntity.class)
+    @ApiOperation(
+            value = "Removes a user from a user group",
+            notes = "Removes a user from a user group. The will not be 
deleted, jsut the fact that they were in this group.",
+            response = UserGroupEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 404, message = "The specified resource 
could not be found."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
     public Response removeUserFromGroup(
             @Context HttpServletRequest httpServletRequest,
+            @ApiParam(
+                    value = "The name of the user group.",
+                    required = true
+            )
             @PathParam("group") String group,
+            @ApiParam(
+                    value = "The id of the user to remove from the user 
group.",
+                    required = true
+            )
             @PathParam("userId") String userId,
+            @ApiParam(
+                    value = "If the client id is not specified, new one will 
be generated. This value (whether specified or generated) is included in the 
response.",
+                    required = false
+            )
             @QueryParam(CLIENT_ID) @DefaultValue(StringUtils.EMPTY) 
ClientIdParameter clientId) {
 
         // this user is being modified, replicate to the nodes to invalidate 
this account
@@ -295,21 +359,49 @@ public class UserGroupResource extends 
ApplicationResource {
     }
 
     /**
-     * Deletes the user group. The users will not be removed, just the fact 
that they were grouped.
+     * Deletes the user group. The users will not be removed, just the fact 
that
+     * they were grouped.
      *
      * @param httpServletRequest request
      * @param group The user group.
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
      * @return A userGroupEntity.
      */
     @DELETE
+    @Consumes(MediaType.WILDCARD)
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @Path("/{group}")
     @PreAuthorize("hasRole('ROLE_ADMIN')")
-    @TypeHint(UserGroupEntity.class)
+    @ApiOperation(
+            value = "Deletes a user group",
+            notes = "Deletes a user group. The users will not be removed, just 
the fact that they were grouped.",
+            response = UserGroupEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 404, message = "The specified resource 
could not be found."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
     public Response ungroup(
             @Context HttpServletRequest httpServletRequest,
+            @ApiParam(
+                    value = "The name of the user group.",
+                    required = true
+            )
             @PathParam("group") String group,
+            @ApiParam(
+                    value = "If the client id is not specified, new one will 
be generated. This value (whether specified or generated) is included in the 
response.",
+                    required = false
+            )
             @QueryParam(CLIENT_ID) @DefaultValue(StringUtils.EMPTY) 
ClientIdParameter clientId) {
 
         // this user is being modified, replicate to the nodes to invalidate 
this account

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserResource.java
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserResource.java
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserResource.java
index 6dbb1a7..4a61ef4 100644
--- 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserResource.java
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/UserResource.java
@@ -16,6 +16,12 @@
  */
 package org.apache.nifi.web.api;
 
+import com.wordnik.swagger.annotations.Api;
+import com.wordnik.swagger.annotations.ApiOperation;
+import com.wordnik.swagger.annotations.ApiParam;
+import com.wordnik.swagger.annotations.ApiResponse;
+import com.wordnik.swagger.annotations.ApiResponses;
+import com.wordnik.swagger.annotations.Authorization;
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
@@ -56,12 +62,12 @@ import org.apache.commons.lang3.StringUtils;
 import org.apache.nifi.web.NiFiServiceFacade;
 import static org.apache.nifi.web.api.ApplicationResource.CLIENT_ID;
 import org.apache.nifi.web.api.dto.RevisionDTO;
-import org.codehaus.enunciate.jaxrs.TypeHint;
 import org.springframework.security.access.prepost.PreAuthorize;
 
 /**
  * RESTful endpoint for managing this Controller's users.
  */
+@Api(hidden = true)
 public class UserResource extends ApplicationResource {
 
     /*
@@ -80,16 +86,42 @@ public class UserResource extends ApplicationResource {
     /**
      * Gets all users that are registered within this Controller.
      *
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
      * @param grouped Whether to return the users in their groups.
      * @return A usersEntity.
      */
     @GET
+    @Consumes(MediaType.WILDCARD)
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
+    @Path("") // necessary due to a bug in swagger
     @PreAuthorize("hasRole('ROLE_ADMIN')")
-    @TypeHint(UsersEntity.class)
+    @ApiOperation(
+            value = "Gets all users",
+            response = UsersEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
     public Response getUsers(
+            @ApiParam(
+                    value = "If the client id is not specified, new one will 
be generated. This value (whether specified or generated) is included in the 
response.",
+                    required = false
+            )
             @QueryParam(CLIENT_ID) @DefaultValue(StringUtils.EMPTY) 
ClientIdParameter clientId,
+            @ApiParam(
+                    value = "Whether to return the users in their respective 
groups.",
+                    required = false
+            )
             @QueryParam("grouped") @DefaultValue("false") Boolean grouped) {
 
         // get the users
@@ -112,16 +144,43 @@ public class UserResource extends ApplicationResource {
     /**
      * Gets the details for the specified user.
      *
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
      * @param id The user id.
      * @return A userEntity.
      */
     @GET
+    @Consumes(MediaType.WILDCARD)
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @PreAuthorize("hasRole('ROLE_ADMIN')")
     @Path("/{id}")
-    @TypeHint(UserEntity.class)
-    public Response getUser(@QueryParam(CLIENT_ID) 
@DefaultValue(StringUtils.EMPTY) ClientIdParameter clientId,
+    @ApiOperation(
+            value = "Gets a user",
+            response = UserEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 404, message = "The specified resource 
could not be found."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
+    public Response getUser(
+            @ApiParam(
+                    value = "If the client id is not specified, new one will 
be generated. This value (whether specified or generated) is included in the 
response.",
+                    required = false
+            )
+            @QueryParam(CLIENT_ID) @DefaultValue(StringUtils.EMPTY) 
ClientIdParameter clientId,
+            @ApiParam(
+                    value = "The user id.",
+                    required = true
+            )
             @PathParam("id") String id) {
 
         // get the specified user
@@ -147,11 +206,33 @@ public class UserResource extends ApplicationResource {
      * @return A userSearchResultsEntity
      */
     @GET
+    @Consumes(MediaType.WILDCARD)
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @Path("/search-results")
     @PreAuthorize("hasAnyRole('ROLE_DFM', 'ROLE_ADMIN')")
-    @TypeHint(UserSearchResultsEntity.class)
-    public Response searchUsers(@QueryParam("q") 
@DefaultValue(StringUtils.EMPTY) String value) {
+    @ApiOperation(
+            value = "Searches for users",
+            response = UserSearchResultsEntity.class,
+            authorizations = {
+                @Authorization(value = "Data Flow Manager", type = "ROLE_DFM"),
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
+    public Response searchUsers(
+            @ApiParam(
+                    value = "The search terms.",
+                    required = true
+            )
+            @QueryParam("q") @DefaultValue(StringUtils.EMPTY) String value) {
+
         final List<UserSearchResultDTO> userMatches = new ArrayList<>();
         final List<UserGroupSearchResultDTO> userGroupMatches = new 
ArrayList<>();
 
@@ -234,9 +315,12 @@ public class UserResource extends ApplicationResource {
      * Updates the specified user.
      *
      * @param httpServletRequest request
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
      * @param id The id of the user to update.
-     * @param rawAuthorities Array of authorities to assign to the specified 
user.
+     * @param rawAuthorities Array of authorities to assign to the specified
+     * user.
      * @param status The status of the specified users account.
      * @param formParams form params
      * @return A userEntity
@@ -246,7 +330,6 @@ public class UserResource extends ApplicationResource {
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @PreAuthorize("hasRole('ROLE_ADMIN')")
     @Path("/{id}")
-    @TypeHint(UserEntity.class)
     public Response updateUser(
             @Context HttpServletRequest httpServletRequest,
             @FormParam(CLIENT_ID) @DefaultValue(StringUtils.EMPTY) 
ClientIdParameter clientId,
@@ -299,11 +382,33 @@ public class UserResource extends ApplicationResource {
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @PreAuthorize("hasRole('ROLE_ADMIN')")
     @Path("/{id}")
-    @TypeHint(UserEntity.class)
+    @ApiOperation(
+            value = "Updates a user",
+            response = UserEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 404, message = "The specified resource 
could not be found."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
     public Response updateUser(
             @Context HttpServletRequest httpServletRequest,
+            @ApiParam(
+                    value = "The user id.",
+                    required = true
+            )
             @PathParam("id") String id,
-            UserEntity userEntity) {
+            @ApiParam(
+                    value = "The user configuration details.",
+                    required = true
+            ) UserEntity userEntity) {
 
         if (userEntity == null || userEntity.getUser() == null) {
             throw new IllegalArgumentException("User details must be 
specified.");
@@ -386,17 +491,43 @@ public class UserResource extends ApplicationResource {
      *
      * @param httpServletRequest request
      * @param id The user id
-     * @param clientId Optional client id. If the client id is not specified, 
a new one will be generated. This value (whether specified or generated) is 
included in the response.
+     * @param clientId Optional client id. If the client id is not specified, a
+     * new one will be generated. This value (whether specified or generated) 
is
+     * included in the response.
      * @return A userEntity.
      */
     @DELETE
+    @Consumes(MediaType.WILDCARD)
     @Produces({MediaType.APPLICATION_JSON, MediaType.APPLICATION_XML})
     @Path("/{id}")
     @PreAuthorize("hasRole('ROLE_ADMIN')")
-    @TypeHint(UserEntity.class)
+    @ApiOperation(
+            value = "Deletes a user",
+            response = UserEntity.class,
+            authorizations = {
+                @Authorization(value = "Administrator", type = "ROLE_ADMIN")
+            }
+    )
+    @ApiResponses(
+            value = {
+                @ApiResponse(code = 400, message = "NiFi was unable to 
complete the request because it was invalid. The request should not be retried 
without modification."),
+                @ApiResponse(code = 401, message = "Client could not be 
authenticated."),
+                @ApiResponse(code = 403, message = "Client is not authorized 
to make this request."),
+                @ApiResponse(code = 404, message = "The specified resource 
could not be found."),
+                @ApiResponse(code = 409, message = "The request was valid but 
NiFi was not in the appropriate state to process it. Retrying the same request 
later may be successful.")
+            }
+    )
     public Response deleteUser(
             @Context HttpServletRequest httpServletRequest,
+            @ApiParam(
+                    value = "The user id.",
+                    required = true
+            )
             @PathParam("id") String id,
+            @ApiParam(
+                    value = "If the client id is not specified, new one will 
be generated. This value (whether specified or generated) is included in the 
response.",
+                    required = false
+            )
             @QueryParam(CLIENT_ID) @DefaultValue(StringUtils.EMPTY) 
ClientIdParameter clientId) {
 
         // this user is being modified, replicate to the nodes to invalidate 
this account

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/package-info.java
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/package-info.java
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/package-info.java
deleted file mode 100644
index 0392ca4..0000000
--- 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/package-info.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You 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.
- */
-/**
- * <p>
- * The NiFi REST API allows clients to obtain and update configuration and 
status information pertaining to an instance of NiFi. The links below detail 
each resource. Follow the link to get more
- * information about the resource including the supported HTTP methods and the 
expected parameters.</p>
- *
- * <p>
- * Additionally, the documentation for each resource will describe what type 
of data should be returned from a successful invocation. However, if the 
request is not successful one of the follow status
- * codes should be returned:</p>
- *
- * <ul>
- * <li>400 (Bad Request) - A 400 status code will be returned when NiFi is 
unable to complete the request because it was invalid. The request should not 
be retried without modification.</li>
- * <li>401 (Unathorized) - A 401 status code indicates that the user is not 
known to this NiFi instance. The user may submit an account request.</li>
- * <li>403 (Forbidden) - A 403 status code indicates that the user is known to 
this NiFi instance and they do not have authority to perform the requested 
action.</li>
- * <li>404 (Not Found) - A 404 status code will be returned when the desired 
resource does not exist.</li>
- * <li>409 (Conflict) - NiFi employs an optimistic locking strategy where the 
client must include a revision in their request when performing an update. If 
the specified revision does not match the
- * current base revision a 409 status code is returned. Additionally, a 409 is 
used when the state of the system does not allow for the request at that time. 
This same request may be successful later
- * if the system is in a different state (e.g. cannot delete a processor 
because it is currently running).</li>
- * <li>500 (Internal Server Error) - A 500 status code indicates that an 
unexpected error has occurred.</li>
- * </ul>
- *
- * <p>
- * Most unsuccessful requests will include a description of the problem in the 
entity body of the response.</p>
- *
- * <p>
- * The context path for the REST API is /nifi-api</p>
- */
-package org.apache.nifi.web.api;

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/META-INF/NOTICE
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/META-INF/NOTICE
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/META-INF/NOTICE
deleted file mode 100644
index 253f083..0000000
--- 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/META-INF/NOTICE
+++ /dev/null
@@ -1,27 +0,0 @@
-nifi-web-api
-Copyright 2014-2015 The Apache Software Foundation
-
-This product includes software developed at
-The Apache Software Foundation (http://www.apache.org/).
-
-===========================================
-Apache Software License v2
-===========================================
-
-The following binary components are provided under the Apache Software License 
v2
-
-  (ASLv2) Enunciate Core Annotations 
(org.codehaus.enunciate:enunciate-core-annotations:jar:1.28 - 
http://dist.codehaus.org/enunciate/enunciate-1.28.zip)
-    The following NOTICE information applies:
-      This product includes software developed by the Spring Framework
-      Project (http://www.springframework.org).
-
-      This product includes software developed by the
-      Visigoth Software Society (http://www.visigoths.org/).
-
-========================================================================
-Common Development and Distribution License 1.0
-========================================================================
-
-The following binary components are provided under the Common Development and 
Distribution License 1.0. See project link for details.
-
-    (CDDL 1.0) SR 250 Common Annotations For The JavaTM Platform 
(javax.annotation:jsr250-api:jar:1.0 - 
http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html)

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/bgNifiLogo.png
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/bgNifiLogo.png
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/bgNifiLogo.png
new file mode 100644
index 0000000..d92c484
Binary files /dev/null and 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/bgNifiLogo.png
 differ

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/nifi16.ico
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/nifi16.ico
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/nifi16.ico
new file mode 100644
index 0000000..2ac3670
Binary files /dev/null and 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/images/nifi16.ico
 differ

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/endpoint.hbs
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/endpoint.hbs
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/endpoint.hbs
new file mode 100644
index 0000000..6296862
--- /dev/null
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/endpoint.hbs
@@ -0,0 +1,61 @@
+{{!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You 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.
+--}}
+<div class="endpoints">
+    <span class="path hidden">{{@key}}</span>
+    {{#post}}
+        <div class="endpoint post">
+            <div class="operation-handle">
+                <div class="method">POST</div>
+                <div class="path mono"></div>
+                <div class="summary">{{summary}}</div>
+                <div class="clear"></div>
+            </div>
+            {{> operation}}
+        </div>
+    {{/post}}
+    {{#get}}
+        <div class="endpoint get">
+            <div class="operation-handle">
+                <div class="method">GET</div>
+                <div class="path mono"></div>
+                <div class="summary">{{summary}}</div>
+                <div class="clear"></div>
+            </div>
+            {{> operation}}
+        </div>
+    {{/get}}
+    {{#put}}
+        <div class="endpoint put">
+            <div class="operation-handle">
+                <div class="method">PUT</div>
+                <div class="path mono"></div>
+                <div class="summary">{{summary}}</div>
+                <div class="clear"></div>
+            </div>
+            {{> operation}}
+        </div>
+    {{/put}}
+    {{#delete}}
+        <div class="endpoint delete">
+            <div class="operation-handle">
+                <div class="method">DELETE</div>
+                <div class="path mono"></div>
+                <div class="summary">{{summary}}</div>
+                <div class="clear"></div>
+            </div>
+            {{> operation}}
+        </div>
+    {{/delete}}
+</div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/example.hbs
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/example.hbs
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/example.hbs
new file mode 100644
index 0000000..26a4283
--- /dev/null
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/example.hbs
@@ -0,0 +1,18 @@
+{{!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You 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.
+--}}{{!-- formatting here matters... in whitespace: pre. this is not 
comprehensive but sufficent for our examples --}}
+{{#each properties}}    {{#ifeq type "string"}}"{{@key}}": 
"value"{{/ifeq}}{{#ifeq type "boolean"}}"{{@key}}": true{{/ifeq}}{{#ifeq type 
"integer"}}"{{@key}}": 0{{/ifeq}}{{#ifeq type "number"}}"{{@key}}": 
0.0{{/ifeq}}{{#if $ref}}"{{@key}}": <span class="nested collapsed"><span 
class="nested-id hidden">{{basename $ref}}</span><span 
class="nested-example"><span 
class="open-object">&#123;&#8230;&#125;</span></span></span>{{/if}}{{#ifeq type 
"array"}}"{{@key}}": [{{#if items.$ref}}<span class="nested collapsed"><span 
class="nested-id hidden">{{basename items.$ref}}</span><span 
class="nested-example"><span 
class="open-object">&#123;&#8230;&#125;</span></span></span>{{else}}"value"{{/if}}]{{/ifeq}}{{#ifeq
 type "object"}}"{{@key}}": <span class="open-object">&#123;
+        "name": {{#if additionalProperties.$ref}}<span class="nested 
collapsed"><span class="nested-id hidden">{{basename 
additionalProperties.$ref}}</span><span class="nested-example"><span 
class="open-object">&#123;&#8230;&#125;</span></span></span>{{else}}{{#ifeq 
additionalProperties.type "integer"}}0{{else}}"value"{{/ifeq}}{{/if}}
+    &#125;</span>{{/ifeq}}<span class="comma">,</span>
+{{/each}}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/index.html.hbs
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/index.html.hbs
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/index.html.hbs
new file mode 100644
index 0000000..c44a47f
--- /dev/null
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/index.html.hbs
@@ -0,0 +1,597 @@
+<!DOCTYPE html>
+<!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You 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.
+-->
+<html>
+    <head>
+        <title>{{info.title}}-{{info.version}}</title>
+        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+        <link rel="shortcut icon" href="images/nifi16.ico"/>
+        <script type="text/javascript" 
src="../nifi/js/jquery/jquery-2.1.1.min.js"></script>
+        <script type="text/javascript">
+            if (typeof window.jQuery === 'undefined') {
+                document.write(unescape('%3Cscript 
src="https://code.jquery.com/jquery-2.1.1.min.js"; type="text/javascript" 
%3E%3C/script%3E'));
+            }
+        </script>
+        <style>
+            @import 
"https://fonts.googleapis.com/css?family=Open+Sans:300,300italic,400,400italic,600,600italic|Noto+Serif:400,400italic,700,700italic|Droid+Sans+Mono:400";
+
+            html {
+                overflow-y: scroll;
+            }
+            
+            html, html a {
+                -webkit-font-smoothing: antialiased;
+                text-shadow: 1px 1px 1px rgba(0,0,0,0.004);
+            }
+
+            body {
+                width: 62.5em;
+                margin: 0 auto;
+                display: block;
+                font-family: "Open Sans", "DejaVu Sans", sans-serif;
+            }
+            
+            div.header {
+                margin-top: 10px;
+            }
+            
+            img.logo {
+                float: left;
+                margin-right: 10px;
+            }
+            
+            div.header > div.title {
+                font-size: 30px;
+                height: 50px;
+                line-height: 50px;
+            }
+            
+            .sub-title {
+                font-style: italic;
+                color: #aaa;
+            }
+            
+            div.overview {
+                margin-top: 10px;
+                margin-bottom: 15px;
+            }
+            
+            div.endpoint {
+                margin-bottom: 10px;
+            }
+
+            /* get */
+            
+            div.endpoint.get {
+                border: 1px solid #174961;
+            }
+            
+            div.get div.operation-handle {
+                background-color: rgba(23, 73, 97, .15);
+            }
+            
+            div.get div.method {
+                background-color: #174961;
+            }
+            
+            div.get div.operation {
+                border-top: 1px solid #174961;
+            }
+            
+            /* post */
+            
+            div.endpoint.post {
+                border: 1px solid #7298AC;
+            }
+            
+            div.post div.operation-handle {
+                background-color: rgba(114, 152, 172, .15);
+            }
+            
+            div.post div.method {
+                background-color: #7298AC;
+            }
+            
+            div.post div.operation {
+                border-top: 1px solid #7298AC;
+            }
+            
+            /* put */
+            
+            div.endpoint.put {
+                border: 1px solid #063046;
+            }
+            
+            div.put div.operation-handle {
+                background-color: rgba(6, 48, 70, .15);
+            }
+            
+            div.put div.method {
+                background-color: #063046;
+            }
+            
+            div.put div.operation {
+                border-top: 1px solid #063046;
+            }
+            
+            /* delete */
+            
+            div.endpoint.delete {
+                border: 1px solid #47758E;
+            }
+            
+            div.delete div.operation-handle {
+                background-color: rgba(71, 117, 142, .15);
+            }
+            
+            div.delete div.method {
+                background-color: #47758E;
+            }
+            
+            div.delete div.operation {
+                border-top: 1px solid #47758E;
+            }
+            
+            /* operations */
+            
+            div.operation-handle {
+                cursor: pointer;
+                padding-right: 5px;
+                height: 22px;
+            }
+            
+            div.method {
+                float: left;
+                width: 75px;
+                color: #fff;
+                text-align: center;
+                background-color: #7098ad;
+                margin-right: 10px;
+                font-weight: bold;
+            }
+
+            div.endpoint div.path {
+                float: left;
+                line-height: 22px;
+            }
+
+            div.summary {
+                float: right;
+                font-size: 12px;
+                line-height: 22px;
+            }
+
+            div.operation {
+                padding: 5px;
+                font-size: 12px;
+            }
+
+            div.operation > div.title {
+                font-weight: bold;
+                color: #000;
+            }
+            
+            div.operation > table {
+                margin-left: 5px;
+                margin-right: 5px;
+            }
+            
+            div.operation div.details {
+                margin-left: 5px;
+                margin-bottom: 5px;
+                color: #333;
+            }
+            
+            div.operation div.description {
+                margin-bottom: 10px;
+            }
+
+            div.mediatype {
+                line-height: 16px;
+            }
+
+            div.mediatype > div.title {
+                float: left;
+                width: 70px;
+            }
+            
+            div.mediatype div.title {
+                float: left;
+            }
+            
+            div.type {
+                position: fixed;
+                width: 800px;
+                height: 500px;
+                left: 50%;
+                top: 50%;
+                margin-left: -400px;
+                margin-top: -250px;
+                border: 3px solid #365C6A;
+                box-shadow: 4px 4px 6px rgba(0, 0, 0, 0.9);
+                padding: 10px;
+                background-color: #eee;
+                font-size: 12px;
+            }
+            
+            div.type-container {
+                overflow-y: auto;
+                height: 415px;
+                border-bottom: 1px solid #ccc;
+            }
+            
+            div.close {
+                border: 1px solid #aaa;
+                background-color: #ddd;
+                float: right;
+                margin-top: 10px;
+                font-weight: bold;
+                height: 25px;
+                line-height: 25px;
+                padding: 0 10px;
+                cursor: pointer;
+            }
+            
+            div.close:hover {
+                background-color: #d1d1d1;
+            }
+            
+            div.section-header > div.title {
+                font-size: 24px;
+                float: left;
+            }
+            
+            div.section-description {
+                float: right;
+                margin-top: 10px;
+            }
+            
+            div.section-endpoints {
+                margin-top: 10px;
+            }
+            
+            /* tables */
+
+            table {
+                background-color: #fefefe;
+                border: 1px solid #ccc;
+                border-left: 6px solid #ccc;
+                color: #555;
+                display: block;
+                margin-bottom: 12px;
+                padding: 5px 8px;
+            }
+            
+            table th {
+                font-weight: bold;
+                vertical-align:top;
+                text-align:left;
+                padding: 4px 15px;
+                border-width: 0;
+                white-space: nowrap;
+            }
+            
+            table td {
+                vertical-align:top;
+                text-align:left;
+                padding: 2px 15px;
+                border-width: 0;
+                white-space: nowrap;
+            }
+            
+            table td:last-child {
+                width: 99%;
+                white-space: normal;
+            }
+            
+            code.example {
+                background-color: #fefefe;
+                border: 1px solid #ccc;
+                border-left: 6px solid #ccc;
+                color: #555;
+                margin-bottom: 10px;
+                padding: 5px 8px;
+                white-space: pre;
+                display: block;
+                tab-size: 4;
+                -moz-tab-size: 4;
+                -o-tab-size: 4;
+                line-height: 20px
+            }
+            
+            span.nested.collapsed {
+                cursor: pointer;
+                border: 1px solid #7298AC;
+                background-color: rgba(114, 152, 172, .15);
+                padding: 1px;
+            }
+            
+            /* general */
+            
+            .mono {
+                font-family: monospace;
+            }
+            
+            div.clear {
+                clear: both;
+            }
+
+            .hidden {
+                display: none;
+            }
+            
+            a, .link {
+                cursor: pointer;
+                color: #1e373f;
+                font-weight: normal;
+            }
+            
+            a:hover, .link:hover {
+                color: #264c58;
+                text-decoration: underline;
+            }
+        </style>
+        <script type="text/javascript">
+            $(document).ready(function () {
+                // hide any open type dialogs
+                $('html').on('click', function() {
+                    $('div.type').hide();
+                }).on('keydown', function(e) {
+                    if (e.which === 27) {
+                        $('div.type').hide();
+                    }
+                });
+                
+                // populate all paths - this is necessary because the @key
+                // doesn't seem to reset after iterating through a nested 
+                // array or object
+                $('span.path').each(function() {
+                    var path = $(this);
+                    var endpoint = path.parent();
+                    endpoint.find('div.path').text(path.text());
+                });
+                
+                // toggles the visibility of a given operation
+                $('div.operation-handle').on('click', function () {
+                    $(this).next('div.operation').slideToggle();
+                });
+                
+                // add support for clicking to view the definition of a type
+                $('a.type-link').on('click', function(e) {
+                    // hide any previously shown dialogs
+                    $('div.type').hide();
+
+                    // show the type selected
+                    var link = $(this);
+                    var typeId = link.text();
+                    $('#' + typeId).show();
+                    e.stopPropagation();
+                });
+                
+                // prevent hiding when clicking on the type dialog
+                $('div.type').on('click', function(e) {
+                    e.stopPropagation();
+                });
+                
+                // due to lack of support for @last when iterating objects in 
+                // handlebars we need to remove the last comma from each 
example
+                $('code.example').find('span.comma:last').remove();
+                
+                // populate nested examples
+                $('code.example').on('click', 'span.nested', function(e) {
+                    var nested = $(this).removeClass('collapsed');
+                    var nestedId = nested.find('span.nested-id');
+                    var nestedExample = nested.find('span.nested-example');
+                    
+                    // get the id of the nested example
+                    var typeId = nestedId.text();
+                    var example = $('#' + typeId + ' code.example').html();
+                    var depth = nestedId.parents('span.open-object').length;
+                    
+                    // tab over as appropriate
+                    example = example.replace(/(\r\n|\r|\n)/g, function(match) 
{
+                        var tab = '\t';
+                        for (var i = 0; i < depth - 1; i++) {
+                            tab += '\t';
+                        }
+                        return match + tab;
+                    });
+                    
+                    // copy over the example
+                    nestedExample.html(example);
+                    e.stopPropagation();
+                });
+                
+                // handle close button
+                $('div.close').on('click', function() {
+                    $(this).closest('div.type').hide();
+                });
+                
+                // function for organizing the endpoints
+                var organizeEndpoints = function(term, container) {
+                    $('div.unorganized > div.endpoints').each(function() {
+                        var endpoints = $(this);
+                        var path = endpoints.find('div.path').text();
+                        
+                        if (term === null || path.indexOf(term) > 0) {
+                            endpoints.detach().appendTo(container);
+                        }
+                    });
+                };
+                
+                // organize the endpoints
+                organizeEndpoints('cluster', $('#cluster-endpoints'));
+                organizeEndpoints('provenance', $('#provenance-endpoints'));
+                organizeEndpoints('user', $('#user-endpoints'));
+                organizeEndpoints('controller-services', 
$('#controller-service-endpoints'));
+                organizeEndpoints('reporting-tasks', 
$('#reporting-task-endpoints'));
+                organizeEndpoints('connections', $('#connection-endpoints'));
+                organizeEndpoints('processors', $('#processor-endpoints'));
+                organizeEndpoints('funnels', $('#funnel-endpoints'));
+                organizeEndpoints('remote-process-groups', 
$('#remote-process-group-endpoints'));
+                organizeEndpoints('input-ports', $('#input-port-endpoints'));
+                organizeEndpoints('output-ports', $('#output-port-endpoints'));
+                organizeEndpoints('labels', $('#label-endpoints'));
+                organizeEndpoints('process-groups', 
$('#process-group-endpoints'));
+                organizeEndpoints('history', $('#history-endpoints'));
+                organizeEndpoints(null, $('#controller-endpoints'));
+                
+                
+                // handle expanding/collapsing the sections
+                $('div.section-header > div.title').on('click', function() {
+                    
$(this).parent('div.section-header').next('div.section-endpoints').slideToggle();
+                });
+            });
+        </script>
+    </head>
+    <body>
+        <div class="header">
+            <img class="logo" src="images/bgNifiLogo.png" alt="NiFi Logo"/>
+            <div class="title">{{basePath}}</div>
+            <div class="sub-title">{{info.title}} {{info.version}}</div>
+            <div class="clear"></div>
+        </div>
+        <div class="clear"></div>
+        <div class="overview">{{info.description}}</div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Controller</div>
+                <div class="sub-title section-description">Get controller 
configuration, Search the flow, Manage templates, System diagnostics</div>
+                <div class="clear"></div>
+            </div>
+            <div id="controller-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Process Groups</div>
+                <div class="sub-title section-description">Get the flow, 
Instantiate a template, Manage sub groups, Monitor component status</div>
+                <div class="clear"></div>
+            </div>
+            <div id="process-group-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Processors</div>
+                <div class="sub-title section-description">Create a processor, 
Set properties, Schedule</div>
+                <div class="clear"></div>
+            </div>
+            <div id="processor-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Connections</div>
+                <div class="sub-title section-description">Create a 
connection, Set queue priority, Update connection destination</div>
+                <div class="clear"></div>
+            </div>
+            <div id="connection-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Input Ports</div>
+                <div class="sub-title section-description">Create an input 
port, Set remote port access control</div>
+                <div class="clear"></div>
+            </div>
+            <div id="input-port-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Output Ports</div>
+                <div class="sub-title section-description">Create an output 
port, Set remote port access control</div>
+                <div class="clear"></div>
+            </div>
+            <div id="output-port-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Remote Process Groups</div>
+                <div class="sub-title section-description">Create a remote 
group, Enable transmission</div>
+                <div class="clear"></div>
+            </div>
+            <div id="remote-process-group-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Labels</div>
+                <div class="sub-title section-description">Create a label, Set 
label style</div>
+                <div class="clear"></div>
+            </div>
+            <div id="label-endpoints" class="section-endpoints hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Funnels</div>
+                <div class="sub-title section-description">Manage funnels</div>
+                <div class="clear"></div>
+            </div>
+            <div id="funnel-endpoints" class="section-endpoints hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Controller Services</div>
+                <div class="sub-title section-description">Manage controller 
services, Update controller service references</div>
+                <div class="clear"></div>
+            </div>
+            <div id="controller-service-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Reporting Tasks</div>
+                <div class="sub-title section-description">Manage reporting 
tasks</div>
+                <div class="clear"></div>
+            </div>
+            <div id="reporting-task-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Cluster</div>
+                <div class="sub-title section-description">View node status, 
Disconnect nodes, Aggregate component status</div>
+                <div class="clear"></div>
+            </div>
+            <div id="cluster-endpoints" class="section-endpoints hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Provenance</div>
+                <div class="sub-title section-description">Query provenance, 
Search event lineage, Download content, Replay</div>
+                <div class="clear"></div>
+            </div>
+            <div id="provenance-endpoints" class="section-endpoints 
hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">History</div>
+                <div class="sub-title section-description">View flow history, 
Purge flow history</div>
+                <div class="clear"></div>
+            </div>
+            <div id="history-endpoints" class="section-endpoints hidden"></div>
+        </div>
+        <div class="section">
+            <div class="section-header">
+                <div class="title link">Users</div>
+                <div class="sub-title section-description">Update user access, 
revoke accounts, get account details, Group users</div>
+                <div class="clear"></div>
+            </div>
+            <div id="user-endpoints" class="section-endpoints hidden"></div>
+        </div>
+        <div class="unorganized hidden">
+            {{#each paths}}
+                {{> endpoint}}
+            {{/each}}
+        </div>
+        {{#each definitions}}
+            {{> type}}
+        {{/each}}
+    </body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/operation.hbs
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/operation.hbs
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/operation.hbs
new file mode 100644
index 0000000..5fb25e7
--- /dev/null
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/operation.hbs
@@ -0,0 +1,104 @@
+{{!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You 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.
+--}}
+<div class="operation hidden">
+    {{#if description}}
+    <div class="description">
+        {{description}}
+    </div>
+    {{/if}}
+    <div class="title">Request</div>
+    <div class="mediatypes details">
+        {{#if consumes}}
+        <div class="mediatype"><div class="title">consumes:</div><div 
class="mono">{{join consumes ", "}}</div><div class="clear"></div></div>
+        {{/if}}
+    </div>
+    {{#if parameters}}
+    <table>
+        <thead>
+            <tr>
+                <th>Name</th>
+                <th>Location</th>
+                <th>Type</th>
+                <th>Description</th>
+            </tr>
+        </thead>
+        <tbody>
+    {{/if}}
+    {{#each parameters}}
+        <tr>
+            <td>{{#ifeq in "body"}}{{else}}{{name}}{{/ifeq}}</td>
+            <td>{{in}}</td>
+            {{#ifeq in "body"}}
+                <td>
+                {{#ifeq schema.type "array"}}Array[<a class="type-link" 
href="javascript:void(0);">{{basename schema.items.$ref}}</a>]{{/ifeq}}
+                {{#schema.$ref}}<a class="type-link" 
href="javascript:void(0);">{{basename schema.$ref}}</a> {{/schema.$ref}}
+                </td>
+            {{else}}
+                {{#ifeq type "array"}}
+                        <td>Array[{{items.type}}] ({{collectionFormat}})</td>
+                {{else}}
+                    {{#ifeq type "ref"}}
+                        <td>string</td>
+                    {{else}}
+                        <td>{{type}} {{#format}}({{format}}){{/format}}</td>
+                    {{/ifeq}}
+                {{/ifeq}}
+            {{/ifeq}}
+            <td>{{description}}</td>
+        </tr>
+    {{/each}}
+    {{#if parameters}}
+        </tbody>
+    </table>
+    {{/if}}
+    <div class="title">Response</div>
+    <div class="mediatypes details">
+        {{#if produces}}
+        <div class="mediatype"><div class="title">produces:</div><div 
class="mono">{{join produces ", "}}</div><div class="clear"></div></div>
+        {{/if}}
+    </div>
+    <table>
+        <thead>
+            <tr>
+                <th>Status Code</th>
+                <th>Type</th>
+                <th>Description</th>
+            </tr>
+        </thead>
+        <tbody>
+            {{#each responses}}
+            <tr>
+                <td>{{@key}}</td>
+                <td>
+                    {{#if schema}}
+                        {{#schema.$ref}}<a class="type-link" 
href="javascript:void(0);">{{basename schema.$ref}}</a>{{/schema.$ref}}
+                    {{else}}
+                        string
+                    {{/if}}
+                </td>
+                <td>{{description}}</td>
+            </tr>
+            {{/each}}
+        </tbody>
+    </table>
+    <div class="title">Authorization</div>
+    <div class="authorization details">
+        {{#security}}
+            {{#each this}}
+            <div>{{@key}}</div>
+            {{/each}}
+        {{/security}}
+    </div>
+</div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/type.hbs
----------------------------------------------------------------------
diff --git 
a/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/type.hbs
 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/type.hbs
new file mode 100644
index 0000000..d64610d
--- /dev/null
+++ 
b/nifi/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/resources/templates/type.hbs
@@ -0,0 +1,55 @@
+{{!--
+    Licensed to the Apache Software Foundation (ASF) under one or more
+    contributor license agreements.  See the NOTICE file distributed with
+    this work for additional information regarding copyright ownership.
+    The ASF licenses this file to You 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.
+--}}
+<div id="{{@key}}" class="type hidden">
+    <h3>{{@key}}</h3>
+    <div class="type-container">
+        <table>
+            <tr>
+                <th>Name</th>
+                <th>Type</th>
+                <th>Required</th>
+                <th>Description</th>
+            </tr>
+            {{#each properties}}
+                <tr>
+                    <td>{{@key}}</td>
+                    <td>
+                        {{#ifeq type "array"}}
+                            {{#items.$ref}}
+                                {{type}}[<a class="type-link" 
href="javascript:void(0);">{{basename items.$ref}}</a>]
+                            {{/items.$ref}}
+                            {{^items.$ref}}
+                                {{type}}[{{items.type}}]
+                            {{/items.$ref}}
+                        {{else}}
+                            {{#$ref}}
+                                <a class="type-link" 
href="javascript:void(0);">{{basename $ref}}</a>
+                            {{/$ref}}
+                            {{^$ref}}
+                                {{type}}{{#format}} ({{format}}){{/format}}
+                            {{/$ref}}
+                        {{/ifeq}}
+                    </td>
+                    
<td>{{#required}}required{{/required}}{{^required}}optional{{/required}}</td>
+                    <td>{{#description}}{{{description}}}{{/description}}{{#if 
enum}} Allowable values: {{join enum ", "}}{{/if}}</td>
+                </tr>
+            {{/each}}
+        </table>
+        <h4>Example JSON</h4>
+        <code class="example"><span class="open-object">&#123;{{> 
example}}&#125;</span></code>
+    </div>
+    <div class="close">Close</div>
+    <div class="clear"></div>
+</div>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-nifi/blob/997ed946/nifi/pom.xml
----------------------------------------------------------------------
diff --git a/nifi/pom.xml b/nifi/pom.xml
index ec23e83..7444403 100644
--- a/nifi/pom.xml
+++ b/nifi/pom.xml
@@ -124,7 +124,12 @@
                 <groupId>org.antlr</groupId>
                 <artifactId>antlr-runtime</artifactId>
                 <version>3.5.2</version>
-            </dependency>
+            </dependency> 
+            <dependency>
+                <groupId>com.wordnik</groupId>
+                <artifactId>swagger-annotations</artifactId>
+                <version>1.5.3-M1</version>
+            </dependency> 
             <dependency>
                 <groupId>commons-codec</groupId>
                 <artifactId>commons-codec</artifactId>

Reply via email to