how to solve 'Disconnected from the server' Problem with shiny app
up vote
0
down vote
favorite
I have a shiny-server Hosted in AWS r5.2xlarge Ubuntu-18.04 Instance, And I'm using It to deploy my work.
One of my Apps uses rpivotTable
pkg to render a big data-frame and i get an error when i try to lunch this app with this data,but its working fine Locally in the server but i get 'Disconnected from the server' when i access to it remotely.
SO i created a date range filter to minimize the data. after that it's worked but when i expand this range i get the error again.
i reviewed the log files and there's no problem with them So any one can help me to solve this problem Or even give my a way to Boost the performance of rpivotTable
rendering using something like Parallel
package ?
This's my App code:
ui <- fluidPage(
theme = shinytheme("cerulean"),
titlePanel("Gross Profit"),
sidebarLayout(
sidebarPanel(
dateRangeInput('dateRange',
label = 'Date range input',
start = max(GrossProfitCube$Date) - 30, end = max(GrossProfitCube$Date)
),br(),
downloadButton('downloadData', 'Download All Data as CSV'), br(),br(),
width = 3
),
mainPanel(
tabsetPanel(
tabPanel("Sales pivot",withSpinner(rpivotTableOutput("pivot")),style = "font-size: 85%; width: 84%")
)
)
)
)
server <- function(input, output, session) {
Data <- reactive({
GrossProfitCube %>% filter(Date >= input$dateRange[1] , Date <= input$dateRange[2])
})
output$pivot <- renderRpivotTable({
rpivotTable(data = Data(), aggregatorName = "Sum", rendererName = "Table"
,hiddenFromAggregators = colnames(GrossProfitCube)[c(1:17)]
,hiddenFromDragDrop = colnames(GrossProfitCube)[c(18:27)]
, width="50%", height="550px")
})
output$downloadData <- downloadHandler(
filename = 'GrossProfit.csv',
content = function(file) {
write.csv(Data(), file)
}
)
session$onSessionEnded(stopApp)
}
shinyApp(ui, server)
r shiny shiny-server
add a comment |
up vote
0
down vote
favorite
I have a shiny-server Hosted in AWS r5.2xlarge Ubuntu-18.04 Instance, And I'm using It to deploy my work.
One of my Apps uses rpivotTable
pkg to render a big data-frame and i get an error when i try to lunch this app with this data,but its working fine Locally in the server but i get 'Disconnected from the server' when i access to it remotely.
SO i created a date range filter to minimize the data. after that it's worked but when i expand this range i get the error again.
i reviewed the log files and there's no problem with them So any one can help me to solve this problem Or even give my a way to Boost the performance of rpivotTable
rendering using something like Parallel
package ?
This's my App code:
ui <- fluidPage(
theme = shinytheme("cerulean"),
titlePanel("Gross Profit"),
sidebarLayout(
sidebarPanel(
dateRangeInput('dateRange',
label = 'Date range input',
start = max(GrossProfitCube$Date) - 30, end = max(GrossProfitCube$Date)
),br(),
downloadButton('downloadData', 'Download All Data as CSV'), br(),br(),
width = 3
),
mainPanel(
tabsetPanel(
tabPanel("Sales pivot",withSpinner(rpivotTableOutput("pivot")),style = "font-size: 85%; width: 84%")
)
)
)
)
server <- function(input, output, session) {
Data <- reactive({
GrossProfitCube %>% filter(Date >= input$dateRange[1] , Date <= input$dateRange[2])
})
output$pivot <- renderRpivotTable({
rpivotTable(data = Data(), aggregatorName = "Sum", rendererName = "Table"
,hiddenFromAggregators = colnames(GrossProfitCube)[c(1:17)]
,hiddenFromDragDrop = colnames(GrossProfitCube)[c(18:27)]
, width="50%", height="550px")
})
output$downloadData <- downloadHandler(
filename = 'GrossProfit.csv',
content = function(file) {
write.csv(Data(), file)
}
)
session$onSessionEnded(stopApp)
}
shinyApp(ui, server)
r shiny shiny-server
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I have a shiny-server Hosted in AWS r5.2xlarge Ubuntu-18.04 Instance, And I'm using It to deploy my work.
One of my Apps uses rpivotTable
pkg to render a big data-frame and i get an error when i try to lunch this app with this data,but its working fine Locally in the server but i get 'Disconnected from the server' when i access to it remotely.
SO i created a date range filter to minimize the data. after that it's worked but when i expand this range i get the error again.
i reviewed the log files and there's no problem with them So any one can help me to solve this problem Or even give my a way to Boost the performance of rpivotTable
rendering using something like Parallel
package ?
This's my App code:
ui <- fluidPage(
theme = shinytheme("cerulean"),
titlePanel("Gross Profit"),
sidebarLayout(
sidebarPanel(
dateRangeInput('dateRange',
label = 'Date range input',
start = max(GrossProfitCube$Date) - 30, end = max(GrossProfitCube$Date)
),br(),
downloadButton('downloadData', 'Download All Data as CSV'), br(),br(),
width = 3
),
mainPanel(
tabsetPanel(
tabPanel("Sales pivot",withSpinner(rpivotTableOutput("pivot")),style = "font-size: 85%; width: 84%")
)
)
)
)
server <- function(input, output, session) {
Data <- reactive({
GrossProfitCube %>% filter(Date >= input$dateRange[1] , Date <= input$dateRange[2])
})
output$pivot <- renderRpivotTable({
rpivotTable(data = Data(), aggregatorName = "Sum", rendererName = "Table"
,hiddenFromAggregators = colnames(GrossProfitCube)[c(1:17)]
,hiddenFromDragDrop = colnames(GrossProfitCube)[c(18:27)]
, width="50%", height="550px")
})
output$downloadData <- downloadHandler(
filename = 'GrossProfit.csv',
content = function(file) {
write.csv(Data(), file)
}
)
session$onSessionEnded(stopApp)
}
shinyApp(ui, server)
r shiny shiny-server
I have a shiny-server Hosted in AWS r5.2xlarge Ubuntu-18.04 Instance, And I'm using It to deploy my work.
One of my Apps uses rpivotTable
pkg to render a big data-frame and i get an error when i try to lunch this app with this data,but its working fine Locally in the server but i get 'Disconnected from the server' when i access to it remotely.
SO i created a date range filter to minimize the data. after that it's worked but when i expand this range i get the error again.
i reviewed the log files and there's no problem with them So any one can help me to solve this problem Or even give my a way to Boost the performance of rpivotTable
rendering using something like Parallel
package ?
This's my App code:
ui <- fluidPage(
theme = shinytheme("cerulean"),
titlePanel("Gross Profit"),
sidebarLayout(
sidebarPanel(
dateRangeInput('dateRange',
label = 'Date range input',
start = max(GrossProfitCube$Date) - 30, end = max(GrossProfitCube$Date)
),br(),
downloadButton('downloadData', 'Download All Data as CSV'), br(),br(),
width = 3
),
mainPanel(
tabsetPanel(
tabPanel("Sales pivot",withSpinner(rpivotTableOutput("pivot")),style = "font-size: 85%; width: 84%")
)
)
)
)
server <- function(input, output, session) {
Data <- reactive({
GrossProfitCube %>% filter(Date >= input$dateRange[1] , Date <= input$dateRange[2])
})
output$pivot <- renderRpivotTable({
rpivotTable(data = Data(), aggregatorName = "Sum", rendererName = "Table"
,hiddenFromAggregators = colnames(GrossProfitCube)[c(1:17)]
,hiddenFromDragDrop = colnames(GrossProfitCube)[c(18:27)]
, width="50%", height="550px")
})
output$downloadData <- downloadHandler(
filename = 'GrossProfit.csv',
content = function(file) {
write.csv(Data(), file)
}
)
session$onSessionEnded(stopApp)
}
shinyApp(ui, server)
r shiny shiny-server
r shiny shiny-server
asked Nov 21 at 13:23
omarahmedm93
187
187
add a comment |
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53413018%2fhow-to-solve-disconnected-from-the-server-problem-with-shiny-app%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown