Class ContentPackResource
java.lang.Object
org.graylog2.shared.rest.resources.RestResource
org.graylog2.rest.resources.system.contentpacks.ContentPackResource
@RequiresAuthentication
@Path("/system/content_packs")
@Produces("application/json")
public class ContentPackResource
extends RestResource
-
Field Summary
Fields inherited from class org.graylog2.shared.rest.resources.RestResource
configuration, userService -
Constructor Summary
ConstructorsConstructorDescriptionContentPackResource(ContentPackService contentPackService, ContentPackPersistenceService contentPackPersistenceService, ContentPackInstallationPersistenceService contentPackInstallationPersistenceService) -
Method Summary
Modifier and TypeMethodDescriptionjavax.ws.rs.core.ResponsecreateContentPack(@NotNull @Valid ContentPack contentPack) voiddeleteContentPack(ModelId contentPackId) voiddeleteContentPack(ModelId contentPackId, int revision) javax.ws.rs.core.ResponsedeleteContentPackInstallationById(ModelId contentPackId, String installationId) downloadContentPackRevisions(ModelId id, int revision) getContentPackRevisions(ModelId id, int revision) installContentPack(ModelId id, int revision, @Valid @NotNull ContentPackInstallationRequest contentPackInstallationRequest) uninstallDetails(ModelId id, String installationId) Methods inherited from class org.graylog2.shared.rest.resources.RestResource
checkAnyPermission, checkPermission, checkPermission, getCurrentUser, getIndexSet, getSubject, getUriBuilderToSelf, isAnyPermitted, isAnyPermitted, isPermitted, isPermitted, setPrettyPrint
-
Constructor Details
-
ContentPackResource
@Inject public ContentPackResource(ContentPackService contentPackService, ContentPackPersistenceService contentPackPersistenceService, ContentPackInstallationPersistenceService contentPackInstallationPersistenceService)
-
-
Method Details
-
listContentPacks
-
listLatestContentPacks
-
listContentPackRevisions
@GET @Path("{contentPackId}") @Timed public ContentPackRevisions listContentPackRevisions(@PathParam("contentPackId") ModelId id) -
getContentPackRevisions
@GET @Path("{contentPackId}/{revision}") @Timed public ContentPackResponse getContentPackRevisions(@PathParam("contentPackId") ModelId id, @PathParam("revision") int revision) -
downloadContentPackRevisions
@GET @Path("{contentPackId}/{revision}/download") @Timed public ContentPack downloadContentPackRevisions(@PathParam("contentPackId") ModelId id, @PathParam("revision") int revision) -
createContentPack
@POST @Timed @Consumes("application/json") public javax.ws.rs.core.Response createContentPack(@NotNull @Valid @NotNull @Valid ContentPack contentPack) -
deleteContentPack
@DELETE @Timed @Path("{contentPackId}") public void deleteContentPack(@PathParam("contentPackId") ModelId contentPackId) -
deleteContentPack
@DELETE @Timed @Path("{contentPackId}/{revision}") public void deleteContentPack(@PathParam("contentPackId") ModelId contentPackId, @PathParam("revision") int revision) -
installContentPack
@POST @Path("{contentPackId}/{revision}/installations") @Timed public ContentPackInstallation installContentPack(@PathParam("contentPackId") ModelId id, @PathParam("revision") int revision, @Valid @NotNull @Valid @NotNull ContentPackInstallationRequest contentPackInstallationRequest) -
listContentPackInstallationsById
@GET @Path("{contentPackId}/installations") @Timed public ContentPackInstallationsResponse listContentPackInstallationsById(@PathParam("contentPackId") ModelId id) -
uninstallDetails
@GET @Path("{contentPackId}/installations/{installationId}/uninstall_details") @Timed public ContentPackUninstallDetails uninstallDetails(@PathParam("contentPackId") ModelId id, @PathParam("installationId") String installationId) -
deleteContentPackInstallationById
-