Search in sources :

Example 51 with SampleSequencingObjectJoin

use of ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin in project irida by phac-nml.

the class SamplesController method getSampleFiles.

/**
 * Get the page that shows the files belonging to that sample.
 *
 * @param model
 *            Spring {@link Model}
 * @param projectId
 *            the id of the {@link Project} the sample is in
 * @param sampleId
 *            Sample id
 * @return a Map representing all files (pairs and singles) for the sample.
 */
@RequestMapping(value = { "/projects/{projectId}/samples/{sampleId}/sequenceFiles" })
public String getSampleFiles(final Model model, @PathVariable Long projectId, @PathVariable Long sampleId) {
    Sample sample = sampleService.read(sampleId);
    model.addAttribute("sampleId", sampleId);
    Collection<SampleSequencingObjectJoin> filePairJoins = sequencingObjectService.getSequencesForSampleOfType(sample, SequenceFilePair.class);
    Collection<SampleSequencingObjectJoin> singleFileJoins = sequencingObjectService.getSequencesForSampleOfType(sample, SingleEndSequenceFile.class);
    Collection<SampleGenomeAssemblyJoin> genomeAssemblyJoins = sampleService.getAssembliesForSample(sample);
    logger.trace("Assembly joins " + genomeAssemblyJoins);
    List<GenomeAssembly> genomeAssemblies = genomeAssemblyJoins.stream().map(SampleGenomeAssemblyJoin::getObject).collect(Collectors.toList());
    List<SequencingObject> filePairs = filePairJoins.stream().map(SampleSequencingObjectJoin::getObject).collect(Collectors.toList());
    // get the project if available
    Project project = null;
    if (projectId != null) {
        project = projectService.read(projectId);
    }
    // add project to qc entries and filter any unavailable entries
    for (SequencingObject f : filePairs) {
        enhanceQcEntries(f, project);
    }
    for (SampleSequencingObjectJoin f : singleFileJoins) {
        enhanceQcEntries(f.getObject(), project);
    }
    // SequenceFile
    model.addAttribute("paired_end", filePairs);
    model.addAttribute("single_end", singleFileJoins);
    // assemblies
    model.addAttribute("assemblies", genomeAssemblies);
    model.addAttribute(MODEL_ATTR_SAMPLE, sample);
    model.addAttribute(MODEL_ATTR_CAN_MANAGE_SAMPLE, isProjectManagerForSample(sample));
    model.addAttribute(MODEL_ATTR_ACTIVE_NAV, ACTIVE_NAV_FILES);
    return SAMPLE_FILES_PAGE;
}
Also used : SampleGenomeAssemblyJoin(ca.corefacility.bioinformatics.irida.model.joins.impl.SampleGenomeAssemblyJoin) Project(ca.corefacility.bioinformatics.irida.model.project.Project) SequencingObject(ca.corefacility.bioinformatics.irida.model.sequenceFile.SequencingObject) Sample(ca.corefacility.bioinformatics.irida.model.sample.Sample) GenomeAssembly(ca.corefacility.bioinformatics.irida.model.assembly.GenomeAssembly) SampleSequencingObjectJoin(ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin)

Example 52 with SampleSequencingObjectJoin

use of ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin in project irida by phac-nml.

the class ProjectExportController method getUploadNcbiPage.

/**
 * Get the page for exporting a given {@link Project} and selected
 * {@link Sample}s
 *
 * @param projectId
 *            The ID of the project to export
 * @param sampleIds
 *            A List of sample ids to export
 * @param model
 *            model for the view to render
 * @return Name of the NCBI export page
 */
