10 Dezember 2011

Cron and File Extensions

I created a script using TAR to backup my data on Ubuntu.
The script was putted to /etc/cron.daily but I didn't run!
After some investigations I found out that in /etc/cron.*/ directories no file extension or dots in the file name are allowed.

So be careful how you name your scripts that should run with cron.

07 Dezember 2011

OpenWebBeans Bootstrap in Java SE


It took me a while to get OpenWebBeans in Java SE up and running. Find below an example on how to bootstrap OWB:

ContainerLifecycle lifecycle = WebBeansContext.currentInstance().getService(ContainerLifecycle.class);
lifecycle.startApplication(null);


BeanManager beanManager = lifecycle.getBeanManager();
Bean<?> bean = beanManager.getBeans(B.class).iterator().next();


B b = (B) lifecycle.getBeanManager().getReference(bean, B.class, beanManager.createCreationalContext(bean));
b.foo();

16 November 2011

jtoggl a Java API for Toggl

Toggl is a great tool for time tracking. Specially if you work for multiple clients and/or projects at the same time.

Toggl provides a REST/JSON API and several samples in various programming languages. But one thing was missing a Java wrapper for the Toggl API.

So I decided to create one. You can find the project on Google code. It's called jtoggl.

If you have any suggestions or find any problems please let me know. You can use the issue tracker.

24 Oktober 2011

JBoss User Group Neuchatel

Since September 2011 there is a JBoss User Group (JBUG) in Neuchatel.
There were already two events.
  • JBUG Neuchatel Intro & JBoss AS7
  • OpenShift, the Red Hat cloud offering (I will blog about OpenShift and Java EE soon) 
The next event will be about Infinispan on November 23rd 2011

If you are interested in any Java and JBoss releated stuff feel free to join: http://community.jboss.org/groups/jbug-neuchatel 

The events will be held monthly.

29 Juni 2011

GlassFish Console hanging

If you are not able to login to the admin console of GlassFish you can try to disable the update center:
http://techmythoughts.blogspot.com/2010/08/glassfish-v3-admin-console-taking-too.html

16 Mai 2011

JBoss 5.1.0 as Windows Service

Today we had a problem starting JBoss as a Windows Service on Windows Server 2008. After some time we had a PermGenSpace OutOfMemoryError.

To fix that have a look at https://issues.jboss.org/browse/JBAS-7290

29 Januar 2011

Wicket on Google App Engine

I found a good description how to use Wicket on Google App Engine.

Have a look: http://stronglytypedblog.blogspot.com/2009/04/wicket-on-google-app-engine.html

21 Januar 2011

PASV FTP with IIS 6 on Windows Server 2003

After some hours I finally get PASV FTP up and running on Windows Server 2003.
Here how to do it:

First set the port range:
C:\Inetpub\AdminScripts\adsutil.vbs set /MSFTPSVC/PassivePortRange "5500-5550"

Then open the port range to the firewall
FOR /L %I IN (5500,1,5550) DO NETSH FIREWALL ADD PORTOPENING TCP %I FTPPort%I

Finally reset the IIS
iisreset

That's all. Easy, isn't it ;-)

19 Januar 2011

Java EE 6 on Microsoft Azure

David Chou, a Microsoft architect, describes how to run Java EE 6 with GlassFish in the Microsoft cloud Windows Azure.

http://blogs.msdn.com/b/dachou/archive/2011/01/17/run-java-with-glassfish-in-windows-azure.aspx