[JBoss Tools] - Content assist goes wrong after installed Hibernate-tools
by 背泳的 鱼
背泳的 鱼 [https://community.jboss.org/people/fish47] created the discussion
"Content assist goes wrong after installed Hibernate-tools"
To view the discussion, visit: https://community.jboss.org/message/750374#750374
--------------------------------------------------------------
Hi everyone, recently I got a problem as you can see from the title. Hope you can give me some tips (solutions better). Thanks a lot.
Platform
OS: Ubuntu 12.04
Eclipse: Java Developers Edition, Indigo SR2
Hibernate-tools: 3.4.x for Indigo (I download it from Marketplace)
Situation
After installed the Hibernate-Tools, whenever I use content assist, Eclipse shows the dialog below:
http://www.eclipse.org/forums/index.php/fa/10833/0/ (http://www.eclipse.org/forums/index.php/fa/10833/0/)
Moreover, when I do something relation to dialog, Eclipse also shows the dialog like this:
http://www.eclipse.org/forums/index.php/fa/10834/0/ (http://www.eclipse.org/forums/index.php/fa/10834/0/)
Tried Solution (all failed)
www.codeweblog.com/eclipse-hibernate-proposals
stackoverflow.com/questions/1367306/eclipse-java-content-assist-not-working
A Piece of Log:
!SESSION 2012-07-24 14:39:40.778 -----------------------------------------------
eclipse.buildId=M20120208-0800
java.version=1.7.0_05
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=zh_CN
Framework arguments: -product org.eclipse.epp.package.java.product
Command-line arguments: -os linux -ws gtk -arch x86 -product org.eclipse.epp.package.java.product
!ENTRY org.eclipse.jdt.ui 4 0 2012-07-24 14:39:59.234
!MESSAGE The 'org.eclipse.jpt.jpa.ui.JpaJpqlCompletionProposalComputer' proposal computer from the 'org.eclipse.jpt.jpa.ui' plug-in did not complete normally. Unable to instantiate the extension.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/750374#750374]
Start a new discussion in JBoss Tools at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&con...]
12 years, 5 months
[JBoss Tools] - Observations from two year of ping-backs from JBoss Tools users
by Max Rydahl Andersen
Max Rydahl Andersen [https://community.jboss.org/people/maxandersen] modified the blog post:
"Observations from two year of ping-backs from JBoss Tools users"
To view the blog post, visit: https://community.jboss.org/community/tools/blog/2012/07/30/observations-...
--------------------------------------------------------------
Almost two years ago we started including an opt-in ping-back functionallity to JBoss Tools and Developer Studio installations. The ping-back has in that time given us a lot of good and sometimes surprising information about our users.
In this blogpost I want to give you the highlights of these observations.
h1. Disclaimer
Before I start I must underline that we do not track any individuals data and it is all opt-in, i.e. users need to explicitly say “Yes - please send pings” for us to pick up data.
The data below is not for +all+ users of our tools, it is only for those who have said yes to participate - but with the amount of pings we do get (currently 28K/day, 6+ million/year) I believe it is a signficant high part of our user base to at least give an idea about the trends and divisions of our user base.
I’ve tried my best to validate and ensure I report correct findings - please leave a comment if you believe I’ve made an error or there is some other metric you would like to know about.
And finally - the content, observations and conclusions in this blog are my personal views based on my intepretation of the analytics data I have access to.
h1. Methodology
The way our ping-back works from a highlevel is that on startup of an Eclipse instance a HTTP GET is made to Google Analytics and here the data is collected as if it was a web page hit (i.e. Google Analytics gathers information from the network connection, HTTP headers and URL parameters).
We only make maximum one ping every 24-hour per Eclipse Instance and it is only on startups. Thus if you have your eclipse instance running for six days, you only make one ping in those six days.
I’ve used Google Analytics web UI and data extraction features as a basis for the findings below.
h1. Operating Systems
If you should be in doubt, Microsoft Windows is by far the most dominant desktop OS out there when it comes to desktop OS, and this is no different for users of JBoss Tools.
Here is Operating Systems for June-July 2012:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19110/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
Even if you separate out Windows XP on its own then Windows XP users outnumber Linux + OSX users combined.
Operating Systems for June-July 2012 with XP separated out.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19111/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I saw these same splits in our usage tracking (Windows: ~80%, Linux: ~15% OSX: ~5%) and I was worried we were having some bug in our ping-back code.
I therefore got access to Google Analytics for several of our jboss.org project sites including all of community.jboss.org and here the splits are more or less the same no matter how you slice and dice it. Thus either this split is true or Google Analytics is wrong everywhere.
What surprises me though is that Windows is even growing over time, both on site visits and JBoss Tools ping back:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19112/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I’m sure the growth of Windows here does not resemble the growth of operating systems world wide, I believe it is more a function of more and more “real world” industrial users picking up and using JBoss technology.
I know it surprises alot of people both inside and outside of my current employer (Red Hat) who would like to think Linux is not just primarily a server side OS anymore; and I know of a lot of conference attendees who claims OSX is “everywhere”. It might be everywhere at conferences, but not out there in the “real world”.
h1. Linux Distributions
Once you get pass the fact Windows is by far the biggest desktop platform then it is interesting to look at how the various Linux distributions spread out.
The following charts shows a summary of Linux distributions as detected by our ping-back code to https://source.jboss.org/browse/JBossTools/trunk/usage/plugins/org.jboss.... detect Linux distributions.
Our ping-back report back the distribution name and version as found in various distribution specific files and I’ve taken these reports and stripped out the versions and just looked at the distribution name.
I unfortunately do not have any way of confirming the validity of these numbers because Google Analytics does not report this level of detail for specific websites and looking at http://distrowatch.com/dwres.php?resource=popularity distrowatch.com the numbers are very different. Probably the difference should be explained in difference of Desktop vs. Server, Linux users vs. JBoss/Middleware users.
In any case please do take these uncertainties into account when considering these numbers.
The graphs below is for the period June-July 2012:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19113/l... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19114/l... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
h1. Countries
One of my favorite images from Google Analytics is the map showing city activity across the world.
City Activity 2011-2012 ( a full year )
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19115/c... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
That is showing JBoss Tools being used across 6 continents, 177 countries in 9644 cities; and as you can see it is not United states nor Europe that is lighting up the most.
Most active cities are in areas such as Brazil, China and India, which also is revealed in the Top 10 countries list for 2011-2012.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19116/t... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I apparently need to learn to write blogs in Portuguese and Mandrin!
I was asked how the Operating System varies across countries and that was a bit trickier to extract because Google Analytics starts sampling when the dataset gets too big - but here is a table showing OS per Top 10 countries based on 80% of data collected in June 2012.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19117/c... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
It’s interesting to see United States OS X usage be almost twice as high as any other country and countries like China and South Korea having ~98% usage of Windows.
Where as countries like Brazil has a much higher percentage using Linux.
Users from Spain and Italy have same Linux usage but Italy has twice as many Mac users.
h1. Screen resolution
In the last year, we’ve seen no less than 7995 different screen resolutions.
The number was much higher than I expected, and I believe this is caused by differences in how Java/SWT differs across various OS releases on how the desktop resolution is reported; thus the Top 10 screen resolutions is a rough estimation.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19118/t... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
What is interesting though is that the number of observed 1366x768 screen resolutions have grown much more than other screen resolutions.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19119/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
It’s as if everyone started to get more and more HD laptops/displays the last couple of months.
One thing I did notice was that there is a few (or just one?) user that has some very large multi-screen setups. Tried to visualize this by showing smallest (640x480), most common (1366x768) and largest observed screen resolution (11520x2400) relatively to each other in this diagram:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19120/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
The large resolutions are probably multiple monitors, not just one single monitor. My guess is the largest reported is a couple of http://en.wikipedia.org/wiki/WQUXGA WQUXGA screens. think I got screen envy!
h1. Java version
Java 7 was released “recently” and I got more than a few request asking why we still support Java 6 when it is EOL and Java 7 is the new kid in town.
The answer is in the following graph. It shows the uptake of the most popular Java versions over the last year.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19121/j... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
You can see Java 1.6.0_26 overtake 1.6.0_24 in July 2011 and similar 1.6.0_29 takeover in November 2011 and finally 1.6.0_31 is the current big winner.
Java 1.7 had only little uptake, and its only recently Java 7 is above 20% usage.
The current %’s shows a clear 76% usage of 1.6, following with Java 1.7 with 22% and then a few (2%) is still using Java 1.5 - we, even had a few Java 1.8 users but they are still below 0.01% thus not visible on any of the graphs.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19122/j... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I expect over the next year Java 1.7 will have a bigger uptake, but I would not bet on it overtaking Java 1.6 anytime soon.
h1. Conclusions
One nice thing to conclude from our usage tracking is that we can see that JBoss Tools keeps growing and has more and more uptake and I’m personally very happy to see that.
Beyond that my primary lesson from the gathering of analytics is that Windows XP is bigger than Linux and OS X combined. Windows overall is where the majority of real-world users are.
There are probably also lot of interesting political and world-economic comments that can be made about the Top 10 countries usage of Operating Systems. But this is just JBoss Tools users, thus not sure how this maps to the world-arena but one thing I do think we can conclude is - each country has very different composition of users/demographics; but they all primarily uses Windows.
Therefore if you are doing any work on tools, frameworks or applications that relate to JBoss user/developer, +please+ remember to test it on Windows, including Windows XP no matter how much you hate this OS your users are using your applicaiton/frameworks to make their own life easier.
Before anyone put words in my mouth any say this means Linux and OS X users should be ignored because they are such a small percentage - that is not true since the uptake of Windows over time shows that Linux/OSX is where a good portion of the “early adopters” are.
That is it for this time, let me know what you think - does this match your expectations ? Could we improve the dataset/statistics somehow ?
Have fun,
Max
--------------------------------------------------------------
Comment by going to Community
[https://community.jboss.org/community/tools/blog/2012/07/30/observations-...]
12 years, 5 months
[JBoss Tools] - Observations from two year of ping-backs from JBoss Tools users
by Max Rydahl Andersen
Max Rydahl Andersen [https://community.jboss.org/people/maxandersen] modified the blog post:
"Observations from two year of ping-backs from JBoss Tools users"
To view the blog post, visit: https://community.jboss.org/community/tools/blog/2012/07/30/observations-...
--------------------------------------------------------------
Almost two years ago we started including an opt-in ping-back functionallity to JBoss Tools and Developer Studio installations. The ping-back has in that time given us a lot of good and sometimes surprising information about our users.
In this blogpost I want to give you the highlights of these observations.
h1. Disclaimer
Before I start I must underline that we do not track any individuals data and it is all opt-in, i.e. users need to explicitly say “Yes - please send pings” for us to pick up data.
The data below is not for +all+ users of our tools, it is only for those who have said yes to participate - but with the amount of pings we do get (currently 28K/day, 6+ million/year) I believe it is a signficant high part of our user base to at least give an idea about the trends and divisions of our user base.
I’ve tried my best to validate and ensure I report correct findings - please leave a comment if you believe I’ve made an error or there is some other metric you would like to know about.
And finally - the content, observations and conclusions in this blog are my personal views based on my intepretation of the analytics data I have access to.
h1. Methodology
The way our ping-back works from a highlevel is that on startup of an Eclipse instance a HTTP GET is made to Google Analytics and here the data is collected as if it was a web page hit (i.e. Google Analytics gathers information from the network connection, HTTP headers and URL parameters).
We only make maximum one ping every 24-hour per Eclipse Instance and it is only on startups. Thus if you have your eclipse instance running for six days, you only make one ping in those six days.
I’ve used Google Analytics web UI and data extraction features as a basis for the findings below.
h1. Operating Systems
If you should be in doubt, Microsoft Windows is by far the most dominant desktop OS out there when it comes to desktop OS, and this is no different for users of JBoss Tools.
Here is Operating Systems for June-July 2012:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19110/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
Even if you separate out Windows XP on its own then Windows XP users outnumber Linux + OSX users combined.
Operating Systems for June-July 2012 with XP separated out.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19111/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I saw these same splits in our usage tracking (Windows: ~80%, Linux: ~15% OSX: ~5%) and I was worried we were having some bug in our ping-back code.
I therefore got access to Google Analytics for several of our jboss.org project sites including all of community.jboss.org and here the splits are more or less the same no matter how you slice and dice it. Thus either this split is true or Google Analytics is wrong everywhere.
What surprises me though is that Windows is even growing over time, both on site visits and JBoss Tools ping back:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19112/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I’m sure the growth of Windows here does not resemble the growth of operating systems world wide, I believe it is more a function of more and more “real world” industrial users picking up and using JBoss technology.
I know it surprises alot of people both inside and outside of my current employer (Red Hat) who would like to think Linux is not just primarily a server side OS anymore; and I know of a lot of conference attendees who claims OSX is “everywhere”. It might be everywhere at conferences, but not out there in the “real world”.
h1. Linux Distributions
Once you get pass the fact Windows is by far the biggest desktop platform then it is interesting to look at how the various Linux distributions spread out.
The following charts shows a summary of Linux distributions as detected by our ping-back code to https://source.jboss.org/browse/JBossTools/trunk/usage/plugins/org.jboss.... detect Linux distributions.
Our ping-back report back the distribution name and version as found in various distribution specific files and I’ve taken these reports and stripped out the versions and just looked at the distribution name.
I unfortunately do not have any way of confirming the validity of these numbers because Google Analytics does not report this level of detail for specific websites and looking at http://distrowatch.com/dwres.php?resource=popularity distrowatch.com the numbers are very different. Probably the difference should be explained in difference of Desktop vs. Server, Linux users vs. JBoss/Middleware users.
In any case please do take these uncertainties into account when considering these numbers.
The graphs below is for the period June-July 2012:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19113/l... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19114/l... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
h1. Countries
One of my favorite images from Google Analytics is the map showing city activity across the world.
City Activity 2011-2012 ( a full year )
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19115/c... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
That is showing JBoss Tools being used across 6 continents, 177 countries in 9644 cities; and as you can see it is not United states nor Europe that is lighting up the most.
Most active cities are in areas such as Brazil, China and India, which also is revealed in the Top 10 countries list for 2011-2012.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19116/t... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I apparently need to learn to write blogs in Portuguese and Mandrin!
I was asked how the Operating System varies across countries and that was a bit trickier to extract because Google Analytics starts sampling when the dataset gets too big - but here is a table showing OS per Top 10 countries based on 80% of data collected in June 2012.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19117/c... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
It’s interesting to see United States OS X usage be almost twice as high as any other country and countries like China and South Korea having ~98% usage of Windows.
Where as countries like Brazil has a much higher percentage using Linux.
Users from Spain and Italy have same Linux usage but Italy has twice as many Mac users.
h1. Screen resolution
In the last year, we’ve seen no less than 7995 different screen resolutions.
The number was much higher than I expected, and I believe this is caused by differences in how Java/SWT differs across various OS releases on how the desktop resolution is reported; thus the Top 10 screen resolutions is a rough estimation.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19118/t... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
What is interesting though is that the number of observed 1366x768 screen resolutions have grown much more than other screen resolutions.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19119/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
It’s as if everyone started to get more and more HD laptops/displays the last couple of months.
One thing I did notice was that there is a few (or just one?) user that has some very large multi-screen setups. Tried to visualize this by showing smallest (640x480), most common (1366x768) and largest observed screen resolution (11520x2400) relatively to each other in this diagram:
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19120/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I think I got screen envy!
h1. Java version
Java 7 was released “recently” and I got more than a few request asking why we still support Java 6 when it is EOL and Java 7 is the new kid in town.
The answer is in the following graph. It shows the uptake of the most popular Java versions over the last year.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19121/j... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
You can see Java 1.6.0_26 overtake 1.6.0_24 in July 2011 and similar 1.6.0_29 takeover in November 2011 and finally 1.6.0_31 is the current big winner.
Java 1.7 had only little uptake, and its only recently Java 7 is above 20% usage.
The current %’s shows a clear 76% usage of 1.6, following with Java 1.7 with 22% and then a few (2%) is still using Java 1.5 - we, even had a few Java 1.8 users but they are still below 0.01% thus not visible on any of the graphs.
https://community.jboss.org/servlet/JiveServlet/showImage/38-5000-19122/j... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-5000-191...
I expect over the next year Java 1.7 will have a bigger uptake, but I would not bet on it overtaking Java 1.6 anytime soon.
h1. Conclusions
One nice thing to conclude from our usage tracking is that we can see that JBoss Tools keeps growing and has more and more uptake and I’m personally very happy to see that.
Beyond that my primary lesson from the gathering of analytics is that Windows XP is bigger than Linux and OS X combined. Windows overall is where the majority of real-world users are.
There are probably also lot of interesting political and world-economic comments that can be made about the Top 10 countries usage of Operating Systems. But this is just JBoss Tools users, thus not sure how this maps to the world-arena but one thing I do think we can conclude is - each country has very different composition of users/demographics; but they all primarily uses Windows.
Therefore if you are doing any work on tools, frameworks or applications that relate to JBoss user/developer, +please+ remember to test it on Windows, including Windows XP no matter how much you hate this OS your users are using your applicaiton/frameworks to make their own life easier.
Before anyone put words in my mouth any say this means Linux and OS X users should be ignored because they are such a small percentage - that is not true since the uptake of Windows over time shows that Linux/OSX is where a good portion of the “early adopters” are.
That is it for this time, let me know what you think - does this match your expectations ? Could we improve the dataset/statistics somehow ?
Have fun,
Max
--------------------------------------------------------------
Comment by going to Community
[https://community.jboss.org/community/tools/blog/2012/07/30/observations-...]
12 years, 5 months
[JBoss Tools] - Deploy from Eclipse to OpenShift in a breeze
by Max Rydahl Andersen
Max Rydahl Andersen [https://community.jboss.org/people/maxandersen] modified the blog post:
"Deploy from Eclipse to OpenShift in a breeze"
To view the blog post, visit: https://community.jboss.org/community/tools/blog/2012/06/27/deploy-from-e...
--------------------------------------------------------------
*
#Dont_get_your_fingers_dirty_use_the_JBoss_Tools_for_OpenShift Dont get your fingers dirty, use the JBoss Tools for OpenShift
**
#Get_the_tools_get_started Get the tools, get started
*
#A_very_basic_workflow A very basic workflow
**
#Create_your_application_runtime Create your application runtime
**
#Push_to_build_and_deploy Push to build and deploy
**
#Server_Adapter_to_the_rescue Server Adapter to the rescue
*
#Deploy_my_very_own_project Deploy my very own project!
**
#Have_your_project_ready Have your project ready
**
#JBoss_Tools_configure_my_project JBoss Tools, configure my project
**
#Oh_my_project_how_you_changed Oh my project, how you changed!
**
#Push_me_up_Scotty Push me up, Scotty
**
#Multimodule_maven_projects Multi-module maven projects
*
#My_maven_project_is_not_in_the_git_repo_root My maven project is not in the git repo root
**
#Have_your_project_ready_117916 Have your project ready
**
#Create_your_OpenShift_application Create your OpenShift application
**
#OpenShift_here_I_come OpenShift, here I come
*
#But_hey_my_project_does_not_work But hey, my project does not work!
**
#Commit_log Commit log
**
#Inspect_your_server_logs Inspect your server logs
**
#Look_into_the_jboss_as7_management_console Look into the jboss as7 management console
*
#Debug_your_application_with_the_Eclipse_Debugger Debug your application with the Eclipse Debugger
h1. Dont get your fingers dirty, use the JBoss Tools for OpenShift
https://openshift.redhat.com/app/ OpenShift is the PaaS offering from http://www.redhat.com Red Hat. It gives you your personal application platform on demand. With OpenShift, there's no need to look for hosting and application stack. OpenShift provides you those within minutes, whenever you need them.
http://www.jboss.org/tools JBoss Tools for OpenShift offers a feature complete environment to work with OpenShift. From developing to deploying, JBoss Tools provides you a fully fledged environment for your project and aligns with the standard workflows within Eclipse. It allows Eclipse users to stick to their favorite IDE and deal with OpenShift within their developement environment. Especially the OpenShift server adapter mimics an http://www.eclipse.org/webtools/ Eclipse WTP compliant way of deploying to OpenShift and hides the complexity, that you'd otherwise had to handle when publishing bare metal (which is by using Git).
h2. Get the tools, get started
The https://community.jboss.org/community/tools/blog/2012/06/21/jboss-tools-3... release blog shows you extensively how to get JBoss Tools from our update site, from the Eclipse marketplace or even how to install the https://devstudio.jboss.com/download/ JBoss Developer Studio. If installing JBoss Tools, you'll have to make sure you choose at least the OpenShift bundles on our update site:
https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188... (https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18803/u...)
Once you have JBoss Tools installed, you'll spot our wizards either in JBoss Central or in the Eclipse Wizards:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18806/c... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
All you need to get started quickly is offered within this wizard. It'll create your application platform, import a starter project and create a server adapter that you may use to publish to the PaaS.
OpenShift of course requires you to have an account. If you have none yet, the wizard will drop you to the signup form by hitting the link that is displayed on the first wizard page.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18807/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
Once you have your account, you'll be ready to go, ready to get amazed by JBoss Tools and OpenShift.
h1. A very basic workflow
OpenShift is a http://en.wikipedia.org/wiki/Platform_as_a_service PaaS, a Platform as a Service. As such it offers you your personal application stack and it does this on demand. A range of standards runtimes are offered to you whenever you need them. Working with the PaaS is as simple as importing a stub (the starter application) to your workspace, changing and publishing it again:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18892/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2. Create your application runtime
It all starts by creating your own application runtime. In the OpenShift Application wizard, set a name and choose the application (runtime) you need:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18809/a... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
OpenShift offers a wide range of standard runtimes. You may to choose among php, ruby, phython, nodejs etc. Java developers will be most amazed to see that OpenShift offers a fully Java EE 6 compliant application server: the blazing fast http://www.jboss.org/as7 JBoss AS 7.1.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18810/a... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
You may also add different extensions to your platform ranging from SQL- (like MySQL or Postgres) or NoSQL-databases (like MongoDB) up to your very own CI server (jenkins).
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18811/a... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
Once you made up your choices and finish the wizard, it'll create your OpenShift application, wait for it to become reachable and import it's initial content - a starter application - to your Eclipse workspace. Looking into your Project Explorer or Navigator, you'll spot the new project that the wizard imported. It has the very same name as the OpenShift application. In case of a JBoss AS7 runtime, the starter app is a maven artifact and the project we import to your workspace will have the name that's configured for the maven artifact.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18852/i... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2. Push to build and deploy
The new project in your Eclipse workspace is where you apply your changes. It is shared with a git repository on your local machine. This repository is a clone of the git repository within your OpenShift application.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18853/a... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
Deploying this project to the PaaS is as simple as pushing the local repository to it's origin, the OpenShift git repository. OpenShift will then build and deploy your application to the application runtime.
In case of a Java application, OpenShift relies on a maven based build, that is triggered with each git push:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18817/a... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2. Server Adapter to the rescue
When dealing with git, you have to deal with a brilliant but rather complex code versioning system. Even if you're familiar with git, there's still room to reduce the number of manipulations when publishing.
http://www.eclipse.org/webtools/ Eclipse WTP server adapters historically allow you to interact with your server. This would typically be some local or remote server you'd have file- or SSH-based access to. We adapted this handy concept and implemented a variant that would work with OpenShift. This server adapter hides the complexity of dealing with git and allows 1-click publishing to the cloud.
The OpenShift Application wizard sets the adapter up when you create your application and import the starter project to your workspace. Our Server adapter is bound to the OpenShift project in your workspace and it'll do the git operations for you.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18818/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
When publishing it will deploy the changes in your OpenShift project to the PaaS. It'll hide all the complexity that is inherent to git. It will commit your changes to your local clone and push them to the git repository of your OpenShift application (the origin).
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18819/s... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h1. Deploy my very own project!
Importing the starter application to your workspace is the most simple usecase we provide. I bet most users already have a project that they'd want to deploy though. We of course also provide this ability in our OpenShift Application wizard.
Our little screencast shows you the steps when starting with your very own project. It uses the kitchensink example to demonstrate how this would occourr. You may get it on github:
> *Kitchensink example project:*
>
> https://github.com/adietish/kitchensink.git https://github.com/adietish/kitchensink.git
h2. Have your project ready
You first have to get your project to Eclipse. We only support *git-shared or non-shared project* though. A typical usecase would be to have your project on https://github.com/ github or in any other git repository.You then simply clone it's repository to your local machine (using http://www.eclipse.org/egit/ EGit or the command line) and import the project within it to your Eclipse workspace.
h2. JBoss Tools, configure my project
You then create your OpenShift application in our wizard, provide the name, type and eventually additional cartridges. You then switch to the second wizard page and tell the wizard that you dont want to create a new project in your workspace. You tell it to use your project instead.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18854/u... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
The wizard will warn you about upcoming changes to your project and ask you to confirm:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18886/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2. Oh my project, how you changed!
We then add OpenShift specific configurations to your project. These changes unfortunately cannot be undone. You'd have to provide your own means (ex. a separate branch) if you dont want these additions in your developement code The changes we apply are the following:
> *All changes:*
> *
> *
> * eventually create a git repository and commit your project to it
> * add a *.op**enshift* folder with openshift specific hooks
> * add a *deployments* folder
> * add the Eclipse specific files (.project, .classpath etc.) to the *.gitignore*
> * add *openshift-profile* to the pom
> * add OpenShift *git repo as remote* to your local git repo
>
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18855/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
Since publishing to OpenShift is git pushing to it, we'll make sure your project is shared to a *git repo*. We therefore eventually create a git repository for your project if there's none yet and add your project to it.
We add the *.openshift* folder which may contain OpenShift specific configurations and tweaks (like custom build-scripts, markers, cron entries etc.). We also create a *deployments* folder which OpenShift will use to build to. You may also add additional artifacts to it.
We then tweak *.gitignore* and add the Eclipse specific files so that they dont make it to the git repo by default.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18857/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
For maven-based java projects we tweak the *pom* and add an openshift profile to it.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18858/o... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
The openshift profile is what the PaaS is using when building your project on the PaaS. The profile we add is telling maven to create the war in the deployments folder. The deployments folder is where JBoss AS7 is expecting and picking new deployables from. Adding the profile makes sure that your project is deployed when it is built.
We'll also then add the OpenShift application git repo as *remote* to the git repo of your local project. This will allow you to push your project to OpenShift without knowing about the exact url you'll have to push to. All you have to know is what name the OpenShift repo is stored at.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18871/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
We're storing the OpenShift application git url as "openshift" in the remotes known to your local repo. You may of course tell the wizard to use any name you like:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18872/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2. Push me up, Scotty
Once we configured your project, we commit the changes to your local git repo (either your project was already shared with a git repo or we created one for you). To now deploy your project to OpenShift, you'd have to go to the Servers view, choose the OpenShift server adapter (that we created for you) and tell it to *publish*. The server adapter will then detect that the local project is ahead of the remote one and that publishing would only be possible when overriding the remote starter application. It'll ask you to confirm this step:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18887/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
Once the publishing is done, you'll have your project running on OpenShift!
h2. Multi-module maven projects
Our OpenShift Application wizard also supports multi-module maven projects. You'd simply have to make sure all modules are nested within a parent project and choose the parent project as existing project (multi vs. multi-web, multi-ejb, multi-ejb in my screenshot) in the wizard:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18889/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18890/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
> *Note:*
>
> in case your multi-module maven project is an ear, there are still slight limitations in our tooling for the moment. You may easily work around them though. You'd have to alter the maven profile in the pom of your parent-projec and replace the maven-war-plugin by the maven-ear-plugin:
>
> https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18870/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
>
> You may read about it in all details and track our progress on it in https://issues.jboss.org/browse/JBIDE-12252 JBIDE-12252
h1. My maven project is not in the git repo root
When deploying an existing project to OpenShift, you'd have to tell the wizard in JBoss Tools about your project. Your project would have to comply to a basic layout though. We expect the pom in the root of your git repository. If this is not the case, then you'd have to take an alternative approach when publishing. Publishing then gets as easy as drag and dropping your project to the adapter.
In our screencast, we show you how to proceed. We use the the ticket-monster example project which is available at github:
> *Ticket-monster example project:*
>
> https://github.com/jboss-jdf/ticket-monster https://github.com/jboss-jdf/ticket-monster
h2. Have your project ready
The first thing to do is to import your application to your Eclipse workspace. The only requirement we have is that your project shall be http://www.eclipse.org/webtools/ Eclipse WTP compliant. It may be a Dynamic Web or a Maven project. Maven projects are turned into Eclipse WTP projects if you have https://www.eclipse.org/m2e-wtp/ m2e-wtp installed when importing them (m2e-wtp bridges the gap between Eclipse WTP and maven, it turns any maven project into a WTP compliant project).
In the ticket-monster example, the maven project is nested into the demo folder:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18881/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
We import with the Eclipse Maven import wizard pointing it to the demo-folder:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18893/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
and get the demo-folder imported to our workspace:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18894/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2.
h2. Create your OpenShift application
Once you have your project ready you'll go and create the OpenShift application that will host your application. Launch the OpenShit Application wizard in JBoss Tools, tell it to create a *jbossas-7* application and let it import the starter app, as shown in the first paragraphs of this blog.
h2. OpenShift, here I come
The OpenShift Application wizard imports the starter application to your workspace and creates a server adapter for it:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18891/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18878/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
You are then ready to publish your project. Simply drag and drop it to the OpenShift *server adapter* in the Servers view. Your project will then get published to OpenShift.
Once the publishing is done, you'll notice that the server adapter now has 2 modules: the starter application and your project:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18882/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
The server adapter actually compressed your project to a war and dropped it to the deployments folder within the starter application:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18883/d... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
It then committed this addition and pushed the starter application to OpenShift. The JBoss AS7 then noticed the new war and deployed it. Simple as that.
h1. But hey, my project does not work!
h2. Commit log
If your deployment fails JBoss Tools offers some goodies that allow you deeper insights into what's happening on the PaaS.
Pushing to the PaaS triggers a build and the deployment of your project. Both operations are logged and make it to the commit log. When the OpenShift server adapter finished publishing (git pushing), it'll show you the console with the commit log. This will show you in a first step if the push, the build and the deployment worked fine:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18896/a... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h2. Inspect your server logs
We also offer you simple access to your server logs. You'll find an appropriate entry in the context menu of your OpenShift server adapter. Simply pick "*OpenShift->Tail files*"
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18900/t... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-189...
It allows you to inspect the logs of your server within the Eclipse console:
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18901/t... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-189...
h2. Look into the jboss as7 management console
JBoss AS7 has a management console that's may be reached on port 9990. OpenShift only allows access to a limited set of ports from the outer world. Nevertheless OpenShift allows you to forward ports to your local machine. Using port-forwarding allows you to access the management console that's running on the JBoss A7 that is running on OpenShift.
Go to the OpenShift server adapter and pick "*OpenShift->Port Forwaring*".
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18897/p... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
The upcoming dialog will list you all ports that may be forwarded to your local machine. Simpley hit "*Start All*" and they'll get available at localhost on your machine.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18898/p... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
You may then access the management console of your JBoss AS7 in a browser on your local machine.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18899/m... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-188...
h1. Debug your application with the Eclipse Debugger
JBoss Tools even allows you to debug your OpenShift Application in the Eclipse debugger. You'll first have to enable debugging on your OpenShift application. You'll do this by adding a marker in the *.openshift* folder of your project. Create an empty file *enable_pda in* .openshift/markers. Commit it and tell the server adapter to publish your project.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18903/e... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-189...
Now that debugging is enabled, the debugging port of the remote JVM will get available and visible in your forwarded ports. Pick "*OpenShift -> Port Forwarding*" in the context menu of your server adapter and double check that the port *8787* is available. You'd eventually have to refresh the list of available port in case you already had it running before. Now *Start All* to get all ports (and the debugging port) forwarded to your local machine.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18904/e... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-189...
You're almost there. The last step is to tell Eclipse to connect it's debugger to your forwarded port. Go to the *Debug Configurations* in Eclipse and create a new configuration for a Remote Java Application. As soon as you hit Debug, the execution of your application on OpenShift will halt at the breakpoints you set in your Eclipse.
https://community.jboss.org/servlet/JiveServlet/showImage/38-4972-18905/e... https://community.jboss.org/servlet/JiveServlet/downloadImage/38-4972-189...
--------------------------------------------------------------
Comment by going to Community
[https://community.jboss.org/community/tools/blog/2012/06/27/deploy-from-e...]
12 years, 5 months