Modify

Opened 7 months ago

Closed 7 months ago

Last modified 6 months ago

#23489 closed defect (worksforme)

Missing JVM Arguments

Reported by: dieterdreist Owned by: team
Priority: normal Milestone:
Component: Core Version:
Keywords: Cc: taylor.smock

Description

Since 2 days on startup, I get this message and Josm warns it might not work as expected:

Missing JVM Arguments: --add-exports=java.base/sun.security.action=ALL-UNNAMED --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED

here is my status:

{{{
Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2024-02-15 16:06:37 +0100 (Thu, 15 Feb 2024)
Revision:18986
Build-Date:2024-02-16 02:30:57
URL:https://josm.openstreetmap.de/svn/trunk

Identification: JOSM/1.5 (18986 en) Mac OS X 13.6.4
OS Build number: macOS 13.6.4 (22G513)
Memory Usage: 240 MB / 12288 MB (105 MB allocated, but free)
Java version: 21.0.1, Homebrew, OpenJDK 64-Bit Server VM
Look and Feel: javax.swing.plaf.metal.MetalLookAndFeel
Screen: Display 1 1920×1080 (scaling 1.00×1.00) Display 2 1920×1080 (scaling 1.00×1.00)
Maximum Screen Size: 1920×1080
Best cursor sizes: 16×16→16×16, 32×32→32×32
System property file.encoding: UTF-8
System property sun.jnu.encoding: UTF-8
Locale info: en_IT
Numbers with default locale: 1234567890 -> 1234567890
VM arguments: [-Djosm.home=<josm.pref>, -Dsun.java2d.opengl=true]

Plugins:
+ buildings_tools (36200)


cache.bing.attribution.xml=1707689759
cache.capabilities1637351842=1707689733
cache.motd.html=1708120649
cache.motd.html.java=21.0.1
cache.motd.html.lang=En:
cache.motd.html.version=18986
changesetdialog.lastHeight=0
commandstack.lastHeight=0
conflict.lastHeight=0
download.newlayer=true
downloadprimitive.lasttype=1
draw.rawgps.colormode=0
draw.rawgps.lines=2
expert=true
filter.lastHeight=0
gui.geometry=x=-1920,y=-263,width=1920,height=1055
gui.maximized=true
imagery.entries=[{max-zoom=22, min-zoom=1, noTileHeaders={"X-VE-Tile-Info":["no-tile"]}, noTileChecksums={"MD5":["c13269481c73de6e18589f9fbc3bdf7e"]}, metadataHeaders={"X-VE-TILEMETA-CaptureDatesRange":"Capture Date"}, transparent=true, minimumTileExpire=3600, name=Bing aerial imagery, id=Bing, type=bing, url=https://www.bing.com/maps/, permission-reference-url=https://wiki.openstreetmap.org/wiki/Bing_Maps, cookies=, icon=data:image/png;base64,iVBORw0..., customHttpHeaders={}, category=photo},
  {max-zoom=22, noTileHeaders={"Etag":["\"10i954m13i2\""]}, noTileChecksums={"MD5":["f27d9de7f80c13501f470595e327aa6d"]}, transparent=true, minimumTileExpire=3600, name=Esri World Imagery, id=EsriWorldImagery, type=tms, url=https://{switch:services,server}.arcgisonline.com/arcgis/rest/services/World_Imagery/MapServer/tile/{zoom}/{y}/{x}, attribution-text=Terms & Feedback, attribution-url=https://wiki.openstreetmap.org/wiki/Esri, cookies=, icon=data:image/png;base64,iVBORw0..., customHttpHeaders={}, category=photo},
  {max-zoom=22, transparent=true, minimumTileExpire=3600, name=Esri World Imagery (Clarity) Beta, id=EsriWorldImageryClarity, type=tms, url=https://clarity.maptiles.arcgis.com/arcgis/rest/services/World_Imagery/MapServer/tile/{zoom}/{y}/{x}, attribution-text=Terms & Feedback, attribution-url=https://wiki.openstreetmap.org/wiki/Esri, permission-reference-url=https://github.com/osmlab/editor-layer-index/pull/358#issuecomment-361416110, cookies=, icon=data:image/png;base64,iVBORw0..., description=Esri archive imagery that may be clearer and more accurate than the default layer., customHttpHeaders={}, category=photo},
  {max-zoom=22, noTileHeaders={"ETag":["\"336b022ed883bc72347a637634e490d4\"|\"067736a547cafe90014b4e59b6510abe\"|\"ee1f6802b0234046b553cbbc672ac7d9\"|\"9f5a2f1d7cc131e58befc2052c71c827\""]}, noTileChecksums={"MD5":["58e78313d04adf0ea64b8de8590c3d46"]}, transparent=true, minimumTileExpire=3600, name=Mapbox Satellite, id=Mapbox, type=tms, url=https://{switch:a,b,c,d}.tiles.mapbox.com/v4/mapbox.satellite/{zoom}/{x}/{y}.jpg?access_token={apikey}, attribution-text=Terms & Feedback, attribution-url=https://www.mapbox.com/about/maps/, permission-reference-url=https://wiki.openstreetmap.org/wiki/Vertical_Aerial_Photographs#DigitalGlobe_.2F_MapBox, cookies=, icon=data:image/png;base64,iVBORw0..., customHttpHeaders={}, category=photo},
  {max-zoom=19, valid-georeference=true, transparent=true, minimumTileExpire=3600, name=OpenStreetMap Carto (Standard), id=standard, type=tms, url=https://tile.openstreetmap.org/{zoom}/{x}/{y}.png, attribution-text=© OpenStreetMap contributors, attribution-url=https://www.openstreetmap.org/, permission-reference-url=https://wiki.osmfoundation.org/wiki/Terms_of_Use, cookies=, icon=data:image/png;base64,iVBORw0..., customHttpHeaders={}, category=osmbasedmap}
]
imagery.layers.default=[Bing, EsriWorldImagery, EsriWorldImageryClarity, Mapbox, standard]
josm.version=18986
laf=javax.swing.plaf.metal.MetalLookAndFeel
lastDirectory=${HOME}
layerlist.lastHeight=110
mappaint.renderer-class-name=org.openstreetmap.josm.data.osm.visitor.paint.StyledMapRenderer
mappaint.style.known-defaults=[resource://styles/standard/elemstyles.mapcss]
mapstyle.lastHeight=0
message.imagery.nagPanel.https://www.bing.com/maps/=false
minimap.lastHeight=0
mirror.https://josm.openstreetmap.de/maps=[1708120651247, <josm.pref>/cache/mirror_https___josm.openstreetmap.de_maps]
mirror.https://josm.openstreetmap.de/remote/geofabrik-index-v1-nogeom.json=[1707689734341, <josm.pref>/cache/mirror_https___josm.openstreetmap.de_remote_geofabrik-index-v1-nogeom.json]
notes/note_open.lastHeight=0
oauth.use-for-all-requests=false
org.openstreetmap.josm.actions.ImageryAdjustAction$ImageryOffsetDialog.geometry=x=-1216,y=167,width=512,height=194
org.openstreetmap.josm.gui.conflict.tags.CombinePrimitiveResolverDialog.geometry=x=-1360,y=-36,width=800,height=600
org.openstreetmap.josm.gui.dialogs.DeleteFromRelationConfirmationDialog.geometry=x=-1160,y=164,width=400,height=200
org.openstreetmap.josm.gui.dialogs.LatLonDialog.geometry=x=-1271,y=5,width=622,height=518
org.openstreetmap.josm.gui.dialogs.properties.TagEditHelper$AddTagsDialog.geometry=x=-1485,y=257,width=660,height=419
org.openstreetmap.josm.gui.dialogs.properties.TagEditHelper$EditTagDialog.geometry=x=-1250,y=174,width=597,height=181
org.openstreetmap.josm.gui.dialogs.relation.GenericRelationEditor.geometry=x=-868,y=-168,width=700,height=650
org.openstreetmap.josm.gui.download.DownloadDialog.geometry=x=-1616,y=-205,width=1302,height=925
org.openstreetmap.josm.gui.download.DownloadObjectDialog.primitivesHistory=[1101246258, 1101246261, 1690324]
org.openstreetmap.josm.gui.history.HistoryBrowserDialogManager.geometry=x=-1772,y=-76,width=850,height=500
org.openstreetmap.josm.gui.io.UploadDialog.geometry=x=-1653,y=38,width=800,height=600
org.openstreetmap.josm.gui.preferences.PreferenceDialog.geometry=x=-1416,y=-136,width=906,height=800
osm-download.bounds=41.8966791;12.4816409;41.8970464;12.4821344
osm-server.upload-strategy=singlerequest
pluginmanager.lastupdate=1708120467412
pluginmanager.version=18986
pluginmanager.version-based-update.policy=always
plugins=[buildings_tools]
preferences.reset.draw.rawgps.lines=true
progressdialog.size=207
properties.recent-tags=[tree_lined,
  right,
  tree_lined,
  both,
  access,
  private,
  landuse,
  farmyard,
  natural,
  wood,
  landcover,
  trees,
  leisure,
  swimming_pool,
  building,
  yes,
  service,
  driveway,
  natural,
  scrub,
  surface,
  unpaved,
  highway,
  track,
  highway,
  service,
  landuse,
  orchard,
  landuse,
  farmland,
  amenity,
  bar,
  shop,
  pastry,
  brand,
  Pewex,
  barrier,
  fence,
  landuse,
  residential,
  barrier,
  gate,
  entrance,
  main,
  amenity,
  fountain,
  disused,
  yes,
  historic,
  yes,
  indoor,
  yes,
  entrance,
  yes,
  wikimedia_commons,
  File:Fountain in the staircase of Palazzo Bonaparte, Rome.jpg,
  drinking_water,
  no
]
propertiesdialog.geometry=x=-887,y=-18,width=783,height=519
propertiesdialog.lastHeight=166
proxy.policy=no-proxy
relationlist.lastHeight=213
remotecontrol.permission.authorization=true
search.history=[R wikimedia_commons~"File:Drinking_fountain_on.*", R wikimedia_commons~"File:Drinking_fountain_on"]
selectionlist.lastHeight=166
sensitive.keys=[oauth.access-token.key, oauth.access-token.object.OAuth20.api.openstreetmap.org, oauth.access-token.parameters.OAuth20.api.openstreetmap.org, oauth.access-token.secret, osm-server.password, osm-server.username, proxy.pass, proxy.user, sensitive.keys]
toggleDialogs.width=755
upload.comment.history=[adding details from survey, fixing details broken by previous edit and after survey, tracing details from bing aerial imagery, , add Photo from survey, add Photo from survey, actually it is of the north western fountain, drawing details from bing aerial imagery, draw, fix sentiero 7 after feedback from local mapper (survey)]
upload.comment.last-used=1707690501
upload.source.history=[Bing, survey, survey (by another mapper, who wrote to me), , knowledge]
upload.source.obtainautomatically=true
userlist.lastHeight=117
userlist.visible=true
validator.lastHeight=169
validator.visible=true
}}}

Attachments (0)

Change History (12)

comment:1 by GerdP, 7 months ago

This is intended, see #23355.

comment:2 by anonymous, 7 months ago

ok, so I should add these additional options in my startup, or what should I do about it? I just ignored it and nothing particular happens.

comment:3 by GerdP, 7 months ago

Cc: taylor.smock added

I don't know why exactly these parameters are required. A lot of tickets about crashes mention these missing arguments with java versions > 8.

comment:4 by skyper, 7 months ago

See #21059 and its duplicate tickets.
I usually have no problems without these additional options with Debian and openjdk-jre versions > 15 but these additional options do not harm.

comment:5 by anonymous, 7 months ago

thank you, I added the parameters to my startup script and, as expected, the warning went away

comment:6 by taylor.smock, 7 months ago

I don't remember what the arguments are required for, but it isn't something that will be hit during "normal" usage (download from OSM -> edit -> upload to OSM). I think you might be more likely to run into issues if you are running some specific plugins though, and it might be only if you are using plugins. But I think most people are using at least one plugin. JOSM core, I think, is just fine without those JVM arguments (we have those set in the MANIFEST.MF file, IIRC -- which does not carry over to the plugins).

So, the arguments aren't something that are required, but (as the window indicated), JOSM may work improperly. The important word is may.

TBH, the whole point of the startup sanity check is to stop or reduce the number of tickets where users were missing one of the VM arguments, where the user was running JOSM using a x32 JVM implementation on a x64 computer, and to have one or two last releases where people still running Java 8 can have decent instructions on updating their Java version before we flip the switch and compile for Java 11 (I'm really hoping to avoid a flood of tickets that have a root cause of trying to run JOSM with Java 8).

comment:7 by GerdP, 7 months ago

reg. #21059: I am not sure but I think I only saw crashes on systemns running Linux so far. So maybe these arguments are not needed on MacOS or Windows?

comment:8 by taylor.smock, 7 months ago

Resolution: worksforme
Status: newclosed

I've seen some crashes Mac. I haven't really used Windows, so I don't know about that. I suspect very few people are using the jar on Mac/Windows though.

comment:9 by Klerik7, 6 months ago

is there any solution for this problem? AJ on the latest Java 21 it throws it out, I am forced to use josm 18969...so far I found out that it makes a problem when replacing the geometry, when I want to merge for example an address point with a building

comment:10 by skyper, 6 months ago

As I neither know your operating system nor how you installed JOSM it is difficult to give you the correct advice.
You could:

Last edited 6 months ago by skyper (previous) (diff)

comment:11 by taylor.smock, 6 months ago

Addendum to what skyper said:

  • If you are on Linux, either use the unofficial flatpak or the official Debian repo. I use the flatpak on Fedora.

comment:12 by Klerik7, 6 months ago

thank you

I thought it was a problem with other installation methods as well...I always used .jar but when I tried .exe now it doesn't throw it up anymore

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.