Running DotCMS in Windows and Memory

Posted July 15th, 2010 in DotCMS by cfalzone

Java Service Wrapper Logo Just a quick post today.  A few months back we decided to increase the RAM on our dotCMS servers to 12Gb.  We were starting to notice some performance lags in our boxes that only had 4Gb.  In doing this we also had to make the switch to 64bit Windows.  Everything went very smoothly, albeit we did not see the performance increase we were hoping for.

Today, while talking with a dotCMS support agent, he made us aware that Java Service Wrapper that dotCMS uses to let you install dotCMS as a service in windows is a 32bit application and as such only allows windows to access 4Gb of memory.  On top of this, the 64bit windows version of this third-party application is not freely available.  The Java Service Wrapper that ships with dotCMS is developed by a company called Tanuki Software.  Here is a link to the software page:  http://wrapper.tanukisoftware.com/doc/english/download.jsp

If you scroll down to the bottom of the page you will note note #2:

*2: 64-bit Windows versions of the Java Service Wrapper are not currently being made available in the Community Edition.

The Community Edition is what dotCMS ships with.  Moral of the story, if you are using dotCMS in windows and want to access more than 4Gb or RAM, you need to purchase a Standard Version License from Tanuki.  I’ll post more after we’ve made the upgrade.

Live Blogging – DotCMS Bootcamp Day 2

Posted April 15th, 2010 in DotCMS by cfalzone

Watch this space for updates today.

I will be missing the first session today :(  But stay tuned at 11:15 for updates from the Plugins Session.

Last night we decided to head to the 8 oz Burger for dinner.  There are not many Burger Joints I would feel comfortable getting a raw burger at, but this place was top notch.  Very good burgers. Continue Reading »

Live blogging – DotCMS Bootcamp Day 1

Posted April 14th, 2010 in DotCMS by cfalzone

I will be trying to live blog from the DotCMS Bootcamp conference here.  Watch this space for updates.

Last night opened with a cocktail party for some social networking.  It was great to meet back up with some old friends and meet some new ones as well.  It was kinda sad that a lot of the folks that didn’t get to make it.  We miss you fusion27, bradrice, and all the other folks from the IRC channel that couldn’t make it.  After the party a bunch of us went to Sushi Samba — AMAZING, I really recommend it. Continue Reading »

Creating an iCal Feed from DotCMS Content / Calendar

Posted September 16th, 2009 in DotCMS, Edinboro University by cfalzone

First off I apologize for be a slacker and not having time to post anything on this blog for quite some time. I’d like to say that I’m going to get better at it, but I probably won’t!

This past week I needed to get an iCal feed created for my DotCMS Calendar.  What I came up with might not be the most elegant solution, but it does the trick for Outlook and Google Calendars at least.  So I thought I’d post up my process …

First I started by creating an HTML page in DotCMS, and choosing the Blank Template.  The next thing I did was create a new contentlet.  The important thing to remember about this step is to name your contentlet something that is going to be ewasy to remember.  The reason for this is that doing this will break the DotCMS Page Editor.  You’ll see why a little latter.

Now for the code:

$response.setContentType('text/calendar')
$response.setHeader("Content-disposition","attachment;filename=calendar.ics")
#set($today = $UtilMethods.now())
#set($fromDate = $date.format("MM/dd/yyyy", $today))
#set($endDate = $UtilMethods.addDays($today, 30))
#set($toDate = $date.format("MM/dd/yyyy", $endDate))
#pullContent("+structureInode:135155  +date1:[01/01/1900 00:00:00
TO $toDate 23:59:59] +date2:[$fromDate 00:00:00 TO 01/01/3000 00:00:00]
+languageId:1 +deleted:false +live:true" '0' 'date1')
BEGIN:VCALENDAR
PRODID:-//Microsoft Corporation//Outlook 9.0 MIMEDIR//EN
VERSION:2.0
METHOD:PUBLISH
CALSCALE:GREGORIAN
X-WR-TIMEZONE:America/New_York
X-WR-CALNAME:EUP Events
BEGIN:VTIMEZONE
TZID:US-Eastern
LAST-MODIFIED:19870101T000000Z
BEGIN:STANDARD
DTSTART:19971026T020000
RDATE:19971026T020000
TZOFFSETFROM:-0400
TZOFFSETTO:-0500
TZNAME:EST
END:STANDARD
BEGIN:DAYLIGHT
DTSTART:19971026T020000
RDATE:19970406T020000
TZOFFSETFROM:-0500
TZOFFSETTO:-0400
TZNAME:EDT
END:DAYLIGHT
END:VTIMEZONE
#foreach($content in $list)
BEGIN:VEVENT
DTSTAMP:$date.format("yyyyMMdd'T'HHmmss", $content.startDate)
DTSTART:$date.format("yyyyMMdd'T'HHmmss", $content.startDate)
DTEND:$date.format("yyyyMMdd'T'HHmmss", $content.endDate)
SUMMARY:$!content.title
UID:$!content.identifier
PRIORITY:3
CATEGORIES:MEETING
LOCATION:Edinboro
END:VEVENT
#end
END:VCALENDAR

