Missing build.xml when creating project with ClickStart? - build

I am using Eclipse EE version and CloudBees plugin to create a ClickStart JBoss 7 project. However, I am not very familiar with the EE version of Eclipse, and used Netbeans to edit my JSP.
Then I used CloudBees SDK to run and deploy my new project but it failed (the command prompt):
D:\Personel\Java EE\HelloCloudBees>bees run
ERROR: java.io.FileNotFoundException: D:\Personel\Java
EE\HelloCloudBees\build.xml (The system cannot find the file
specified)
I found no build.xml file in my folder. How can I create it?

bees run command expect an ant-based project structure, so the build.xml. As documented
CloudBees project commands are only available for applications
generated using the Bees wizard (on the web), built using the
CloudBees SDK style.
This is more or less some legacy stuff, as is now superseded by ClickStart. Equivalent command would be bees app:run but require your app to first be packaged as a WAR and only support the default tomcat6 runtime. So for your specific use-case would be simpler to package and deploy on a local JBoss 7 server. To deploy on RUN#Cloud, use bees app:deploy or just git push and let DEV#Cloud Jenkins build and deploy for you (assuming you created app with a clickstart).
Also, there's no need to use Eclipse if you're familiar with NetBeans.

Have you tried out maven?If yes you can download it and then use mvn eclipse:eclipse and then you can import your project in your workspace using eclipse import capabilities.File -> Import -> Maven -> Existing Maven Project...you point to the file where your pom.xml file is..and is imported. Take into accoutn m2eclipse plugin in eclipse must be installed prior.
regards
\n\m

Related

How to build a Windows Qt/MSBuild C++ application inside a Jenkins docker container

First of all, I'm completely new in CI.
I am trying to set up a Jenkins to build several C++ projects I am hosting on my own Gitea instance.
The applications I want to add to my Jenkins build pipeline are mostly Qt or MSBuild projects.
I have installed the MSBuild plugin for Jenkins, however I couldn't find a Qt plugin.
Since the Jenkins docker container runs inside a Linux environment and runs on Linux itself too, I couldn't find out how to make Jenkins build MSBuild (.sln) or qt (.pro) projects.
How do I have to configure Jenkins to make it build MSBuild or Qt repositories?
Do I have to create makefile or CMakeLists files?
My goal is to have automated release builds inside my repositories built using my Jenkins docker container running on my Linux machine.
I really couldn't find a useful tutorial or explanation on this.
Thanks a lot in advance.

WebPack on VSTS Hosted Build

We're using the hosted build agent on VSTS to build and release our ASP.NET Core code to Azure App service.
My question is: can we run WebPack to handle front-end tasks on this hosted build on VSTS or do we have to do it manually before checking the code into our repository?
Update:
I'm utilizing the new ASP.NET Core Build (Preview) template that's available on VSTS -- see below:
Here are the steps -- out of the box:
For VSTS we're working on an extension, currently it's in beta phase, you can ask for a share.
Check the VSTS marketplace.
Check this github repo.
Webpack is definitively not a first class citizen for VS2015 and VSTS. Streamlining webpack for CI/CD has been a real headache in my case, especially as webpack was introduced hastily to solve dreadful performance issues with a large monolithic SPA (ASP.NET 4.6, Kendo, 15,000 files, 2000 folders). To cut short, after trying many scenarios to make sure that freshly rebuilt bundles would end up in IIS and Azure webapp, I did a 2-pass build. The sequence of VSTS tasks is as follows: npm install global, npm install local, npm webpack install local, npm webpack install global, build pass 1, webpack, build pass 2, etc... This works with hosted and private agents, providing you supply the proper path for webpack as webpack is installed in a different location in host and in private (did not find a way to chose the webpack install location for consistency). I scorch everything before starting the build. Also need to do these in VS2015 solution : (1) unload "built" folder, and (2) Add Content Include="Built\StarStar" in project file. The "built" folder contains the bundles and should appear greyed, otherwise more bad surprises and instabilities to deal with...
Build-Pass #2 task in VSTS BUILD allows to collect the fresh bundles generated by Build-Pass #1 and includes them automatically in the package to be published.
Without a second build-pass, collecting the bundles and merging them in the zip package is a nightmare, especially when you have 15,000 files to unzip then rezip (300 ms per file!!). Did not find file-merging capability that I could readily use in VSTS.
I have my hears to the ground listening for someone coming up with a more efficient CI/CD scheme for webpack. In the meanwhile, my 2-pass-build workaround is working flawlessly, but slow indeed.
I anticipate that the advances with ASP.NET core, Angular 2 and webpack will look into solving this elegantly.

Can't load JSTL in multi module maven project with embedded jetty

I have created a test framework for testing .jsp files and .tag files using embedded jetty. I'm starting Jetty server programmatically using Java API, adding servlet holder and wrapper test JSP and initializing the server passing the project's web root.
There were some issues with Jasper discovering TLD locations during runtime when run from maven surefire plugin. I fixed it by providing
<useManifestOnlyJar>false</useManifestOnlyJar>
plugin classpath settings. Everything works good when I run tests using mvn clean install now.
Running tests from eclipse context menu has one issue. If there is any other project in workspace in the multi module maven build, TLD's in that project are not resolved. One workaround I tried was to 'close' the project in eclipse workspace and it worked out.
However I would want it to work with all the projects open in workspace and running from the eclipse JUnit context menu. The problem is in the jasper TldScanner that looks for tld files in jar and WEB-INF of current project only.
TldScanner.scanTlds()
processWebDotXml();
scanJars();
processTldsInFileSystem("/WEB-INF/");
I'm using org.glassfish.web.jsp-impl 2.2.2-b06 version with Jetty-8.1.0-RC5.
Is there a way to specify file based TLD scanning for jasper for extra classpath items?

Jetty runner is not executing the war file

I have a project named as test using spring,hibernate and struts.It is running when am using eclipse.But when i export this project as war and execute it using jetty runner in command prompt it just extracted the project and listed the contents in the browser.But i want the project to be executed.I have tried with some other simple web application war using the same procedure and it works fine.But in my project its not working with jetty.
here is my code for jetty
D:\>java -jar jetty-runner-7.0.0.v20091005.jar test.war
i just listing some console output of jetty
INFO::RUNNER
NO tx manager found
deploying file:D:/test.war #/[webAppContext#86f241#86f241/,null,file:D:/test.war
can any one tell me a solution for my problem
1) use a newer version of runner, 7.6.3.v20120416
2) what context are you trying to navigate to, you might want to experiment with some of the other cli options on the runner to set the context and whatnot from the command line and experiment with that. This site has some good information on using this artifact as well.

deploying scalatra onto Jetty

How does one deploy scala or scalatra onto Jetty servlet container? Does anyone have experience or can point me to some resources online?
If you're using sbt, run the package command from within the sbt shell. This will create you a war file in the target dir. You can drop that into jetty's webapps directory and configure a context xml file in its contexts directory.
If you're using maven, I believe the command you want is mvn package.
Are you using Simple Build Tool (SBT) for your project? If you do, it's as easy as running "sbt jetty"
Check it out: http://code.google.com/p/simple-build-tool/