Packaging/publication services and analysis execution results data providers for Shiny applications#2399
Conversation
| <include>shiny-cohortCounts.zip</include> | ||
| <include>shiny-incidenceRates.zip</include> | ||
| <include>shiny-cohortCharacterizations.zip</include> | ||
| </includes> |
There was a problem hiding this comment.
We should clean 'shiny-cohortPathways.zip' as well
| return dto; | ||
| } | ||
| @Override | ||
| public PathwayPopulationResultsDTO getGenerationResults(Long generationId) { |
There was a problem hiding this comment.
Being extracted from PathwayController
| dataConsumers.getAppProperties().accept("atlas_link", String.format("%s/#/cc/characterizations/%s", atlasUrl, cohortCharacterization.getId())); | ||
| dataConsumers.getAppProperties().accept("analysis_name", cohortCharacterization.getName()); | ||
|
|
||
| generationResults.getReports() |
There was a problem hiding this comment.
For Cohort Characterization Shiny application report listings export CSV interface has been chosen
| import java.util.stream.Collectors; | ||
| import java.util.stream.Stream; | ||
|
|
||
| public abstract class CommonShinyPackagingService { |
There was a problem hiding this comment.
A Javadoc to be added
| } | ||
| } | ||
|
|
||
| public final TemporaryFile packageApp(Integer generationId, String sourceKey, PackagingStrategy packaging) { |
There was a problem hiding this comment.
As Shiny applications template archives shouldn't have data and a manifest file should be extended properly with new file entries and signatures an application package creation takes place on the fly so that a 'data' folder is populated with analysis execution results
| CommonFileUtils.unzipFiles(templateArchive, path.toFile()); | ||
| Path manifestPath = path.resolve("manifest.json"); | ||
| if (!Files.exists(manifestPath)) { | ||
| throw new PositConnectClientException("manifest.json is not found in the Shiny Application"); |
There was a problem hiding this comment.
A malformed or missing manifest.json will result in an error while publishing an application to Posit Connect
|
Notes from demo today on ATLAS WG Call:
|
|
@alex-odysseus I've set up the https://github.com/OHDSI/webapi-shiny to hold the Shiny application templates your team has developed. |
|
Converting this to a draft since the necessary Shiny resources are not yet posted to https://github.com/OHDSI/webapi-shiny |
anthonysena
left a comment
There was a problem hiding this comment.
This looks good but there is a conflict can you resolve @oleg-odysseus?
|
…es while configuring application Docker container with an --env-file
…n the same metadata as used by Atlas
…ishing connect/read/write timeout, no changes/limits to the call timeout), Improved shiny apps code design, eliminated duplicate logic, implemented properties propagation into R apps using a single file app.properties
…ocale formatting of numbers
…the generated filenames to the UI
…nfo parameters for Mean, StdDev, variance calculations
e9d94ac to
d04951a
Compare
…shiny. Eliminated usage of an exception for flow control. Added logging of body prefix on exceptions from Posit server to troubleshoot posit (non-http) error codes
|
Hi @chrisknoll, I`ve resolved the conflicts and ran this branch locally - looks ok to me, please kindly merge this PR along with the Atlas part if you have no objections, thank you. |
Addressing #2349
By default the feature is not enabled
There was a new profile added 'webapi-shiny' so that while building an application it should be specified together with a set property 'shiny.app.directory' pointing to a checked out directory on the build server with the Shiny applications source code (a new OHDSI repository to be created @chrisknoll @anthonysena - https://github.com/OHDSI/webapi-shiny)
mvn clean package -s WebAPIConfig/settings.xml -P webapi-postgresql,webapi-shiny -D shiny.app.directory=D:\\webapi\\checkoutThe following properties to be specified in settings.xml:
A specific Spring profile is activated
<spring.profiles.active>default,shiny</spring.profiles.active>