Let me pick this apart section by section. First off we have what I like to call, “The Magic” of this whole thing:

$response.setContentType('text/calendar')
$response.setHeader("Content-disposition","attachment;filename=calendar.ics")

What this little bit of code does is set content type for the page, and tells the browser that this should be downloaded, not displayed in the screen. It also tells the browser exactly what the filename should be that they are downloading. This allows us to set the extension of .ics.

#set($today = $UtilMethods.now())
#set($fromDate = $date.format("MM/dd/yyyy", $today))
#set($endDate = $UtilMethods.addDays($today, 30))
#set($toDate = $date.format("MM/dd/yyyy", $endDate))
#pullContent("+structureInode:135155  +date1:[01/01/1900 00:00:00
TO $toDate 23:59:59] +date2:[$fromDate 00:00:00 TO 01/01/3000 00:00:00]
+languageId:1 +deleted:false +live:true" '0' 'date1')

Note:  I had to break up the #pullContent into 3 lines so it would fit on the page, this should be one line.

This bit of code is probably fairly familiar to most of you reading this. Basically it is pulling the events from the last 30 days. You will of course need to make sure you change the structureInode to match what your Event Structure’s Inode is.

BEGIN:VCALENDAR
PRODID:-//Microsoft Corporation//Outlook 9.0 MIMEDIR//EN
VERSION:2.0
METHOD:PUBLISH
CALSCALE:GREGORIAN
X-WR-TIMEZONE:America/New_York
X-WR-CALNAME:EUP Events
BEGIN:VTIMEZONE
TZID:US-Eastern
LAST-MODIFIED:19870101T000000Z
BEGIN:STANDARD
DTSTART:19971026T020000
RDATE:19971026T020000
TZOFFSETFROM:-0400
TZOFFSETTO:-0500
TZNAME:EST
END:STANDARD
BEGIN:DAYLIGHT
DTSTART:19971026T020000
RDATE:19970406T020000
TZOFFSETFROM:-0500
TZOFFSETTO:-0400
TZNAME:EDT
END:DAYLIGHT
END:VTIMEZONE

This is the begining of the iCal Code. It defines the Time Zone, the name, the version, and various other tidbits. I found it was necessary to put in the vTimeZone element for the calendar to show up in Google in the right times. I also found a nifty reference of the iCal Format Here.

#foreach($content in $list)
BEGIN:VEVENT
DTSTAMP:$date.format("yyyyMMdd'T'HHmmss", $content.startDate)
DTSTART:$date.format("yyyyMMdd'T'HHmmss", $content.startDate)
DTEND:$date.format("yyyyMMdd'T'HHmmss", $content.endDate)
SUMMARY:$!content.title
UID:$!content.identifier
PRIORITY:3
CATEGORIES:MEETING
LOCATION:Edinboro
END:VEVENT
#end
END:VCALENDAR

The rest of the code is fairly straight foward I think. Loop through each contentlet and create a vEvent item then bookend with your ending vCalendar. The hard part is the Time Format. I found putting in the Timezone here did not work in Google, perhaps you will have better luck.

Now, I know this isn’t perfect. I haven’t put in descriptions and nice locations and all that. This was a quick and dirty write-up to get what I needed done. I hope it benefits you, if you have any questions or suggestions I’d love to hear from you in the comments.