@RequestMapping(value = "/projects/{projectId}/export/ncbi", method = RequestMethod.GET)
public String getUploadNcbiPage(@PathVariable Long projectId, @RequestParam("ids[]") List<Long> sampleIds, Model model) {
    Project project = projectService.read(projectId);
    logger.trace("Reading " + sampleIds.size() + " samples");
    Iterable<Sample> samples = sampleService.readMultiple(sampleIds);
    logger.trace("Got samples");
    Set<Long> checkedSingles = new HashSet<>();
    Set<Long> checkedPairs = new HashSet<>();
    List<Map<String, Object>> sampleList = new ArrayList<>();
    for (Sample sample : samples) {
        Map<String, Object> sampleMap = new HashMap<>();
        sampleMap.put("name", sample.getLabel());
        sampleMap.put("id", sample.getId().toString());
        logger.trace("Doing sample " + sample.getId());
        Map<String, List<? extends Object>> files = new HashMap<>();
        Collection<SampleSequencingObjectJoin> singleEndFiles = sequencingObjectService.getSequencesForSampleOfType(sample, SingleEndSequenceFile.class);
        Collection<SampleSequencingObjectJoin> pairedEndFiles = sequencingObjectService.getSequencesForSampleOfType(sample, SequenceFilePair.class);
        List<SingleEndSequenceFile> singleEndFilesForSample = singleEndFiles.stream().map(j -> (SingleEndSequenceFile) j.getObject()).collect(Collectors.toList());
        List<SequenceFilePair> sequenceFilePairsForSample = pairedEndFiles.stream().map(j -> (SequenceFilePair) j.getObject()).collect(Collectors.toList());
        Optional<SequenceFilePair> newestPair = sequenceFilePairsForSample.stream().sorted((f1, f2) -> f2.getCreatedDate().compareTo(f1.getCreatedDate())).findFirst();
        Optional<SingleEndSequenceFile> newestSingle = singleEndFilesForSample.stream().sorted((f1, f2) -> f2.getCreatedDate().compareTo(f1.getCreatedDate())).findFirst();
        if (newestPair.isPresent() && newestSingle.isPresent()) {
            SequenceFilePair sequenceFilePair = newestPair.get();
            SingleEndSequenceFile join = newestSingle.get();
            if (sequenceFilePair.getCreatedDate().after(join.getCreatedDate())) {
                checkedPairs.add(newestPair.get().getId());
            } else {
                checkedSingles.add(newestSingle.get().getId());
            }
        } else {
            if (newestPair.isPresent()) {
                checkedPairs.add(newestPair.get().getId());
            } else if (newestSingle.isPresent()) {
                checkedSingles.add(newestSingle.get().getId());
            }
        }
        files.put("paired_end", sequenceFilePairsForSample);
        files.put("single_end", singleEndFilesForSample);
        sampleMap.put("files", files);
        sampleList.add(sampleMap);
    }
    sampleList.sort(new Comparator<Map<String, Object>>() {

        @Override
        public int compare(Map<String, Object> o1, Map<String, Object> o2) {
            String s1Name = (String) o1.get("name");
            String s2Name = (String) o2.get("name");
            return s1Name.compareTo(s2Name);
        }
    });
    model.addAttribute("project", project);
    model.addAttribute("samples", sampleList);
    model.addAttribute("newestSingles", checkedSingles);
    model.addAttribute("newestPairs", checkedPairs);
    model.addAttribute("instrument_model", NcbiInstrumentModel.values());
    model.addAttribute("library_selection", NcbiLibrarySelection.values());
    model.addAttribute("library_source", NcbiLibrarySource.values());
    model.addAttribute("library_strategy", NcbiLibraryStrategy.values());
    model.addAttribute("defaultNamespace", namespace);
    model.addAttribute("activeNav", "export");
    return NCBI_EXPORT_VIEW;
}
Also used : JsonProperty(com.fasterxml.jackson.annotation.JsonProperty) Builder(ca.corefacility.bioinformatics.irida.model.export.NcbiBioSampleFiles.Builder) java.util(java.util) DTExportSubmission(ca.corefacility.bioinformatics.irida.ria.web.models.datatables.DTExportSubmission) NcbiExportSubmission(ca.corefacility.bioinformatics.irida.model.NcbiExportSubmission) PreAuthorize(org.springframework.security.access.prepost.PreAuthorize) LoggerFactory(org.slf4j.LoggerFactory) Autowired(org.springframework.beans.factory.annotation.Autowired) Controller(org.springframework.stereotype.Controller) ProjectService(ca.corefacility.bioinformatics.irida.service.ProjectService) Value(org.springframework.beans.factory.annotation.Value) Model(org.springframework.ui.Model) DataTablesResponseModel(ca.corefacility.bioinformatics.irida.ria.web.components.datatables.models.DataTablesResponseModel) DataTablesResponse(ca.corefacility.bioinformatics.irida.ria.web.components.datatables.DataTablesResponse) Sort(org.springframework.data.domain.Sort) NcbiExportSubmissionService(ca.corefacility.bioinformatics.irida.service.export.NcbiExportSubmissionService) SequencingObjectService(ca.corefacility.bioinformatics.irida.service.SequencingObjectService) Logger(org.slf4j.Logger) ImmutableMap(com.google.common.collect.ImmutableMap) DataTablesRequest(ca.corefacility.bioinformatics.irida.ria.web.components.datatables.config.DataTablesRequest) SequenceFilePair(ca.corefacility.bioinformatics.irida.model.sequenceFile.SequenceFilePair) ca.corefacility.bioinformatics.irida.model.export(ca.corefacility.bioinformatics.irida.model.export) Sample(ca.corefacility.bioinformatics.irida.model.sample.Sample) SampleSequencingObjectJoin(ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin) Page(org.springframework.data.domain.Page) Collectors(java.util.stream.Collectors) Project(ca.corefacility.bioinformatics.irida.model.project.Project) Principal(java.security.Principal) UserService(ca.corefacility.bioinformatics.irida.service.user.UserService) org.springframework.web.bind.annotation(org.springframework.web.bind.annotation) User(ca.corefacility.bioinformatics.irida.model.user.User) SampleService(ca.corefacility.bioinformatics.irida.service.sample.SampleService) SingleEndSequenceFile(ca.corefacility.bioinformatics.irida.model.sequenceFile.SingleEndSequenceFile) DataTablesParams(ca.corefacility.bioinformatics.irida.ria.web.components.datatables.DataTablesParams) SingleEndSequenceFile(ca.corefacility.bioinformatics.irida.model.sequenceFile.SingleEndSequenceFile) SequenceFilePair(ca.corefacility.bioinformatics.irida.model.sequenceFile.SequenceFilePair) Sample(ca.corefacility.bioinformatics.irida.model.sample.Sample) Project(ca.corefacility.bioinformatics.irida.model.project.Project) ImmutableMap(com.google.common.collect.ImmutableMap) SampleSequencingObjectJoin(ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin)

