Xomino

Domino with the new improved X

Bluemix Monitoring and Analysis – Diagnostics version

Posted by MarkyRoden on July 21, 2015

In this article I will show how to utilize some aspects of the paid Bleumix Monitoring and Analysis service to look inside the performance of your applications.

State of shock

I am in a state of shock, as I am writing this post I actually broke my application, and used these very tools to figure out why……………..COOL !!!

Introduction

The paid version of Bluemix monitoring and analysis costs $0.03 per application her hour – which equates to about $21 a month per app. Once you turn this on it starts charging – and this is completely outside of the 375GB/Hour free cost. In a week I racked up $5 in charges cos I went away for an extended weekend.

m6

 

I hooked that up to my application and immediately started to see more information about it than the free package

m1

Clicking on the Diagnose button gives me access to more information about my slowest requests

m2

Click on one of the request name options then shows me more information about the response time of that item

m3

 

So how did I break the application?

I am putting together a websockets demo for MWLUG and as part of looking at this monitoring service I started to refresh my website repeatedly, quickly in multiple browsers. This blew up the application and it crashed

m4

Out of memory……weird – how come?

Well as I look at the monitoring tools I can clearly see that the baseline application with no one using it – was hovering over 100M

m5

So clearly we need to add more memory

Go CLOUD

All this preaching about scaling and paying for what you need is all well and good until you actually see it happen. In less than 30 seconds I have more memory applied

m8

and after a quick restart – we can see that we are now not pushing the limit of allocated memory

m7

This is fantastic – because I plan to do a live demo of this application in a room full of people next month – there is a really good chance that this would have crashed when 30 people connected to it – and now there isn’t – and that is freaking awesome !!!!

m9

Posted in Bluemix, DevOps | Leave a Comment »

Marky and John on tour in D.C. next week: 2015-07-28

Posted by MarkyRoden on July 20, 2015

Next week on Tuesday (July 28th), John Head and I will be in the Maryland / D.C / Virginia area and we would love to talk to Domino/XPages/Modern Web Apps teams about their projects and plans for the future of the platform. This is not intended to be a “can you fix this code for me” kinda trip, but more of a strategic learning experience.

If anyone is interested in meeting up please ping me marky @ myblogname . com

Posted in XPages | Leave a Comment »

Bluemix Monitoring and Analytics – free service

Posted by MarkyRoden on July 19, 2015

In this article I will introduce the free IBM Bluemix Monitoring and Analytics service and show some of the available information.

Monitoring and Analytics

From the Bluemix Dashboard select one of your node applications and then “Add a new Service” – scroll down until you find the DevOps section and select Monitoring and Analysis.

a1

 

There are two opens – Free and not Free, in this case we are going to select free.

a2

Once added you have to restage the application

a3

 

 

Once the application is restaged we can access the service from the dashboard – and initially there will be very little of interest/use.

a4

 

But over time you will start to see information build up about how your application is performing within Bluemix. In this case I am using an example from http://pscportal.mybluemix.net – which if you click on the link you will find nothing – that is because I purposefully have nothing running on the root. What is fascinating is how the monitoring shows this and other interesting information.

Once you have added the service you can bind it to all your applications and it will monitor all of them separately.

Investigating a crash

Apparently the application crashed overnight

a7

 

So I wondered what the monitoring said

a6

 

Apparently the application went from zero CPU usage to DEAD right at 3:24am. But what is also really cool and apparent is that the application self healed and restarted itself – how freaking-cloud-cool is that !!

a9

The application is never available – well that is as I would expect – the root has no node path responding to it. There are other routes within the application which work – but not that one.

a8

Looking at the logs we can see that something happened but not much information as to what. I do not have any logging built into the application yet – but I will have to work on that.

XPages

Unfortunately the whole suite of monitoring is not available for XPages yet – I bound the service to my XPages application and all that was visible was he availability. This is still better than nothing.

a10

a11

The not free version

https://www.ng.bluemix.net/docs/services/monana/index.html#monana_paid_feat_c

“You can use the Request Summary dashboard to identify the requests with the slowest response times and use the widgets to drill down and identify blockages. To open the Request Summary dashboard, open theMonitoring and Analytics service, click on the Performance tab and click Diagnose.”

Sounds interesting…….

Conclusion

Doing “DevOps” means constant monitoring of you application. The trick will be to take action based on the monitoring – we will see if we can do that and I will keep watching these logs over time to see what happens to the applications. Admittedly there are next to no users at all – but hey we will see.

 

 

 

 

Posted in Bluemix | Leave a Comment »

XPages in Bluemix – Pushing new changes via Bluemix git repository

Posted by MarkyRoden on July 15, 2015

In this article I will look at modifying the out of the box boilerplate application and starting to look at the tooling around the new XPages in Bluemix capability. I will specifically talk about the use of the Bluemix integrated git repository.

Introduction

In the previous article I walked through the basic steps of creating the boilerplate XPages application in Bluemix. So let’s look at what we created and how we can mess with it :)

The Dashboard

Looking at the dashboard for our new boilerplate application we can start to see a number of items. On the top right there is an option to Add Git

h2

Continuing will create a git repository within the Bluemix integrated jazz hub repository. Once complete you will see a link to the new repo

h3

Clicking on the link will take you to the repo page

h4

We can immediately see from this image that it is not quite what we normally expect from a “source control repo” for XPages development. The entire NSF is part of the repo……but let’s go with it.

Click on the “Git URL” link to get the URL for the repo

h5

I use source tree for this part of the process – Clone New and use the URL for the repo – you will have to log into IBM as well

h6

Once complete you will have the repo locally – it can then be opened in Domino Designer

h7 h8

 

As we have seen before – we have the to do boilerplate application – to which we can add a new simple XPage

h9

h10

Note

You must be using the notes ID provided by bluemix for your notes applications.

Build and then close the application in designer

Within Sourcetree – we commit the changes in the master branch and push to repo

h11

h12

Once that is complete we can refresh the jazz hub repo page and see the committed change

h13

When we created this repo in Bluemix, the automatic build and deploy tasks were created as well – so clicking on the “Build and Deploy” tab on the top right takes us the deploy page where we can see this in action

h14

Once that is complete we can go over to our application http://hub.mybluemix.net/ToDo_design.nsf/marky.xsp and there it is

h15

Conclusion

Using this method we are able to upload a new XPage into the application without using the built in tooling in OpenNTF release v13

Caveats

I did have a build issue, don’t know why (experimental code) but clicking the redeploy button fixed it.

Don’t forget to build before you send to Bleumix (duh Marky)

I am not sure I recommend this manner of deploying an application to Bluemix via this method – I just wanted to see if it was possible.

 

 

 

Posted in Bluemix, XPages, XPages in Bluemix | 4 Comments »

XPages in Bluemix – Looking at the application dashboard

Posted by MarkyRoden on July 14, 2015

In this article I will explain the XPages in Bluemix application dashboard and what is available to the developer from the Bluemix web interface.

The Dashboard

Once you have created your new XPages application in Bluemix it will appear on the “Dashboard” with a weird spacecraft for an icon.

b6

Clicking on the box will review a lot about your application

b11

Link to the application

Clicking on the link at the top left will open your application in a new window

Clicking on the pencil next to it allows you to edit and / or create an additional subdomain for the application (yes it can have many)

b12

Add Git

Clicking on this link will automatically create a source control site for this application

b13

Memory allocated ($$$)

By default the application has 512M allocated to it. Once XPages in Bluemix goes live this will become more significant – this is the number by which Bluemix determines how much you get charged each month. Throughout Bluemix you are charged by the GigaByte hour. That is the number of Gigabytes utilized by a running application each hour. so in this case 512M for an hour is 0.5 Gigabyte hours. Over a typical month that is 720 hours, or 360GBHours. The free allocation is typically 375hours. So this one application running for a month is all you would have “free”. You can reduce this value through the menu, but what you need will be based on your application. Right now (July 2015) XPages is free – keep an eye on it !!!

VCAP services

On the bottom of the smaller box for IBM XPages NoSQL Database you will see a down arrow – if you click on it you will see what are called the “VCAP” services. These are the Cloud Foundry Environmental Variables.

“Environment variables are the means by which the Cloud Foundry runtime communicates with a deployed application about its environment. This page describes the environment variables that Droplet Execution Agents (DEAs) and buildpacks set for applications.”

b14

This JSON construct is critical to telling Bluemix how the XPages boilerplate application works. When you use the self selection to deploy the application all this information is created on the fly. Looking at the labels for the data they should be relatively self explanatory for a Domino developer.

 

 

 

 

 

Posted in Bluemix, XPages, XPages in Bluemix | Leave a Comment »

XPages in Bluemix – where is the design and where is the data?

Posted by MarkyRoden on July 13, 2015

Digging into the code for the example database – aaaah memories – but I digress…..as normal I am mostly blogging this for my own notes and if someone else happens to get something out of it – great :D

Design and Data are separate?

So the design and the data are separate – well kinda – in fact “some” of the design is separate and “all” of the data is. Following the instructions on how to deploy the starter code and mess with it I managed to change the database and add a new XPage.

BTW for those who cannot find “Start Coding” it is here….took me ages to find it in front of my nose

b1

Notes client

So the database look like this in the notes client – pretty normal

c1

and viewing the design of this database we can see forms, views and No XPages of worth

c2

The data can be changed through the notes client and immediately represented on the website

c3

The Design

Looking at the boilerplate code which was downloaded from starter code we can see – no data, no form, no views – but there are the XPages

c4

New design elements

So I created a XPage in the Design database and followed the instructions on deploying the new code – it worked

c5

Adding a new form to the VIEW database, failed.

Adding a new form to the DESIGN database worked just fine

c6

 

Conclusion – So where is everything again?

Views and Data are in the NoSQL database

XPages and Forms and in the Design database

There is a lot to learn here……..and a lot of questions….

Posted in Bluemix, XPages, XPages in Bluemix | 2 Comments »

Creating my first true XPages in Bluemix application

Posted by MarkyRoden on July 12, 2015