Where to go from here? I would love to see this macroized and/or wigitized and put into a plugin. I hope some day I have time to beef it up and learn more about what I can and can’t do with iCal. I would also like to put in the ability to give iCal Feeds for specific categories and tags. Ultimately, I would like to see the iCal download servelet that already exists in DotCMS fleshed out to this natively within the CMS.

Please if you have any suggestions on how to make this better or any improvements you’ve made on this, I’d love to hear about it in the comments.

Comments Off

How to Enable SSL in DotCMS

Posted February 18th, 2009 in DotCMS by cfalzone

Having just gone through this process, I thought I’d share the steps I took to enable SSL in DotCMS.  On the DotCMS wiki there are some fairly brief instructions on how to enable SSL.  A quick search on Tomcat and SSL will point you to their documentation which explains it step-by-step.  So here it is all laid out in once nice How To.  Note that I am using windows and our Certificate Authority id DigiCert.  Your experience my vary.

Step 1:  Generating a Keystore

The first steps is to generate the keystore.  Tomcat, the java application server that DotCMS runs on, uses a format called Java KeyStore (JKS) for it’s keystores.  The Java SDK provides all the tools necessary to get the task done.  So, hop on over to where you have your SDK installed and follow along

C:\Program Files\Java\jdk1.6.0_03\bin>keytool -genkey -alias tomcat -keyalg RSA -keystore C:\DotCMS_keystore.key

You will need to enter some information about your organization and location.  You will have have to choose a password for your keystore.  Don’t forget the password or you’ll have to start over.  You should now have a valid keystore with the alias of tomcat.

Step 2 – Generate a Certificate Request

With the keystore in place you could skip all the way to the end now and have a fully functioning self-signed certificate.  This is nice, but more likely you are looking to have a certificate authority such as DigiCert or Verisign sign your certificate.  To do this you are going to need to generate a CSR or Certificate Signing Request.  Thankfully the keytool takes care of that for us as well.

C:\Program Files\Java\jdk1.6.0_03\bin>keytool -certreq -alias tomcat -keyalg RSA -keystore C:\DotCMS_keystore.key -file c:\DotCMS_certreq.csr

You are going to be required to enter your keystore password, but this should generate the certificate request for you without too much trouble.  Now you can take your DotCMS_certreq.csr to your signing authority and submit a request for a certificate.  I am not going to cover that process because  I don’t do that part, my sys admin does.  Well, it is also different with each signing authority.   Once you have your certificate you are ready to start the next step.

Step 3 – Importing your certificate

C:\Program Files\Java\jdk1.6.0_03\bin>keytool -import -trustcacerts -alias tomcat -file c:\star_edinboro_edu.p7b -keystore c:\DotCMS_keystore.key

Again, the keytool handles the dirty work for you and you’ll need that password again.

Step 4 – Checking the details

You could probably skip this step if you know you have the right password.  Honestly the output of this command really didn’t tell me much other than I could see that my certificated had imported.

C:\Program Files\Java\jdk1.6.0_03\bin>keytool -list -v -keystore c:\DotCMS_keystore.key

Step 5 – Configure DotCMS to listen on Port 443

The next step is going to require you to head to your DotCMS’s server.xml  Add the following lines:

<Connector port="443" address="192.168.8.221"
protocol="HTTP/1.1"
maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
SSLEnabled="true" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS"
keystoreFile="C:\DotCMS_keystore.key"
keypass="..."  />

You will have to change the address and keypass to match your system.

Step 6 – Restart and test

That’s really all there is to it.  Restart your DotCMS service and you can use openSSL to test the connection just like telnet.

C:\Program Files\Java\jdk1.6.0_03\bin>openssl s_client -connect 192.168.8.221:443 -state

After it establishes a connection you should see your certificate information.  You will of course want to test the whole setup in a browser.

In order for DotCMS to use SSL you also need to set a page to use SSL in the properties.  Create a test page, but before you save and publish head to the advanced properties and check the force https option.  Now when you try to visit that page it should redirect you https if you are not already using it.

Hopefully this small little guide helps out anyone trying to figure out how to setup SSL in DotCMS.

DotCMS Bootcamp

Posted February 11th, 2009 in DotCMS by cfalzone

