google / earthenterprise

Google Earth Enterprise - Open Source
Apache License 2.0
2.67k stars 887 forks source link

Admin Console Publish a DB pre-populates the publish point erroneously #1921

Open tst-bmuthusamy opened 3 years ago

tst-bmuthusamy commented 3 years ago

Description In Admin Console publish option, the "publish point" is created by removing multiple copies of glbglm Issue is when we have DBs named as: "cut1glm.glm", "cut2glm.glm", "cut3glm.glm", "cut4glb.glb", and you try to publish these, they are now populated as names like: "cut", "cut_copy", "cut_copy_2" and so on, while the name should have been "cut1glm", "cut2glm",..,"cut4glb" and such.

To Reproduce Login to the admin console: Example: "http://myserver/admin/" Publish any existing with a DB publish point name such as: "aglbbglbcglb1glm2glm3glm.glb". Now try publishing this newly created DB, and observe that the publish point is now named something like "_copy" or such.

Expected behavior Publish point should have been the entire content "aglbbglbcglb1glm2glm3glm", sans the final ".glb" or the final ".glm", if they exist. An addition of "_copy" is acceptable on DB name if the prior DB name was already taken.

Screenshots image

Desktop

Additional context Originally identified when creating cutter with DB names like: cut1glb.glb, cut2glb.glb, cut3glm.glm, cut4glm.glm and then later identified that the error is actually due to a possible replacement of "?glb" and "?glm" without actually validating that it is a ".glb" and ".glm" that occurs only at the end of the string.