In this post I will document my attempt to create my first XPages application in Bluemix. I will be following the documentation (ish) and also clicking around to see what happens. This was written July 2015 and is likely out of date soon after.

OpenNTF

I installed the new ExtLib by downloading the last release, then in designer installing the new eclipse plugin. This is not necessary for the sake of this post but will be later.

Bluemix

Go to the Catalog, then scroll to the bottom and select “Looking for more”

b1

Then from the next page select the XPages Web Starter

b2

 

You will then get the screen to create the instance – over on the right give it a name – in this case I called it xpages

b3

Select Create

and you will get a screen telling you it is being created

b4

b5

 

Click on the “Dashboard” link at the top

b6

Click on the box for the new application (xpages in this case)

b7

Then we click on our new application link at the top – http://xpages.bluemix.net and there we have it.

b8

 

Conclusion

Setting up our first application was a very simple set of clicking options. This is cloud – self service deployment of services and capabilities.

Posted in Bluemix, XPages, XPages in Bluemix | 1 Comment »

XPages in Bluemix – Experimental is live

Posted by MarkyRoden on July 10, 2015

Finally – we have XPages in Bluemix. It is currently “Experimental” which means nothing is guaranteed to function as expected, it is basically a good Alpha made available to early adopters for testing. This means that at any time, things could change. The model, the process, the everything. So while there is much to learn, much to play with….

This is absolutely 100% NOT production ready

Here are the links to the documentation

  1. Building apps with the IBM XPages for Bluemix runtime
  2. Getting started with IBM XPages NoSQL Database for Bluemix
  3. The new OpenNTF ExtLib release

 

There is a lot to cover and I know a number of people are looking at it. XPages exists in Bluemix as two completely separate entities.

  1. The XPages runtime based on JSF
  2. The XPages NoSQL data store

Why are they not one NSF like normal??

Tony McGuckin explained it all to me in Orlando back In January. It was one of those surreal conversations where everything he said made sense as it came out of his mouth and yet at the end of the conversation I knew nothing more than – oooo that makes sense………and I am clearly now more stupid than I was 20 minutes ago. Hopefully he will be able to better explain to us some day. 

So here is what I think I understood – it is to do with the way that Cloud Foundry underpins Bluemix. The runtime container which is running on top of Bluemix has to be able to run without the NoSQL data piece. For the sake of uptime failover, scaling and other fundamental aspects of Cloud Foundry I don’t entirely understand, they are separate. A side aspect of this means that the runtime is not dependent on the Notes NSF structure to create applications.

As normal – I have way more questions than answers – so let’s get rocking :)

 

 

 

Posted in Bluemix, XPages | 2 Comments »

An introduction to creating Domino applications in the Bluemix environment – SocialBizUg Webinar July 23rd

Posted by MarkyRoden on July 8, 2015

I am very happy to announce that on July 23rd, myself and Toby Samples, will be presenting a SocialBizUg webinar with the illustrious Martin Donnelly.

The topic as the title suggests is an introduction to creating Domino applications in Bluemix.

A link for the event is provided below – We look forward to showing you this exciting new capability.

https://www.socialbizug.org/blogs/ac3c982e-c4bb-4553-ae9c-6633f03e5ee8/entry/July_23_Webcast_An_introduction_to_creating_Domino_applications_in_the_Bluemix_environment?lang=en_us

 

Abstract

Companies are looking to the cloud more and more for cost savings and to facilitate the creation of new modern applications. Join this webcast to find out how Bluemix – IBM’s Platform as a Service (PaaS) cloud offering – can help create applications quickly, securely, and in a scalable manner. Get an introduction to Bluemix, what it offers, and more specifically how XPages and REST play a role key in it.
Join this webcast and learn how to:

  • Easily get Bluemix up and running and how to create your own XPages applications quickly.
  • Integrate with the other services available within the Bluemix ecosystem.
  • Maximize the new and exciting possibilities this integration opens up to the Domino community.

 

Posted in Bluemix, SocialBizUg, XPages | Leave a Comment »

Speaking at MWLUG 2015: WebSockets – “Pushing” the web forward

Posted by MarkyRoden on July 7, 2015

This year at the MWLUG conference in Atlanta I will be speaking about something near and dear to my heart – WebSockets.

I will introduce the concept and demonstrate the many advantages of using WebSockets over traditional HTTP requests. As always I have a number of demos, this year interactive ones that will require audience participation. If you are considering attending MWLUG I strongly encourage you to do so – there are a large number of excellent speakers, much to learn and much to share. It is always a great event.

Hopefully see you then :)

Abstract

Since it’s inception XHR has been an asynchronous process of browsers requesting data from servers and waiting for a response. The constant polling to ask “Has something changed?”, “No”. “Has something changed?”, “No” is such a waste! WebSockets changes the paradigm and allows the server to “push” information to the browser, as an when it needs to. This reduces network traffic, allows multiple users to get notified at the same time, speeds up applications, makes developers happy and makes users happy. In this presentation Mark will introduce the concepts of WebSockets as a modern web technology, demonstrate how it works and provide numerous examples. Come and see how WebSockets will change your perception on how applications will work in the future.

Posted in MWLUG | 1 Comment »