My Delphi 10.4 application uses a HTTPRIO-component to communicates with SOAP REST Server over HTTPS.
It is installed on more then 100 PC's, and it works fine almost everywhere.
However, I now have 2 clients that get the following error:
"Error sending data: (12030). De verbinding met de server is niet normaal beëindigd"
(--> The connection to the server did not end normally )
The user has a Windows 7 Home Premium machine (I have Windows 10 Pro).
Firewall was disabled.
If I copy the complete application-dirctory with all the dll's to my machine everything works fine.
Where should I start looking for a solution?
Which properties of the HTTPRIO-component could have an effect on this behaviour? Or which dll's?
I checked the article Peter Wolf suggested but without succes. (The register-settings should be OK). All the registers are present with the right values, but the windows update could not be installed. Also downloading the stand-alone update KB3140245 fails. It juist says "failed".
any hints are welcome!
kind regards,
Dirk Janssens
Related
We have a application deployed in a Citrix environment. Many workstations can print to the Citrix print server fine via our application, but 2 cannot (this is limited to our application ie MS Word document prints fine). Of the many workstations, 2 with issues are on the same host as other workstations without issues. There are no printing issues with our application on other workstations. The application is published from the same host. Not having a Citrix background not sure how to go about troubleshooting this.
Check that Citrix host (on which users have issues) have the same policies applied comparing to others. In Citrix XenApp 6.0 and higher run AppCenter console and inspect policies and WorkerGroups they applied on.
Secondly, check Citrix host Windows Event Log for printing errors or printer creation errors.
And lastly check print server for received print jobs and their status.
I'm having some serious issues with the Server Push support in Vaadin 7, and it's proving difficult to pin down the problem. I've followed all the steps in the Book of Vaadin on enabling server push, including adding the vaadin-push.jar file to WEB-INF/lib, adding the "asyncSupported = true" parameter to the #WebServlet annotation, and adding the #Push annotation to the UI class. (I've also tried specifying the equivalent in the deployment descriptor.) I also added the org.atmosphere.useWebSocketAndServlet3=true property to the catalina.properties file of my Tomcat 7 server, as suggested in https://vaadin.com/wiki/-/wiki/Main/Working%20around%20push%20issues.
I found the Server Push support to be very quirky, making it difficult to identify the problem. For instance, when developing code, the server will often not automatically re-start; only recognizing new code when I close the browser (not just the browser window), stop the server and re-start Eclipse; missing any of these steps will result in the Server Push not working. Note that this issue only occurs when Server Push is enabled. I read something about sessions not expiring when push is enabled (https://vaadin.com/forum#!/thread/3576361), so maybe that's the reason..
I often encounter suspicious log messages:
Mar 02, 2014 9:25:45 PM com.vaadin.server.communication.PushHandler$3 run
WARNING: Could not find push connection to close: 38450652-2a2b-4221-8300-8313e9c4779a with
transport WEBSOCKET
Mar 02, 2014 9:25:45 PM org.apache.catalina.loader.WebappClassLoader loadClass
INFO: Illegal access: this web application instance has been stopped already. Could not load
java.nio.ByteBuffer.
It does seem that the Atmosphere is finding the async support:
INFO: Atmosphere is using async support:
org.atmosphere.container.Tomcat7AsyncSupportWithWebSocket running under container: Apache
Tomcat/7.0.47
I also found this error; don't know whether it indicates a serious problem (haven't tried resolving it, since I don't want to get into the Atmosphere stuff):
WARNING: No BroadcasterCache configured. Broadcasted message between client reconnection will be
LOST. It is recommended to configure the org.atmosphere.cache.UUIDBroadcasterCache
That said, Firefox works quite well with the Server Push, while Chrome has problems and IE spews errors (surprise!). In particular, Chrome often takes quite a while to communicate a UI interaction (e.g., button push) to the server, whereby a spinner (changing color from yellow to orange to red) appears at the right top. IE simply updates the wrong UI components when multiple windows are open. So, as long as every user employs Firefox there's no problem, but I can't possibly assume that.
I came across this post, where developers vented their frustration on the feature: https://vaadin.com/forum#!/thread/4040408. This is quite a recent post, so it doesn't sound too promising.. The only reason I need the Server Push feature is to allow the ChatBox add-on (https://vaadin.com/directory/-/directory/addon/chatbox) to update in real-time.
Any ideas? Has anyone gotten these kinds of errors and managed to get some workaround? Or even better, has anyone gotten the ChatBox add-on to work with the Server Push?
Thanks,
William
Try Again
Web Push is still a young technology, especially the WebSocket variety. Tomcat for example replaced one WebSocket implementation with another. Vaadin’s adoption of the Atmosphere library and all the other work in Vaadin 7 are relatively new. Much has improved in the months following the posting of this Question. I suggest giving Push another try.
Use the latest versions of your web server. For example, both Tomcat 7 & 8 and Jetty have made significant changes in their support of Push and WebSocket.
Use the latest version of Java 8 and Vaadin (7.3.7 now).
No Need For setPollInterval
No need to call UI::setPollInterval as was mentioned in the comments above. That feature uses only one approach to Push.
All you need is the #Push annotation. And a Thread, or better, a ScheduledExecutorService to update the data for display in your app. Using the #Push annotation engages the Atmosphere library. Atmosphere tries multiple techniques of Push, starting with WebSocket, and automatically uses other techniques as a fall-back.
Working Example
I recently (2015-01) posted a working example of Push working in Vaadin 7.3.7 as an answer to another question. My example is purposely minimal, using a single file to replace the MyUI file’s content in a new default Vaadin app project.
I have an application named “LeafTest” which has Server Edition and Client Edition. The server Service is “Mss.exe” which is running under account “stepup” account which I checked from “services.msc” and system configuration is 2003 server 32bit standard edition with SP2. But yesterday means November 20 it suddenly stopped , I don’t know what is the reason behind it.
When I checked my application logs I can see these errors just before it reported service stopped
The entries in event log are
Following error also i can see somewhere
Event ID ( 8500 ) in Source ( LeafTest)
cannot be found. The local computer may not have the necessary registry
information or message DLL files to display messages from a remote computer.
When I go0gled somewhere its mentioning my application may not be installed properly or registered or I need to work with registry. Can any body tell me what will be the reason behind the service stpped by reading logs which i have posted
A service may halt if there is an unhandled exception. Check that you are handling all exceptions. Also, if the service uses any COM objects I have, in the past, had exceptions that could not be caught in my .NET 2.0 applications.
I have been scouring the web for how to solve my problem with grails functional testing using embedded server + ssl, and would very much appreciate any help with the problem I'm having.
We have had good success so far testing our Grails webapp with Firefox using Selenium WebDriver 2. We run functional tests automatically from our Jenkins server (and sometime our local machines) using the functional-test plugin to start and stop our app, and the webdriver plugin in conjunction.
This line:
profile.acceptUntrustedCertificates = true
that is used for the profile of the new Firefox instance has been effective for us in making everything SSL totally valid as far as the browser is concerned during our tests with Firefox.
So, although that setup is working great with Firefox, we still need to run a parallel set of tests for IE 8, but I simply cannot figure out a way for webdriver to deal with the SSL warnings/obstacles of IE 8.
Because we are purely Mac (dev)/Linux (jenkins, etc) here, we run IE 8 in a Win 7 VirtualBox VM. Then from the Win 7 VM instance we run the standalone WebDriver server. It works fine up to the point where the test reaches the SSL part of our webapp, at which point I get the IE SSL warning page, and the test is derailed.
We bought a cheap godaddy SSL cert to use for this very reason, hoping to make IE happy, but I have not been able to figure out a way to make our certificate appear as valid and CA signed one, rather than just self-signed. When I examine the certificate in Chrome for example, it does show my certificate, but also that it is self signed. It's CN is along the lines of testbox.example.com and I have added to /etc/hosts the line: 127.0.0.1 testbox.example.com.
I generated the CSR with java keytool and then imported the resulting signed certificate, and intermediate certificate, cross certificate, etc, per the instructions on the godaddy site. I saw somewhere that grails requires it's keystore to retain the password 123456, which I have done.
I have done SSL configs successfully for regular servers, e.g. standalone glassfish and tomcat, but I have just really hit a wall on this issue.
Thanks!
Jamie
Another aproach:
You mentioned that changes in the IE settings don't work since the WebDriver creates a new IE instance.
IE stores a lot of settings in the windows registry. So "IE registry certificate" could be a good start to google your problem. Here is one promising result:
http://www.ehow.com/how_5024374_fix-certificate-error-internet-explorer.html
Since you run your IE in a virtual machine, I guess it is OK to disable the IE security features on this vm. Otherwise I have to admit that it's not a good idea to disable such a security feature by default.
For testing just install your certificate into IE 8.
See What do I need to do to get Internet Explorer 8 to accept a self signed certificate?
I know it's not a very clean solution, but out IE8 displays a warning that something is wrong with the certificate. This warning itself is a valid HTML page and your are able to click the link which says something like "ignore this, display the page".
You only have to this once for a session. So we simple have a small step in our tests which checks after invoking the first page if we get the error message. If yes, we automatically click the link and the rest works fine.
Again: I know it's not a clean solution. But it works for us. And having to configure the java keystores the right way can be a pain. :-)
I have created a Delphi Service which prints TQuickReports. Everything works fine if compiled and run as a Windows Application. But when converted to operate as a service trying to create a form containing a TQuickRep component throws the exception.
This service runs fine on many other boxes but not this one in particular. Here are some details:
Using QuickReport version 4.07
Box is a Windows Server 2008 operating system.
Using Delphi 2007
Printer.Printers.Count is returning a positive value. In fact I can list out all of the printers.
I have tried running the service both using Local System Account and Logged on as an Admin.
Is there a default printer set up in session 0? Remember that under Vista / Server 2008 / Windows 7, services run in a separate session. Whether or not the logged-in user has a default printer set is not relevant - it's a per-session setting and doesn't affect session 0.
Can you rewrite the code to gracefully handle that exception and pick a printer to use?
You can solve this problem by creating a new dword UserSelectedDefault with the value: 1 in
HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows\SessionDefaultDevices\Session_ID
Make sure you have a local printer selected.
You might give the user a way to select the printer for the service. The Windows service probably does not have a default printer set.
Set TQuickRep.PrinterSettings.PrinterIndex to set the printer number. Then, TQuickRep.Print to print the report.
A colleague ended up finding the solution. I should have added these are "network" printers and not Local printers (at the time I didn't think this was related to the problem). So the service needed to be installed with "NetworkService" as the user account under the logon tab. From the Windows Help:
To specify that the service uses the Network Service account, click This account, and
then type NT AUTHORITY\NetworkService
We had a simular problem here. Using TS servers, Citrix and Powerfuse 9.
Powerfuse had all printers capitalized, however they were shared in a mixed case.
This combination caused Delphi/QReport to crash
When all printers are from printserver to powerfuse in the same case (not important upper or lower or even mixed), the problem was gone
Actually it is a Delphi(5) problem. The comparison of the available printers and the default printer is case sensitive (Printers.pas):
if TPrinterDevice(Objects[I]).Device = Device then
begin
with TPrinterDevice(Objects[I]) do
SetPrinter(PChar(Device), PChar(Driver), PChar(Port), 0);
Exit;
end;
Changing the comparison to:
if lowercase(TPrinterDevice(Objects[I]).Device) = lowercase(Device)
solves the problem.
If using terminal services 2008, same user for multiple sessions, you should look into the:
HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows\SessionDefaultDevices\Session_ID
instead of
HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Windows\
I solved a similar problem: If a Delphi application (or service) uses QuickReport, it runs before the system loads the default printer (or printers).
When QuickReport executes TQRPrinter.Init, the printer.printers.count is zero,
shortly after the system loads, the printer.printers.count is the number of printers,
but tqrprinter.int has already executed, so TQRPrinter.FPrinterOK is false,
you then see this error when you try open a QuickReport.
The solution for me was wait until the printers were loaded before launching the application (in citrix and terminal server). I solved this in two ways, either by overwriting tqrprinter or delay the dpr.