English Article · Software

How to resolve Java heap space exception in Solr

For the last few days I’ve noticed weird behavior in Sitecore instances which are related to Solr, for example:

  • indexes are rebuilding with exceptions;
  • sitecore instance is being slow;
  • lost connection to Solr;
  • not able to restart the Solr service, it’s just take an infinity time to stop.

For all of this things I haven’t pay much attention to start troubleshooting, because I’m working in another area which not related to indexes, the behaviour is quite new for me and just simple reboot has helped.

Lost connection to Solr
Continue reading “How to resolve Java heap space exception in Solr”
English Article · Software

“Entourage” anti-pattern and “Stairway” pattern

The Entourage anti-pattern brings no needed dependency. In this example if we build project with Controllers in isolation, the bin folder going to have the NHibirnate assembly as implicit dependency. With the current implementation the services, domain, NHibernate, etc. classes must be public, hence developer able to create any of them manually with constructor usage and this is unwilling situation.

The Entourage anti-pattern

The Stairway pattern is fix the entourage anti-pattern. The interface and implementation should be separated from each other in different assemblies. Hence, with this approach we easily can replace implementations.

The Stairway pattern