Example 53 with SampleSequencingObjectJoin

use of ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin in project irida by phac-nml.

the class PipelineController method getSpecifiedPipelinePage.

/**
 * Get a generic pipeline page.
 *
 * @param model
 *            the the model for the current request
 * @param principal
 *            the user in the current request
 * @param locale
 *            the locale that the user is using
 * @param pipelineId
 *            the pipeline to load
 * @return a page reference or redirect to load.
 */
@RequestMapping(value = "/{pipelineId}")
public String getSpecifiedPipelinePage(final Model model, Principal principal, Locale locale, @PathVariable UUID pipelineId) {
    String response = URL_EMPTY_CART_REDIRECT;
    boolean canUpdateAllSamples;
    Map<Project, Set<Sample>> cartMap = cartController.getSelected();
    // Cannot run a pipeline on an empty cart!
    if (!cartMap.isEmpty()) {
        Authentication authentication = SecurityContextHolder.getContext().getAuthentication();
        IridaWorkflow flow = null;
        try {
            flow = workflowsService.getIridaWorkflow(pipelineId);
        } catch (IridaWorkflowNotFoundException e) {
            logger.error("Workflow not found - See stack:", e);
            return "redirect:errors/not_found";
        }
        // Check if there even is functionality to update samples from results for this pipeline
        canUpdateAllSamples = analysisSubmissionSampleProcessor.hasRegisteredAnalysisSampleUpdater(flow.getWorkflowDescription().getAnalysisType());
        User user = userService.getUserByUsername(principal.getName());
        // Get all the reference files that could be used for this pipeline.
        List<Map<String, Object>> referenceFileList = new ArrayList<>();
        List<Map<String, Object>> projectList = new ArrayList<>();
        List<Map<String, Object>> addRefList = new ArrayList<>();
        IridaWorkflowDescription description = flow.getWorkflowDescription();
        final String workflowName = description.getName().toLowerCase();
        for (Project project : cartMap.keySet()) {
            // Check to see if it requires a reference file.
            if (description.requiresReference()) {
                List<Join<Project, ReferenceFile>> joinList = referenceFileService.getReferenceFilesForProject(project);
                for (Join<Project, ReferenceFile> join : joinList) {
                    referenceFileList.add(ImmutableMap.of("project", project, "file", join.getObject()));
                }
                if (referenceFileList.size() == 0) {
                    if (user.getSystemRole().equals(Role.ROLE_ADMIN) || projectService.userHasProjectRole(user, project, ProjectRole.PROJECT_OWNER)) {
                        addRefList.add(ImmutableMap.of("name", project.getLabel(), "id", project.getId()));
                    }
                }
            }
            Set<Sample> samples = cartMap.get(project);
            Map<String, Object> projectMap = new HashMap<>();
            List<Map<String, Object>> sampleList = new ArrayList<>();
            for (Sample sample : samples) {
                Map<String, Object> sampleMap = new HashMap<>();
                sampleMap.put("name", sample.getLabel());
                sampleMap.put("id", sample.getId().toString());
                Map<String, List<? extends Object>> files = new HashMap<>();
                // Paired end reads
                if (description.acceptsPairedSequenceFiles()) {
                    Collection<SampleSequencingObjectJoin> pairs = sequencingObjectService.getSequencesForSampleOfType(sample, SequenceFilePair.class);
                    files.put("paired_end", pairs.stream().map(SampleSequencingObjectJoin::getObject).collect(Collectors.toList()));
                }
                // Singe end reads
                if (description.acceptsSingleSequenceFiles()) {
                    Collection<SampleSequencingObjectJoin> singles = sequencingObjectService.getSequencesForSampleOfType(sample, SingleEndSequenceFile.class);
                    files.put("single_end", singles.stream().map(SampleSequencingObjectJoin::getObject).collect(Collectors.toList()));
                }
                sampleMap.put("files", files);
                sampleList.add(sampleMap);
            }
            projectMap.put("id", project.getId().toString());
            projectMap.put("name", project.getLabel());
            projectMap.put("samples", sampleList);
            projectList.add(projectMap);
            canUpdateAllSamples &= updateSamplePermission.isAllowed(authentication, samples);
        }
        // Need to add the pipeline parameters
        final List<IridaWorkflowParameter> defaultWorkflowParameters = flow.getWorkflowDescription().getParameters();
        final List<Map<String, Object>> parameters = new ArrayList<>();
        if (defaultWorkflowParameters != null) {
            final List<Map<String, String>> defaultParameters = new ArrayList<>();
            for (IridaWorkflowParameter p : defaultWorkflowParameters) {
                if (p.isRequired()) {
                    continue;
                }
                defaultParameters.add(ImmutableMap.of("label", messageSource.getMessage("pipeline.parameters." + workflowName + "." + p.getName(), null, locale), "value", p.getDefaultValue(), "name", p.getName()));
            }
            parameters.add(ImmutableMap.of("id", DEFAULT_WORKFLOW_PARAMETERS_ID, "label", messageSource.getMessage("workflow.parameters.named.default", null, locale), "parameters", defaultParameters));
            final List<IridaWorkflowNamedParameters> namedParameters = namedParameterService.findNamedParametersForWorkflow(pipelineId);
            for (final IridaWorkflowNamedParameters p : namedParameters) {
                final List<Map<String, String>> namedParametersList = new ArrayList<>();
                for (final Map.Entry<String, String> parameter : p.getInputParameters().entrySet()) {
                    namedParametersList.add(ImmutableMap.of("label", messageSource.getMessage("pipeline.parameters." + workflowName + "." + parameter.getKey(), null, locale), "value", parameter.getValue(), "name", parameter.getKey()));
                }
                parameters.add(ImmutableMap.of("id", p.getId(), "label", p.getLabel(), "parameters", namedParametersList));
            }
            model.addAttribute("parameterModalTitle", messageSource.getMessage("pipeline.parameters.modal-title." + workflowName, null, locale));
        } else {
            model.addAttribute("noParameters", messageSource.getMessage("pipeline.no-parameters", null, locale));
        }
        // Parameters should be added not matter what, even if they are empty.
        model.addAttribute("parameters", parameters);
        model.addAttribute("title", messageSource.getMessage("pipeline.title." + description.getName(), null, locale));
        model.addAttribute("mainTitle", messageSource.getMessage("pipeline.h1." + description.getName(), null, locale));
        model.addAttribute("name", description.getName());
        model.addAttribute("pipelineId", pipelineId.toString());
        model.addAttribute("referenceFiles", referenceFileList);
        model.addAttribute("referenceRequired", description.requiresReference());
        model.addAttribute("addRefProjects", addRefList);
        model.addAttribute("projects", projectList);
        model.addAttribute("canUpdateSamples", canUpdateAllSamples);
        model.addAttribute("workflowName", workflowName);
        model.addAttribute("dynamicSourceRequired", description.requiresDynamicSource());
        final List<Map<String, Object>> dynamicSources = new ArrayList<>();
        if (description.requiresDynamicSource()) {
            TabularToolDataTable galaxyToolDataTable = new TabularToolDataTable();
            IridaWorkflowDynamicSourceGalaxy dynamicSource = new IridaWorkflowDynamicSourceGalaxy();
            for (IridaWorkflowParameter parameter : description.getParameters()) {
                if (parameter.isRequired() && parameter.hasDynamicSource()) {
                    try {
                        dynamicSource = parameter.getDynamicSource();
                    } catch (IridaWorkflowParameterException e) {
                        logger.debug("Dynamic Source error: ", e);
                    }
                    List<Object> parametersList = new ArrayList<>();
                    String dynamicSourceName;
                    Map<String, Object> toolDataTable = new HashMap<>();
                    try {
                        dynamicSourceName = dynamicSource.getName();
                        toolDataTable.put("id", dynamicSourceName);
                        toolDataTable.put("label", messageSource.getMessage("dynamicsource.label." + dynamicSourceName, null, locale));
                        toolDataTable.put("parameters", parametersList);
                        galaxyToolDataTable = galaxyToolDataService.getToolDataTable(dynamicSourceName);
                        List<String> labels = galaxyToolDataTable.getFieldsForColumn(dynamicSource.getDisplayColumn());
                        Iterator<String> labelsIterator = labels.iterator();
                        List<String> values = galaxyToolDataTable.getFieldsForColumn(dynamicSource.getParameterColumn());
                        Iterator<String> valuesIterator = values.iterator();
                        while (labelsIterator.hasNext() && valuesIterator.hasNext()) {
                            String label = labelsIterator.next();
                            String value = valuesIterator.next();
                            HashMap<String, String> toolDataTableFieldsMap = new HashMap<>();
                            toolDataTableFieldsMap.put("label", label);
                            toolDataTableFieldsMap.put("value", value);
                            toolDataTableFieldsMap.put("name", parameter.getName());
                            parametersList.add(toolDataTableFieldsMap);
                        }
                        dynamicSources.add(toolDataTable);
                    } catch (Exception e) {
                        logger.debug("Tool Data Table not found: ", e);
                    }
                }
            }
            model.addAttribute("dynamicSources", dynamicSources);
        }
        response = URL_GENERIC_PIPELINE;
    }
    return response;
}
Also used : ReferenceFile(ca.corefacility.bioinformatics.irida.model.project.ReferenceFile) Set(java.util.Set) User(ca.corefacility.bioinformatics.irida.model.user.User) HashMap(java.util.HashMap) IridaWorkflow(ca.corefacility.bioinformatics.irida.model.workflow.IridaWorkflow) ArrayList(java.util.ArrayList) IridaWorkflowNamedParameters(ca.corefacility.bioinformatics.irida.model.workflow.submission.IridaWorkflowNamedParameters) IridaWorkflowParameterException(ca.corefacility.bioinformatics.irida.exceptions.IridaWorkflowParameterException) IridaWorkflowParameter(ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowParameter) List(java.util.List) ArrayList(java.util.ArrayList) Sample(ca.corefacility.bioinformatics.irida.model.sample.Sample) Join(ca.corefacility.bioinformatics.irida.model.joins.Join) SampleSequencingObjectJoin(ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin) TabularToolDataTable(com.github.jmchilton.blend4j.galaxy.beans.TabularToolDataTable) IridaWorkflowNotFoundException(ca.corefacility.bioinformatics.irida.exceptions.IridaWorkflowNotFoundException) IridaWorkflowParameterException(ca.corefacility.bioinformatics.irida.exceptions.IridaWorkflowParameterException) IOException(java.io.IOException) DuplicateSampleException(ca.corefacility.bioinformatics.irida.exceptions.DuplicateSampleException) IridaWorkflowNotFoundException(ca.corefacility.bioinformatics.irida.exceptions.IridaWorkflowNotFoundException) Project(ca.corefacility.bioinformatics.irida.model.project.Project) Authentication(org.springframework.security.core.Authentication) IridaWorkflowDescription(ca.corefacility.bioinformatics.irida.model.workflow.description.IridaWorkflowDescription) SequencingObject(ca.corefacility.bioinformatics.irida.model.sequenceFile.SequencingObject) Map(java.util.Map) ImmutableMap(com.google.common.collect.ImmutableMap) HashMap(java.util.HashMap) SampleSequencingObjectJoin(ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin) RequestMapping(org.springframework.web.bind.annotation.RequestMapping)

