Progressable bar for Servoy Web Client in Servoy 6.1

Hi All,

I require a progress bar functionality in my current project . The JProgress bar is a swing component . It is working fine in the Servoy’s Smart Client . But it will not work in the web client . My functionality is such like , I am uploading a file . During uploading the file , it should update the Progress bar . Actually I was trying to implement such functionality using the Jquery Progress bar . The Web Page is not updating untill the file upload is completed . How can I achieve this ? . Will in servoy 6.1 , there will be some progressable bar compatible for Web Client ? .

Please provide some valuable informations on this.

Thanks,
Ashutos.

Similar post answer: viewtopic.php?f=34&t=18272

With that said, in the file streaming monitor method you could trigger a client-side javascript method to update your progress bar periodically. Use the web client utils plugin to trigger the client-side javascript.

Unfortunately the communication channel between server and web client is now a unique channel (one way or the other).

If your method is waiting for a response from a first call, the server will not be able to communicate with the client until the first method is finished.

The methods are QUEUED and executed in order.

So until your download/upload is finished, the web client utils plugin will not be able to execute client side JavaScript. This sucks since at least october 2011 and an update of the Wicket lib.

The busy plugin is suffering from the same problem, and I’ve been jumping a lot of hoops to make a simple cancel callback to the server working more or less reliably (basically exposing a servlet that is called by the cancel button, which is updating a boolean stored in a ConcurrentHashMap in a server plugin, which is called using RMI by the client plugin when you check for busy.plugins.isCanceled()).

Meaning: there’s currently no solution to update the web client from a server callback during a process that has been initiated by the client. The update will always happen AFTER the first method call has finished.

Oi, past couple of months we’ve been converting everything over to web client with 6.1. Finally web client and css works well enough not to feel like we’re hacking through the Great Wall of China to make standard tools work. But without the web client utils plugin, things would still be a no-go (web client utils should be a standard plugin in Servoy).

I just assumed after doing our web client testing with Servoy 5.2 this was still possible. Hmmm…sincerely hope you can figure out a way around this one…or we may have to do our file uploaders with a 3rd party tool hooked into Servoy.

A temporary workaround is to show a client-side spinner when you start a method and then hide it when done. We do this for various things with short load/refresh times so not my preferred solution when needing to show progress for a longer process.

We do this by showing the client-side spinner with a web utils call to client-side js, then put all the heavy lifting code in the callback method of the web utils call, at the end of which we hide the spinner with another web utils call to client-side js.

Good luck figuring out a better solution! Much appreciated.

I’ve been banging my head with this new limitation since I first encountered it in October 2011 and changed some things in the Busy plugin to workaround it.
Basically for a simple boolean update this is hell enough to forget about doing more complex interactions. You spinner idea is the only possible option I can imagine, but this is basically showing an ‘indeterminate’ progress.
So, good luck to you to find a better solution: the limitation is deep in Servoy and Wicket code.

Case #2375

The Servoy bug reporter site has some sort of progress bar, when uploading attachments. I know that is different sofware (JIRA?), but what are they using?

you can have multiply channels, only not to the same page
Multiple channels that works at the same time for the same page (so same window) will not happen, this will not be allowed by wicket or servoy, because wicket makes sure that everything is single threaded (else wicket application would be much harder to develop if you have to take into account that the same page can be accessed and processed over multiply threads)

But again multiply channels can work fine, the only thing is that you need to use different pages (iframes in html like the modal dialog)
those have an independent channel to the server

So the progress page that you want to show must be in an iframe which is own wicket WebPage that then can query some state out of the session that it displays

In servoy 6.1 we have support for plugins who want to add something to the page a bit easier see for example the WindowPlugin that we have (the new popup code)

IPageContributor pageContributor = ((IWebClientPluginAccess)clientPluginAccess).getPageContributor();
IRepeatingView repeatingView = pageContributor.getRepeatingView();

the WicketPopupShower shows a panel there, but you can also use that to show a special Wicket component that generates an IFrame which in return shows a webpage (with the content your plugin defines, so the progress in this case)

Will be checking out, thx Johan.

Sorry to belabor this but I’m afraid I’m a neophyte…

So it is possible to display a cancellable progress bar on the web, as long as it’s in a separate window or separate frame on the page? I assume that this would apply to batch (looping) operations, as well?

If so, is there any example code? I don’ t know how to place a separate frame on a Servoy form.

I saw that Adrian McGilly had a progress module, and David Workman an example, but both seem to be for Servoy Client?

Thank you,
Don