{"action":"created","issue":{"url":"https://api.github.com/repos/scenarioo/scenarioo/issues/450","repository_url":"https://api.github.com/repos/scenarioo/scenarioo","labels_url":"https://api.github.com/repos/scenarioo/scenarioo/issues/450/labels{/name}","comments_url":"https://api.github.com/repos/scenarioo/scenarioo/issues/450/comments","events_url":"https://api.github.com/repos/scenarioo/scenarioo/issues/450/events","html_url":"https://github.com/scenarioo/scenarioo/issues/450","id":129222471,"number":450,"title":"Introduce identifier (ID field) for scenarioo entities","user":{"login":"bruderol","id":755721,"avatar_url":"https://avatars.githubusercontent.com/u/755721?v=3","gravatar_id":"","url":"https://api.github.com/users/bruderol","html_url":"https://github.com/bruderol","followers_url":"https://api.github.com/users/bruderol/followers","following_url":"https://api.github.com/users/bruderol/following{/other_user}","gists_url":"https://api.github.com/users/bruderol/gists{/gist_id}","starred_url":"https://api.github.com/users/bruderol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bruderol/subscriptions","organizations_url":"https://api.github.com/users/bruderol/orgs","repos_url":"https://api.github.com/users/bruderol/repos","events_url":"https://api.github.com/users/bruderol/events{/privacy}","received_events_url":"https://api.github.com/users/bruderol/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-01-27T18:00:55Z","updated_at":"2016-03-01T16:01:43Z","closed_at":null,"body":"Currently names are used as identifier, this causes many troubles.\r\nSeparating the two concepts (and by default generating the identifiers, for those who not want to set both) would resolve this problems.\r\n\r\nThe two troubles we have with names:\r\n* special characters like slashes or backslashes in names, cause troubles, because names are used as identifiers in URLs and tomcat does not accept them (even encoded in URLs).\r\n* If a name of an object changes, the old URL will not work anymore (because the identifier of the object changed when changing its display text = name).\r\n\r\nRemark / state of this issue:\r\nThis is just a first draft of a possible solution (as roughly discussed today with @adiherzog).\r\nFeel free to discuss about it ...\r\n\r\n**Proposed solution (draft)**:\r\n* Introduce an id-Field for all objects in Scenarioo Format\r\n* id-Field does only allow normal characters: a-z A-Z 0-9 _ - # (maybe more?)\r\n* default value is calculated on server from name (if not set explicitly), but without special characters (and maybe some hash added for less collision probability)\r\n* server could check for object with different name having same calculated identifier and warn about this and/or react somehow appropriately?\r\n* later the writer libraries may allow the users to set the identifiers, to ensure that some object keep same identifier, even if their names change.\r\n* in URLs we only use identifiers\r\n* **breaking change** (therefore we can only introduce this in the same run, together with the new format):\r\n  * the new format will use the same identifiers internaly to locate all the objects (e.g. for directory names).\r\n  * the writer libraries will have to use the identifier for directory and file names (instead of the name).\r\n  * migration tool needs to migrate old docu format documentations accordingly"},"comment":{"url":"https://api.github.com/repos/scenarioo/scenarioo/issues/comments/190784681","html_url":"https://github.com/scenarioo/scenarioo/issues/450#issuecomment-190784681","issue_url":"https://api.github.com/repos/scenarioo/scenarioo/issues/450","id":190784681,"user":{"login":"mi-we","id":8026536,"avatar_url":"https://avatars.githubusercontent.com/u/8026536?v=3","gravatar_id":"","url":"https://api.github.com/users/mi-we","html_url":"https://github.com/mi-we","followers_url":"https://api.github.com/users/mi-we/followers","following_url":"https://api.github.com/users/mi-we/following{/other_user}","gists_url":"https://api.github.com/users/mi-we/gists{/gist_id}","starred_url":"https://api.github.com/users/mi-we/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mi-we/subscriptions","organizations_url":"https://api.github.com/users/mi-we/orgs","repos_url":"https://api.github.com/users/mi-we/repos","events_url":"https://api.github.com/users/mi-we/events{/privacy}","received_events_url":"https://api.github.com/users/mi-we/received_events","type":"User","site_admin":false},"created_at":"2016-03-01T16:01:43Z","updated_at":"2016-03-01T16:01:43Z","body":"I like the idea, for the auto-generated IDs we could replace the spaces and other special characters with \"-\" or \"_\" for example. It should still result in a readable URL in my opinion, meaning, that you should get an idea of what you are linking to if you copy the URL.\r\n\r\nRegarding the uniqueness of the IDs, is your idea to have a unique ID \"documentation-wide\" or is it a bit less strict? For example could two scenarios have the same ID if they are in different use cases?\r\n\r\nI guess the idea to have the server generate missing IDs automatically is because of backwards compatibility, so that we are still able to import older builds without the IDs?"}}