Example 54 with SampleSequencingObjectJoin

use of ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin in project irida by phac-nml.

the class AssemblyFileProcessorTest method testAssemblyDisabled.

@Test
public void testAssemblyDisabled() {
    Long sequenceFileId = 1L;
    SequenceFilePair pair = new SequenceFilePair();
    Sample sample = new Sample();
    Project project = new Project();
    project.setAssembleUploads(false);
    when(objectRepository.findOne(sequenceFileId)).thenReturn(pair);
    when(ssoRepository.getSampleForSequencingObject(pair)).thenReturn(new SampleSequencingObjectJoin(sample, pair));
    when(psjRepository.getProjectForSample(sample)).thenReturn(ImmutableList.of(new ProjectSampleJoin(project, sample, true)));
    assertFalse("processor should not want to assemble file", processor.shouldProcessFile(sequenceFileId));
    verifyZeroInteractions(submissionRepository);
}
Also used : ProjectSampleJoin(ca.corefacility.bioinformatics.irida.model.joins.impl.ProjectSampleJoin) SequenceFilePair(ca.corefacility.bioinformatics.irida.model.sequenceFile.SequenceFilePair) Project(ca.corefacility.bioinformatics.irida.model.project.Project) Sample(ca.corefacility.bioinformatics.irida.model.sample.Sample) SampleSequencingObjectJoin(ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin) Test(org.junit.Test)

