From guillaume.smet at gmail.com Tue Jul 19 18:53:29 2016 Content-Type: multipart/mixed; boundary="===============4273250533792229453==" MIME-Version: 1.0 From: Guillaume Smet To: hibernate-dev at lists.jboss.org Subject: Re: [hibernate-dev] People can't find our docs Date: Wed, 20 Jul 2016 00:53:27 +0200 Message-ID: --===============4273250533792229453== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi Sanne, Thanks for your feedback. I was pretty sure I hadn't all the history! Getting Google to prioritize our latest doc is probably a long time goal. I played a bit with jQuery to suggest to the user to go to the latest stable. Note that I only took into consideration the page for the time being and didn't consider the anchor but it should be easy to add it if we think it's worth it (it's a lot more work on the json descriptor though). The following command for each version is all that is needed: sed -i 's@@@' *.html (or a find -exec to do it on all the versions at once) I attached the global json descriptor and the js file (with a .txt extension as it didn't pass the mail filter). Both should be added to /hibernate/search/. Note that I only did the work for version 4.5 in the json descriptor. The work for other versions would mostly be a copy/paste. I also attached a screenshot of how it looks like. Nothing fancy but we can do whatever we want. Note that I only targeted the multi page HTML output as it was the most interesting to prototype. When we release a new version, we would have to update the descriptor file. Comments? -- Guillaume On Tue, Jul 19, 2016 at 2:39 PM, Sanne Grinovero wr= ote: > Hi Guillaume, > > yes I'm aware of the issue; we discussed it before, I think on this > same mailing list but maybe it was during our last meeting. > > We really need to fix that metadata; Stefania (my partner) is an SEO > consultant and is shocked at how bad we do with this; apparently we > are a funny example in her office but at least we're not the worst :) > > The problem is we can't change the headers as we don't control the > Apache httpd configuraion on the documentation server, so the > alternative is we'd need to rsync those docs locally, insert the right > changes in the static files of the docs, and push them back. > > Needs a volunteer to find some time for this. > > Also related to SEO I recently opened some issues on our WEBSITE > project, these should be easier to fix as it's directly under our > control: > - https://hibernate.atlassian.net/browse/WEBSITE-461 > - https://hibernate.atlassian.net/browse/WEBSITE-460 > - https://hibernate.atlassian.net/browse/WEBSITE-459 > > I've assigned them to Davide as he's usually quick with such things > but anyone is welcome to take some. > > The metadata issue on the docs server is probably the most urgent / > valuable though. > > Thanks, > Sanne --===============4273250533792229453== Content-Type: text/plain MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="outdated-version.js.txt" JChkb2N1bWVudCkucmVhZHkoZnVuY3Rpb24oKSB7CgkkLmdldEpTT04oJy9oaWJlcm5hdGUvc2Vh cmNoL2RvY3VtZW50YXRpb24uanNvbicsIGZ1bmN0aW9uIChqc29uKSB7CgkJdmFyIGN1cnJlbnRV cmwgPSB3aW5kb3cubG9jYXRpb24ucGF0aG5hbWU7CgkJdmFyIG1hdGNoID0gbmV3IFJlZ0V4cCgn XicgKyBqc29uLnBhdHRlcm4ucmVwbGFjZSgnJHt2ZXJzaW9ufScsICcoW14vXSspJykucmVwbGFj ZSgnJHtwYWdlfScsICcoLitcXC5odG1sKScpICsgJyQnKS5leGVjKGN1cnJlbnRVcmwpOwoJCWlm IChtYXRjaC5sZW5ndGggIT0gMykgewoJCQlyZXR1cm47CgkJfQoJCXZhciBjdXJyZW50VmVyc2lv biA9IG1hdGNoWzFdOwoJCXZhciBjdXJyZW50UGFnZSA9IG1hdGNoWzJdOwoJCXZhciBjdXJyZW50 SGFzaCA9IHdpbmRvdy5sb2NhdGlvbi5oYXNoOwoJCQoJCWlmIChjdXJyZW50VmVyc2lvbiA9PSBq c29uLnN0YWJsZSB8fCBjdXJyZW50VmVyc2lvbiA9PSBqc29uLmRldmVsb3BtZW50IHx8IGN1cnJl bnRWZXJzaW9uID09ICdzdGFibGUnKSB7CgkJCXJldHVybjsKCQl9CgkJCgkJdmFyIHJlZGlyZWN0 UGFnZTsKCQlpZiAoY3VycmVudFZlcnNpb24gaW4ganNvbi52ZXJzaW9ucyAmJiBjdXJyZW50UGFn ZSBpbiBqc29uLnZlcnNpb25zW2N1cnJlbnRWZXJzaW9uXS5yZWRpcmVjdHMpIHsKCQkJcmVkaXJl Y3RQYWdlID0ganNvbi52ZXJzaW9uc1tjdXJyZW50VmVyc2lvbl0ucmVkaXJlY3R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TsJJyArCgkJCScJdGV4dC1kZWNvcmF0aW9uOiBub25lOycgKwoJCQknfScg KwoJCQknYS52ZXJzaW9uOmhvdmVyIHsnICsKCQkJJwliYWNrZ3JvdW5kLWNvbG9yOiAjQ0NDOycg KwoJCQknfScgKwoJCSc8L3N0eWxlPicpOwoJCSQoJ2JvZHknKS5hcHBlbmQoJzxkaXYgY2xhc3M9 Im91dGRhdGVkLWNvbnRlbnQiPlRoaXMgY29udGVudCByZWZlcnMgdG8gYW4gb3V0ZGF0ZWQgdmVy c2lvbiBvZiAnICsganNvbi5wcm9qZWN0ICsgJy4gR28gdG8gbGF0ZXN0IHN0YWJsZTogPGEgaHJl Zj0iJyArIHN0YWJsZVVybCArICciIGNsYXNzPSJ2ZXJzaW9uIj52ZXJzaW9uICcgKyBqc29uLnN0 YWJsZSArJzwvYT4uPC9kaXY+Jyk7Cgl9KQp9KTsK --===============4273250533792229453==--