Automated webstart-maker: need game authors

Webstart was designed in about 5 minutes on the back of a napkin by people not smart enough to do such things without making huge stupid mistakes.

You’ve just hit one of them: webstart IGNORES all jars except the “first one in the XML file” when looking for manifests.

Bear with me whilst I workaround this. It’s damned stupid though.

The first jar in the JNLP is only a fall back, its more correct to specify the main class directly in the JNLP using a application-desc tag.

Kev

[quote]The first jar in the JNLP is only a fall back
[/quote]
Indeed. But … given that most people already have jars that work before moving to webstart, it’s weak. It doesn’t pay attention to how people actually develop. Ditto the fact that they renamed, arbitrarily, “ms” to “initial-heap-size”; they now have unrelated parallel naming schemes for literal equivalent functionality. Sigh.

Anyway, it was always going to be a simple fix, but I needed to refactor the whole version-editing process to make it simple (otherwise it would be really nasty, which is partly why it didn’t get in first time round). I’ve got a big chunk of code 90% refacotred which I’m still working on, and once that’s done I can add this option easily.

I’ve just done a major upgrade of the server, and despite lots of testing (lookin in the other thread, in Game News, on JGF status, for details) there may be some new bugs and problems.

In particular, I’ve made the “upload files” much prettier, more robust (doesn’t use ANY javascript any more) and somewhat easier to use - however, it is DIFFERENT from the old way. Now, instead of making all your changes in one go and hitting “make version”, you make each change separately, press the appropriate buttons to make them saved in a temporary space on the server, and when you’ve finished, you hit “publish”.

In the process, I also fixed several bugs which meant if you had identical filenames as other games that you could accidnetally delete files from other games, or get their files appearing in your game (although you couldn’t download them,you could only see the file info) . Won’t happen any more.