Last week saw me in Miami at the DotCMS Open Minds Conference, Boot Camp.  DotMarketing’s approach to the conference this year was slightly different this year.  The focus was more on Training whereas last year was more like demo.  I’d have to say that I really enjoyed the conference.

Tuesday, Feb 3

My journey to Miami started a day before the conference.  I couldn’t get a flight in the day of the conference.  It was fairly uneventful (that’s good!).  The Hotel this year was the Mayfair.  A little more ritzy than the Sonata, but still very nice.  I ended up eating at the Johnny Rockets.

Wednesday, Feb 4

The conference didn’t officially start until the registration/welcome party at 6PM.  Since I was there quite early I decided to jump over to DotMarketing Headquarters about 1PM.  DotMarketing was nice enough to throw us Jason Tesser for some informal pre-conference training.

We talked a lot about the bits and pieces of DotCMS.  Here are some take-aways from that conversation:

  • Lucene queries will no longer require the live, deleted, and language parameters.  The DotCMS code tries to be smart enough to put those in based on where you are in the system.  This should simplify the lucene quries in our code considerably.
  • DotMarketing plans on hitting the Content Browser Search functionality with a hammer very soon.  They want to add a more intuitive search.  The idea is to make the search much more like a Google search.  A very simple one field search with advanced option and more intuitive operators.
  • They removed multicast traffic in clustering.  This is coming in the next version, but it is a major improvement on the way clustering works.  At Edinboro I decided to nix the cluster because of the multicast issues on campus.

After the informal training we went back to the Hotel for the opening party.  I got to meet back up with Fienen and meet some of the new folks from the DotCMS Community.  A big welcome to IPFW who just made the decision to go with DotCMS and had a considerable force at the conference.  After the party we (Jason, Fienen, and some others) headed to the Knife for dinner.  The Knife was a very nice place to eat.  It is an Argentinian Steak House Buffet kinda thing.  Very Nice!

After dinner I had mega troubles with my laptop’s wireless.  So that’s why this post is coming a little late.

Thursday, Feb 5

Thursday started with breakfast at the Bookstore in the Grove.  The first session of the day was on structures and relationships.  I already knew much of the content here, but for the new guys this was a lot of bricks and mortar kind of training on the Back-End of DotCMS.  I did manage to grab a couple morsels of goodness from the session though:

  • Relationships have an order field but in order to get the #PullRelatedContent macro to sort on that field you have to first save the order in the back-end.  Then, if you leave the sort parameter blank your results will be sorted by that field.  This is something I had been wondering how to do for some time now.
  • You can also pass a lucene query to the macro.  Allowing you to drill down the results to just what you need.  I couldn’t think of an immediate use for this, but I’ll tuck it away for a rainy day.

The rest of the day, I spent with Jason Tesser in a one-on-one session.  This is the true value of the DotCMS conference.  I am really happy to see a company that will give you one-on-one attention.  Jason and I talked a lot about the nuts and bolts of the Content API and DotConnect Java Classes.  I learned how to use the DotConnect Class to retrieve SQL results from my server and then use the Content API to update and insert new content into DotCMS structures.  Very, very valuable stuff.

After the show a few of had a specialized training on administration of DotCMS.  We learned that you can use JMX to debug some of the more interesting problems may run into with cache and other things in the system.  It looked like really cool stuff, but it was a bit over my head.  Andres did a great job of showing us what can can’t be done though.

I ended up going with a rather large group to a sushi place for dinner.  I am not overly obsessed with sushi, but I went along and the place we went to was very nice.  I had a fried shrimp/lettuce/rice roll that was actually very good.

Friday, Feb 6

Breakfast was at the bookstore again.  We started the day off with Plugins Training.  The training was very well laid out and was my main target for the conference.  Jason covered a ton of information about what you can do with plugins and how they work.  I wish there was more actual code, but when you are talking to a large audience that kind of thing would’ve been hard to pull off. I can’t say how stoked I am about the addition of plugins to the DotCMS product.

One of the cool things you can do with plugins is move all your configuration and custom macros out of DotCMS.  This way if you ever need to restore a server or do an upgrade, you can just stick your plugin back in and you are essentially up and running.  I plan on doing this as my first plugin and hope to have a good post about how it’s all done.  That is, or corse, if Fienen doesn’t beat me to it ;)

