isapir / lucee-websocket

Enables server WebSockets for Lucee via JSR-356 compliant servlet containers (e.g. Tomcat 8, Jetty 9.1, etc.)
GNU Lesser General Public License v2.1
17 stars 6 forks source link

How do you install version 2.0.2? #12

Open redtopia opened 6 years ago

redtopia commented 6 years ago

It's not clear how this is done. I don't see a corresponding .jar file to replace in the Lucee folder structure on Windows 7. Thanks.

isapir commented 6 years ago

Can't you update it from the Admin like any extension?

You should also be able to download the .lex file for version 2.0.2 from http://download.lucee.org/?type=ext and either drop it in the deploy directory or upload from the Admin extensions page.

redtopia commented 6 years ago

So to install this from the Lucee admin, I need a local file .lex file, correct? I don't see one in the release: https://github.com/isapir/lucee-websocket/releases/tag/2.0.2

isapir commented 6 years ago

You need the .lex file, yes.

OK, I see the source of the confusion. I updated https://github.com/isapir/lucee-websocket/releases/tag/2.0.2 so that it has the same files as 2.0.1 did.

redtopia commented 6 years ago

So just download and install the .lex file? The installer will fetch all the required dependencies?

isapir commented 6 years ago

You should still follow the instructions at https://github.com/isapir/lucee-websocket#installation

I'm working with @michaeloffner to make it easier but until that is implemented in Lucee you should follow those instructions.

If you have installed 2.0.1 before then you already have the servlet filter set up, so all you need is to install the Lucee EXtension (or .lex) file.

If you have not installed 2.0.1 then follow the instructions at the link above and use 2.0.2 wherever you see 2.0.1.

redtopia commented 6 years ago

Still having issues installing. I tried by first downloading the lucee-websocket-extension-2.0.2.lex file and attempting to install this file. I got an error that said: "C:\lucee\tomcat\temp\servlet-filter-utils-1.1.1.jar (The system cannot find the file specified)". So I downloaded that file and put it in the same folder as the .lex file, but that gave me the same error. So I put the servlet-filter-utils-1.1.1.jar in the tomcat temp folder, but again got the same error.

After it failed the first time, it basically uninstalled the extension. Now when I try to install it, it shows me that I can choose v2.0.2, which I choose. But I get the same error.

redtopia commented 6 years ago

I've unsuccessfully tried to install v2.0.2 several times. I finally was able to go back to 1.1.3.1 and then upgraded to 2.0.1. But for some reason, I cannot deploy 2.0.2.

isapir commented 6 years ago

Did you follow the instructions at https://github.com/isapir/lucee-websocket#update-july-14th-2017 ?

So I downloaded that file and put it in the same folder as the .lex file

This is not the right place to put it. From the link above:

Save the jar file servlet-filter-utils-1.1.1.jar to the classpath, e.g. if you're using Tomcat it can go into {tomcat}/lib, or if you're using Jetty then it can go into {jetty}/lib/ext

redtopia commented 6 years ago

Yes, I followed those instructions, and it fails.

isapir commented 6 years ago

So I downloaded that file and put it in the same folder as the .lex file

This is not the place according to the instructions. Please re-read them.

redtopia commented 6 years ago

To be clear, I only did that once to see if it would work. I followed the instructions (july 14th update) multiple times and it fails.

isapir commented 6 years ago

I got an error that said: "C:\lucee\tomcat\temp\servlet-filter-utils-1.1.1.jar (The system cannot find the file specified)"

Where do you see this error?

C:\lucee\tomcat\temp\servlet-filter-utils-1.1.1.jar is obviously some path that was added by you somewhere because it's definitely not in the extension nor on my system, so please find out also where is this path coming from.

redtopia commented 6 years ago

it shows up when I try to update the extension to v.2.0.2 from the server admin. This is just another method that I tried. I don't see any errors when I try to install it though the deploy directory as per your instructions.

redtopia commented 6 years ago

There are no errors and the extension is not installed. I'll be happy to check log files if you tell me which ones to check.

isapir commented 6 years ago

There might be a deploy log but I'm not sure without checking. I'll have to test it myself when I have a moment.

redtopia commented 6 years ago

Just tried it again, and this is what the deploy log says:

"INFO","Thread-1085","09/27/2017","16:40:55","extension","deploy fld lucee-websocket-functions.fld"
"ERROR","Thread-1085","09/27/2017","16:40:56","","Extension;C:\lucee\tomcat\temp\servlet-filter-utils-1.1.1.jar (The system cannot find the file specified);lucee.runtime.exp.NativeException: C:\lucee\tomcat\temp\servlet-filter-utils-1.1.1.jar (The system cannot find the file specified)
    at java.util.zip.ZipFile.open(Native Method)
    at java.util.zip.ZipFile.<init>(ZipFile.java:219)
    at java.util.zip.ZipFile.<init>(ZipFile.java:149)
    at java.util.jar.JarFile.<init>(JarFile.java:166)
    at java.util.jar.JarFile.<init>(JarFile.java:130)
    at lucee.runtime.osgi.BundleInfo.<init>(BundleInfo.java:91)
    at lucee.runtime.osgi.BundleFile.<init>(BundleFile.java:42)
    at lucee.runtime.osgi.BundleFile.<init>(BundleFile.java:38)
    at lucee.runtime.config.XMLConfigAdmin.updateJar(XMLConfigAdmin.java:1070)
    at lucee.runtime.config.XMLConfigAdmin.updateRHExtension(XMLConfigAdmin.java:4865)
    at lucee.runtime.config.XMLConfigAdmin.updateRHExtension(XMLConfigAdmin.java:4812)
    at lucee.runtime.config.XMLConfigAdmin._updateRHExtension(XMLConfigAdmin.java:4792)
    at lucee.runtime.config.DeployHandler.deploy(DeployHandler.java:81)
    at lucee.runtime.engine.Controler.control(Controler.java:213)
    at lucee.runtime.engine.Controler.access$000(Controler.java:59)
    at lucee.runtime.engine.Controler$ControlerThread.run(Controler.java:110)
Caused by: java.io.FileNotFoundException: C:\lucee\tomcat\temp\servlet-filter-utils-1.1.1.jar (The system cannot find the file specified)
    ... 16 more
"
isapir commented 6 years ago

I'll look into it. Thanks.

isapir commented 6 years ago

Please try 2.0.3 -- it's the same code as 2.0.2 but packaged a bit differently and should resolve this issue.

psarin commented 4 years ago

Where can we find "servlet-filter-utils-1.1.1.jar"?

isapir commented 4 years ago

Where can we find "servlet-filter-utils-1.1.1.jar"?

@psarin Is that for initializing the Session object? You can use net.twentyonesolutions.servlet.listener.HttpSessionInitializer which comes with the WebSocket extension. See

https://github.com/isapir/lucee-websocket/blob/master/src/main/java/net/twentyonesolutions/servlet/listener/HttpSessionInitializer.java#L11

artknight commented 3 years ago

@isapir reading the thread I am a bit confused on the whole installation process. Please correct me if I am wrong

Step 1: Go to the Lucee Admin and install the Websockets Application 2.0.3. That should be it?

Thanks! Art