Page 1 of 1

ServerCacheMode and Parameters

Posted: Wed Jun 12, 2013 3:24 am
by Werlang
Hello

I've just found that ShowButtonParameters and ServerCacheMode.None are incompatible.
I'd like to set both options.
ShowButtonParameters = to allow end-user parameters
ServerCacheMode.None = this was the only way I've found to allow simultaneous users open the same report without interfere with each other. ServerCacheMode.Page didn't work, and ServerCacheMode.Session can't be used (sessionless webapp).

If I comment out ServerCacheMode, then it works. But I wish both to work together.

Most relevant code below:

Code: Select all

@Html.Stimulsoft().StiMvcViewer(new StiMvcViewerOptions()
{
    Controller = "StiReports",

    ServerCacheMode = StiCacheMode.None,
    ServerTimeout = TimeSpan.FromMinutes(30),

    MenuViewMode = StiWebViewMode.OnePage,
    ShowButtonDesign = false,

    ShowButtonParameters = true
})
What's wrong here?

Thanks

Re: ServerCacheMode and Parameters

Posted: Wed Jun 12, 2013 4:26 am
by Werlang
Not sure, but would this work? What's the side effects of doing this:

ActionResult GetReportSnapshotViewer():

report.ReportGuid = Guid.NewGuid().ToString();

Re: ServerCacheMode and Parameters

Posted: Wed Jun 12, 2013 2:04 pm
by Vladimir
Hello,

If you are using the ServerCacheMode.None option, you must also load the report in the ViewerInteraction action. This action is used to obtain the parameters for the variables panel.
Not sure, but would this work? What's the side effects of doing this:
ActionResult GetReportSnapshotViewer():
report.ReportGuid = Guid.NewGuid().ToString();
Unfortunately, this will not work, because after the report is saved in the cache, it is always taken from there.
We will make revision. If the report parameters are present, separate copies of the report will be saved in cache.

Thank you.

Re: ServerCacheMode and Parameters

Posted: Thu Jun 13, 2013 2:41 pm
by Werlang
Hello Vladimir

I'm not sure about ViewerInteraction you refer?
I've found Interaction and ViewerEvent, can you show me some code of how to properly use? Below is our code.

Code: Select all

        public ActionResult Interaction()
        {
            return StiMvcViewer.InteractionResult(this.HttpContext);
        }

        public ActionResult ViewerEvent()
        {
            return StiMvcViewer.ViewerEventResult(this.HttpContext);
        }

Re: ServerCacheMode and Parameters

Posted: Fri Jun 14, 2013 2:17 pm
by HighAley
Hello.

Sorry, we need a little more time to prepare an answer for you.

Thank you.

Re: ServerCacheMode and Parameters

Posted: Mon Jun 17, 2013 12:20 pm
by Vladimir
Hello,

We had in mind this action:

Code: Select all

public ActionResult Interaction()
        {
            StiReport report = new StiReport();
            report.Load(...);

            return StiMvcViewer.InteractionResult(this.HttpContext, report);
        }
Alternatively, you can upgrade to the latest prerelease build, in which a problem with the cache should be solved.

Thank you.

Re: ServerCacheMode and Parameters

Posted: Wed Sep 25, 2013 8:07 pm
by allo_man
In your last post, you said the bug with the cache *should* be fixed in the prerelease of june.
Alternatively, you can upgrade to the latest prerelease build, in which a problem with the cache should be solved.
Is it fixed now?

Re: ServerCacheMode and Parameters

Posted: Thu Sep 26, 2013 11:23 am
by Vladimir
Hello,

Yes, this error is fixed.

Thank you.