The last half of the day was on Ajax.  While I was not overly interested in the ajax stuff, it was interesting to see some of the cool stuff that DotCMS can do there.

After the Ajax session we moved into the Focus Group / Roadmap / Deiscuss / Wrapup portion of the conference.  I can’t tell you how impressed I am with the way DotCMS is developing.  Here is what is in store for us in the coming year:

  • Enterprise Offeringe -vs- Open Source Offerings:  The idea is is to not turn DotCMS into crippleware.  There are quite a few CMSs that go the crippleware route.  In other words, you can have the software for free, but to really get the most out of it you have to pay.  DotCMS is going pretty much the opposite route.  The open source product will always be fully featured.  (Actually, it will most likely be more featured than the Enterprise. )  The Enterprise version will be the hardened product with better supoprt.
  • Plugins, Plugins, Plugins:  Plugins give us a major shift in the way customization of DotCMS is handled.  From the simplest stuff like your configuration or a small macro, to the big stuff like new portlets.   Plugins also push forward community growth.  We hope to see the infamous DotCMSForge this year.  To add to this DotMarketing is also going to be putting on a plugin competition to get the community start on making plugins.
  • 1.7:  What was going to be 1.6.5c is now going to be 1.7.  With this version, slated to come out in the next few weeks, we will see the addition of plugins.  Also, as a first plugin DotMarketing has created Front Ent Content Submition.
  • 1.8: With 1.8 we will see fater releases (to the tune of 1 every 3-4 months).  1.8 will also add the concept of Binary Content.  This will allow us to dirrectly attach files to content along with exporters.  This esentially turns DotCMS into a digital asset / document management system.  Also due for 1.8 is drafting.  The idea is that it will work much like wordpress posts that auto-save or gmail messages.  There are also changed coming for content/page owners, which is something that has not worked as intended in DotCMS.  Lastly, it will add wiki-like link structures to DotCMS.
  • Looking beyond 1.8 there are some big plans for this year.  A simplified UI for permissions, improvements to the Multi-Site Hosting UI, Push Publishing, a better forms builder with chaining, and access to content in the CMS view web services over CMIS.

Wrap Up

So, this has been a really long congolomo-blog post.  Sorry for that.  As you can see the conference was a great source of information!  I thouroughly enjoyed myself and I think everyone that came got a ton of value out of it.  Not to mention the networking possibilities.    There are some really cool things in store for us this year.  To say that I am giddy with anticipation would be an understatement.

Here are some additional links to information about the conference (more as I find them):

Comments Off

.eduGuru Vote & Warhammer Wrapup #5

Posted November 26th, 2008 in Gaming, Projects by cfalzone

My weekly Warhammer Wrapup is up at WeekendGamer:  
http://weekendgamer.wordpress.com/2008/11/25/the-weekly-warhammer-wrapup-5/

Also, Don’t forget to vote for me in the .eduGuru Blogger Contest: 
http://feeds.feedburner.com/~r/DotEduGuru/~3/463906741/id1326-blogger-search-vote.html

Thanks!!

Comments Off

Weekly Warhammer Wrapup #4

Posted November 18th, 2008 in Gaming by cfalzone

My weekly warhammer wrapup is up and ready for you’re viewing pleasure at WeekendGamer’s blog

http://waaagh.wordpress.com/2008/11/18/realm-war-changed-or-standing-still/

Check it out!!

Comments Off

.eduGuru Guest Post

Posted November 18th, 2008 in Projects by cfalzone

I have been dabbling with the idea of separating my Tech/Work posts from my personal blog.  Just as I was thinking of purchasing another domain, along came the .eduGuru Blogger(s) Search Contest.

So, I decided to jump on over and write a guest post to enter the contest.  Head on over to .eduGuru and check out my post and don’t forget to vote for me:

http://doteduguru.com/id1182-xenu-broken-link.html

Thanks!

Comments Off

Weekend Warhammer Update #3

Posted November 5th, 2008 in Gaming by cfalzone

A little late in reporting it, but my Weekend Warhammer Update is up on Weekend Gamer.

http://weekendgamer.wordpress.com/2008/11/04/weekly-warhammer-wrapup-episode-3/