@Path(value="/streams") public class StreamResource extends RestResource
| Modifier and Type | Field and Description |
|---|---|
protected static com.google.common.collect.ImmutableMap<String,SearchQueryField> |
SEARCH_FIELD_MAPPING |
configuration, userService| Constructor and Description |
|---|
StreamResource(StreamService streamService,
PaginatedStreamService paginatedStreamService,
StreamRuleService streamRuleService,
StreamRouterEngine.Factory streamRouterEngineFactory,
IndexSetRegistry indexSetRegistry,
AlarmCallbackConfigurationService alarmCallbackConfigurationService,
AlertService alertService) |
| Modifier and Type | Method and Description |
|---|---|
javax.ws.rs.core.Response |
cloneStream(String streamId,
@Valid @NotNull CloneStreamRequest cr,
UserContext userContext) |
javax.ws.rs.core.Response |
create(CreateStreamRequest cr,
UserContext userContext) |
void |
delete(String streamId) |
StreamListResponse |
get()
Deprecated.
|
StreamResponse |
get(@NotEmpty String streamId) |
StreamListResponse |
getEnabled() |
StreamPageListResponse |
getPage(int page,
int perPage,
String query,
String sort,
String order) |
void |
pause(@NotEmpty String streamId) |
void |
resume(@NotEmpty String streamId) |
TestMatchResponse |
testMatch(String streamId,
@NotNull Map<String,Map<String,Object>> serialisedMessage) |
StreamResponse |
update(String streamId,
@Valid @NotNull UpdateStreamRequest cr) |
checkAnyPermission, checkPermission, checkPermission, getCurrentUser, getIndexSet, getSubject, getUriBuilderToSelf, isAnyPermitted, isAnyPermitted, isPermitted, isPermitted, setPrettyPrintprotected static final com.google.common.collect.ImmutableMap<String,SearchQueryField> SEARCH_FIELD_MAPPING
@Inject public StreamResource(StreamService streamService, PaginatedStreamService paginatedStreamService, StreamRuleService streamRuleService, StreamRouterEngine.Factory streamRouterEngineFactory, IndexSetRegistry indexSetRegistry, AlarmCallbackConfigurationService alarmCallbackConfigurationService, AlertService alertService)
@POST @Timed @Consumes(value="application/json") @Produces(value="application/json") public javax.ws.rs.core.Response create(CreateStreamRequest cr, @Context UserContext userContext) throws ValidationException
ValidationException@GET @Timed @Path(value="/paginated") @Produces(value="application/json") public StreamPageListResponse getPage(@QueryParam(value="page") @DefaultValue(value="1") int page, @QueryParam(value="per_page") @DefaultValue(value="50") int perPage, @QueryParam(value="query") @DefaultValue(value="") String query, @DefaultValue(value="title") @QueryParam(value="sort") String sort, @DefaultValue(value="asc") @QueryParam(value="order") String order)
@GET @Timed @Deprecated @Produces(value="application/json") public StreamListResponse get()
@GET @Path(value="/enabled") @Timed @Produces(value="application/json") public StreamListResponse getEnabled() throws NotFoundException
NotFoundException@GET
@Path(value="/{streamId}")
@Timed
@Produces(value="application/json")
public StreamResponse get(@PathParam(value="streamId") @NotEmpty
@NotEmpty String streamId)
throws NotFoundException
NotFoundException@PUT
@Timed
@Path(value="/{streamId}")
@Consumes(value="application/json")
@Produces(value="application/json")
public StreamResponse update(@PathParam(value="streamId")
String streamId,
@Valid @NotNull
@Valid @NotNull UpdateStreamRequest cr)
throws NotFoundException,
ValidationException
NotFoundExceptionValidationException@DELETE
@Path(value="/{streamId}")
@Timed
public void delete(@PathParam(value="streamId")
String streamId)
throws NotFoundException
NotFoundException@POST
@Path(value="/{streamId}/pause")
@Timed
public void pause(@PathParam(value="streamId") @NotEmpty
@NotEmpty String streamId)
throws NotFoundException,
ValidationException
NotFoundExceptionValidationException@POST
@Path(value="/{streamId}/resume")
@Timed
public void resume(@PathParam(value="streamId") @NotEmpty
@NotEmpty String streamId)
throws NotFoundException,
ValidationException
NotFoundExceptionValidationException@POST
@Path(value="/{streamId}/testMatch")
@Timed
public TestMatchResponse testMatch(@PathParam(value="streamId")
String streamId,
@NotNull
@NotNull Map<String,Map<String,Object>> serialisedMessage)
throws NotFoundException
NotFoundException@POST
@Path(value="/{streamId}/clone")
@Timed
@Consumes(value="application/json")
@Produces(value="application/json")
public javax.ws.rs.core.Response cloneStream(@PathParam(value="streamId")
String streamId,
@Valid @NotNull
@Valid @NotNull CloneStreamRequest cr,
@Context
UserContext userContext)
throws ValidationException,
NotFoundException
ValidationExceptionNotFoundExceptionCopyright © 2012–2021 Graylog, Inc.. All rights reserved.