Aggregations

SampleSequencingObjectJoin (ca.corefacility.bioinformatics.irida.model.sample.SampleSequencingObjectJoin)54 Sample (ca.corefacility.bioinformatics.irida.model.sample.Sample)45 SequenceFile (ca.corefacility.bioinformatics.irida.model.sequenceFile.SequenceFile)30 SingleEndSequenceFile (ca.corefacility.bioinformatics.irida.model.sequenceFile.SingleEndSequenceFile)30 Test (org.junit.Test)29 Project (ca.corefacility.bioinformatics.irida.model.project.Project)21 SequencingObject (ca.corefacility.bioinformatics.irida.model.sequenceFile.SequencingObject)16 ProjectSampleJoin (ca.corefacility.bioinformatics.irida.model.joins.impl.ProjectSampleJoin)14 SequenceFilePair (ca.corefacility.bioinformatics.irida.model.sequenceFile.SequenceFilePair)11 Path (java.nio.file.Path)9 Transactional (org.springframework.transaction.annotation.Transactional)9 ModelMap (org.springframework.ui.ModelMap)9 ArrayList (java.util.ArrayList)8 Join (ca.corefacility.bioinformatics.irida.model.joins.Join)7 AnalysisSubmission (ca.corefacility.bioinformatics.irida.model.workflow.submission.AnalysisSubmission)7 RequestMapping (org.springframework.web.bind.annotation.RequestMapping)7 PreAuthorize (org.springframework.security.access.prepost.PreAuthorize)6 MockHttpServletResponse (org.springframework.mock.web.MockHttpServletResponse)5 DataAddedToSampleProjectEvent (ca.corefacility.bioinformatics.irida.model.event.DataAddedToSampleProjectEvent)4 User (ca.corefacility.bioinformatics.irida.model.user.User)4