I’ve added JVM args and properties; both seem to work. Let me know if I’ve missed any that should be there, I couldn’t find my list of all args that work in webstart :(.

I have NOT added the main-class selector yet. I’ll do that later tonight.

[quote]blah3,

I’ve uploaded the necessary jars for Windows version of the game only. 2 problems:

  1. I can’t set any system property, which might cause bad performance on some systems. Especially for translucent images.
    [/quote]
    You can now, but I’ve only included a few of them; I can’t find the list of what ones JWS supports (in Sun’s infinite wisdom, only a few are allowed - and they aren;t all documented). If you have any you need + know work in webstart, let me know and I’ll add them in as options.

There is now, on the EDIT RELEASE screen (with the new scheme, you have to create a new release in order to edit it; once you’re done editing, click the PUBLISH button at the top of the screen)

another bug report… sorry :wink:

I have uploaded my new version of the Jars used in my game as the new uploading screen nolonger listed the Jars being present saying “No files in current release! (or you do not have access to view the current release)”

It seems the files were already there as now the webstart loader loads twice the amount of data when loading the Jars.

I wend back to the alpha versioning screen to delete the newly added Jars however it still shows that there is no Jars associated with the game… and all the settings (such as custom JVM arguments) are reset to default.

and now there is another error:

Referer URL:/controllers/release-game

Throwable:java.lang.IllegalArgumentException: Cannot create a new version, there is at least one already in progress (version = 12)

Line Source File
122 In GameReleaseController.java
141 …called from CMSControllersService.java
117 …called from bExpeditionGeos.java
38 …called from Geos.java
62 …called from HttpPostControllerService.java
251 …called from bAsynchronousService.java
334 …called from bModule.java
534 …called from Thread.java

It looks like something went wrong the first time and now that “session” did not close and so i cannot create a new “session” to create a new version…

umm… now it is working…

However i did notice that one of my JARs corrupted on upload…

At least i now saw the corrupt JAR so i tried to delete it and i recieved the following error:

Referer URL:/views/edit-gamerelease?gamename=Anaconda_Net&releasetype=alpha&version=12

Throwable:java.lang.Exception: Velocity is buggy as an ant farm and whoever wrote the exception code broke itso that you can’t actually inspect exceptions;

Please note: This idiot put the ONLY critical information in the logfile, so the admins will have to manually search through potentially hundreds of megabytes to find the damn bloody message. Oh how we wish they didnt do that, because we COULDhave AVOIDED this error message and done some clever stuff and shown you a webpage, except that the velocity coder who never tested their code made that impossible. Sob.

Probably useless message from velocity = Invocation of method ‘executeView’ in class com.grexengine.cms.core.CMSViewService threw exception class org.apache.velocity.exception.MethodInvocationException : Invocation of method ‘fixVelocityCrapBugs’ in class com.grexengine.cms.core.CMSViewService threw exception class java.lang.NullPointerException : null

Line Source File
176 In HttpViewService.java
251 …called from bAsynchronousService.java
245 …called from HttpViewService.java
334 …called from bModule.java
534 …called from Thread.java

And now adding new JARs is broken:

Referer URL:/views/edit-gamerelease?gamename=Anaconda_Net&releasetype=alpha&version=12

Throwable:java.lang.Exception: Velocity is buggy as an ant farm and whoever wrote the exception code broke itso that you can’t actually inspect exceptions;

Please note: This idiot put the ONLY critical information in the logfile, so the admins will have to manually search through potentially hundreds of megabytes to find the damn bloody message. Oh how we wish they didnt do that, because we COULDhave AVOIDED this error message and done some clever stuff and shown you a webpage, except that the velocity coder who never tested their code made that impossible. Sob.

Probably useless message from velocity = Invocation of method ‘executeView’ in class com.grexengine.cms.core.CMSViewService threw exception class org.apache.velocity.exception.MethodInvocationException : Invocation of method ‘fixVelocityCrapBugs’ in class com.grexengine.cms.core.CMSViewService threw exception class java.lang.NullPointerException : null

Line Source File
176 In HttpViewService.java
251 …called from bAsynchronousService.java
245 …called from HttpViewService.java
334 …called from bModule.java
534 …called from Thread.java

Can I fill my bug report too? I have the same problems as moogie reported concerning the currents jar completly disapeared and whenever I upload a completly new version (because I don’t have any other choice) there are multiple versioning problems. The webstart file incorporates mutliple versions at once:


<?xml version="1.0" encoding="utf-8"?>
<jnlp
 spec="1.0+"
 codebase="http://www.javagamesfactory.org/attachments/game/Mighty+Bubbles"
 href="http://www.javagamesfactory.org/jnlp/Mighty+Bubbles/alpha.jnlp"
 >
      <!-- Last-Modified header will be set to: Tue, 29 Mar 2005 04:54:23 +0200 -->
      <information>
            <title>Mighty Bubbles</title>
            <vendor>Author: theanalogkid</vendor>
            <homepage href="http://games.datadino.com/mightybubbles/mighty_bubbles.jnlp" />
            <description kind="one-line" >Capture the water people by throwing them bubbles!</description>
            <description kind="short" ><p>
Mighty Bubbles is the story of a little girl who wants to save her world of the water ennemies invasion. Their goal is to take control of any source of water. There are multiple water trees. Each of them produces water drops and the ennemies want to consume all of them. You, as the little girl (or boy if you insist) have to capture all the water ennemies by throwing them bubbles. When an ennemy is captured, you must pop the bubble to eliminate him.</p>
<p>Your second objective is to retreive all the water drops taken by the ennemies and bring them back to the water trees. A water tree can't hold more than 6 drops so when one is full, you must fill up another one.</p></description>
            <icon href="game-logo.jpg" />
            <offline-allowed/>
            <jgf-release-type>alpha</jgf-release-type>
            <jgf-release-version>13</jgf-release-version>
      </information>
      <security>
            <all-permissions/>
      </security>
      <resources>
            <jar href="alpha/12/mighty_bubbles-demo.jar" />
            <jar href="alpha/12/dom4j.jar" />
            <jar href="alpha/12/gagetimer1_1.jar" />
            <jar href="alpha/12/jinput.jar" />
            <jar href="alpha/12/jutils.jar" />
            <jar href="alpha/12/lwjgl.jar" />
            <jar href="alpha/12/lwjgl_fmod3.jar" />
            <jar href="alpha/12/lwjgl_util.jar" />
            <jar href="alpha/13/mighty_bubbles-demo.jar" />
            <jar href="alpha/13/dom4j.jar" />
            <jar href="alpha/13/gagetimer1_1.jar" />
            <jar href="alpha/13/jinput.jar" />
            <jar href="alpha/13/jutils.jar" />
            <jar href="alpha/13/lwjgl.jar" />
            <jar href="alpha/13/lwjgl_fmod3.jar" />
            <jar href="alpha/13/lwjgl_util.jar" />
            <jar href="alpha/dom4j.jar" />
            <jar href="alpha/gagetimer1_1.jar" />
            <jar href="alpha/jinput.jar" />
            <jar href="alpha/jutils.jar" />
            <jar href="alpha/mighty_bubbles-demo.jar" />
      </resources>
      <resources os="Windows">
            <nativelib href="alpha/win32-dxinput.jar" />
            <nativelib href="alpha/win32-dxinput-native.jar" />
            <nativelib href="alpha/win32-fmod-native.jar" />
            <nativelib href="alpha/win32-gagetimer1_1-native.jar" />
            <nativelib href="alpha/win32-lwjgl_fmod3-native.jar" />
            <nativelib href="alpha/win32-lwjgl-native.jar" />
            <nativelib href="alpha/12/win32-dxinput.jar" />
            <nativelib href="alpha/12/win32-dxinput-native.jar" />
            <nativelib href="alpha/12/win32-fmod-native.jar" />
            <nativelib href="alpha/12/win32-gagetimer1_1-native.jar" />
            <nativelib href="alpha/12/win32-lwjgl_fmod3-native.jar" />
            <nativelib href="alpha/12/win32-lwjgl-native.jar" />
            <nativelib href="alpha/13/win32-dxinput.jar" />
            <nativelib href="alpha/13/win32-dxinput-native.jar" />
            <nativelib href="alpha/13/win32-fmod-native.jar" />
            <nativelib href="alpha/13/win32-gagetimer1_1-native.jar" />
            <nativelib href="alpha/13/win32-lwjgl_fmod3-native.jar" />
            <nativelib href="alpha/13/win32-lwjgl-native.jar" />
      </resources>
      <resources>
            <j2se href="http://java.sun.com/products/autodl/j2se" version="1.4.2+" />
      </resources>
<application-desc>
</application-desc>
</jnlp>

Thanks, guys :(.

The multiple-versioning is … weird … but I’m guessing it’s one errant piece of SQL somewhere that is missing an “AND version= XXX” flag on it.

The loss of settings + files when creating a new version was ahem deliberate, sort-of: I was going to add another button “create new version using existing version” that would copy everything, but ran out of time - and then forgot I’d planned to do it :frowning: :-[

Leave it for now and I’ll try to have another look + apply patches tonight.

LOL, found the bug and fixed it.

I’d modified the GE code for what happens on a 404 to try and do some custom extra reporting - and introduced outside the finally that referred to an open file which was left hanging if the code crashed, which it was doing every time on a certain non-existent file (or, maybe, that file has no access permissions for the webserver).

Migrated it into the finally and all should be well now. No more too many open files issues (we had alomst 1000 instances of that one file still open).

Although, IMHO, the jvm ought to implicitly close file handles when it GC’s the things that own the handle. I have never understood why it doesn’t, other than being a bug they’ve not yet fixed and have had for years in different places.

have you made any progress with the multiple versioning bug and allowing us to remove old versions?

[quote]have you made any progress with the multiple versioning bug
[/quote]
The broken SQL query was … merely the one in the JNLP-maker that fetches files - it hadn’t been upgraded to select “only this version”. Oops. :-[

Old versions will for the time being all be kept, but not visible unless people try hard to get to them. At some point in the future, someone might add a way to access all the old versions (e.g. if an author loses their copy!) or to delete old versions (author doesn’t care and we start to run out of disk space?) but with tens of gb free it’s certainly not an issue at the moment!

More pressingly, you want to be able to “copy” the settings and files from the current version into the new one (I feel for those on dialup still). But that’s going to take some time, which I don’t have until the weekend now probably :(.

blah3,
I’ve created version 15 for my game but now the game fails silently. No log in the webstart log. Can see something on your side?

Same is occuring for me with my new and improved High_quality version of my AnacondaNet game.

Hi!

The generated .jnlp for my game is missing this:


<security>
 <all-permissions/>
</security>

But i’m using lwjgl so I need it for the native libs to be loaded.

You can test it here:
http://www.javagamesfactory.org/jnlp/Arindal/alpha.jnlp?overrideversion=1

Markus

[quote]Hi!

The generated .jnlp for my game is missing this:


<security>
 <all-permissions/>
</security>

But i’m using lwjgl so I need it for the native libs to be loaded.

You can test it here:
http://www.javagamesfactory.org/jnlp/Arindal/alpha.jnlp?overrideversion=1

Markus
[/quote]
Nevermind… I was just blind…

Works now :slight_smile:

are there problems with blanks in names again?

http://javagamesfactory.org/jnlp/Quest+for+peace/alpha.jnlp

Please contact the admin / dev-team

Copy and paste everything below this line when contacting them

Referer URL:/jnlp/Quest+for+peace/alpha.jnlp

Throwable:java.lang.IllegalArgumentException: The specified version has no JVM selected - please go back and choose one! - I found 0 JVM's that matched game = Quest for peace, release = alpha and version = 7
Line      Source File
249      In JNLPService.java
251      ...called from bAsynchronousService.java
334      ...called from bModule.java
534      ...called from Thread.java

and… I’d like to have it Quest for Peace.
Can you change that or should I make a new entry(then just delete the old one) ?

I know that it says its an error, but - did you READ what you just copied and pasted? ::slight_smile:

[quote]are there problems with blanks in names again?

http://javagamesfactory.org/jnlp/Quest+for+peace/alpha.jnlp

Please contact the admin / dev-team

Copy and paste everything below this line when contacting them

Referer URL:/jnlp/Quest+for+peace/alpha.jnlp

Throwable:java.lang.IllegalArgumentException: The specified version has no JVM selected - please go back and choose one! - I found 0 JVM's that matched game = Quest for peace, release = alpha and version = 7
Line      Source File
249      In JNLPService.java
251      ...called from bAsynchronousService.java
334      ...called from bModule.java
534      ...called from Thread.java

and… I’d like to have it Quest for Peace.
Can you change that or should I make a new entry(then just delete the old one) ?
[/quote]
Nothing is wrong, nothing is broken, it’s just that old games need to have a JVM explicitly selected, once and once only. I didn’t have time to make a custom page purely to say “you need to select a JVM” :).