932
I Use This!
Activity Not Available

News

Analyzed 4 months ago. based on code collected over 4 years ago.
Posted over 9 years ago
WLS 12c supports some Java EE 7 API like: JSON Processing (JSR 353), JAX-RS 2.0, JPA 2.1 http://docs.oracle.com/middleware/1213/wls/NOTES/index.html. Now it is time for a Smoke Test: Download size is reasonable: 198,7 MB for a generic ZIP. ... [More] However: the download requires a login to OTN. This is an unnecessary barrier for developers. Installation is easy: setting a MW_HOME variable pointing to the extraction folder and executing the configure.sh NetBeans 8 integration worked out-of-the-box. Application was directly deployed from NetBeans with Maven 3. WLS is nicely integrated with NetBeans: you can start, stop and deploy your application directly from NetBeans. Also a useful feature: WLS and GlassFish are using different ports--you can run both servers at the same time. wls12c was installed on Java 8 (1.8.0-b132 / mac) without any problems Java EE 6 tests were passed Interestingly: a basic JAX-RS service with JsonObject works perfectly on GlassFish v4, but fails on WLS 12.1.3: @Stateless @Path("alert") public class AlertResource { @Inject FireState fireState; @GET public JsonObject get() { return Json.createObjectBuilder(). add("Smoke?:", fireState.isSmoke()). build(); } } <Error> <com.sun.jersey.spi.container.ContainerResponse> <BEA-000000> <Mapped exception to response: 500 (Internal Server Error) javax.ws.rs.WebApplicationException: com.sun.jersey.api.MessageException: A message body writer for Java class org.glassfish.json.JsonObjectBuilderImpl$JsonObjectImpl, and Java type interface javax.json.JsonObject, and MIME media type application/octet-stream was not found. Seems like the "Accept" header is ignored. The request was initiated by: curl -H "Accept: application/json" http://localhost:7001/server-smoke/resources/alert and browser link. See you at Java EE Workshops at MUC Airport or on demand and in a location very near you: airhacks.io! Real World Java EE Workshops [Airport Munich]> [Less]
Posted over 9 years ago
Ken Fogel is the Program Coordinator and Chairperson of the Computer Science Technology program at Dawson College in Montreal, Canada. He is also a Program Consultant to and part-time instructor in the Computer Institute of Concordia University's ... [More] School of Extended Learning. Preview Text:  Regular NetBeans education columnist Ken Fogel, the Program... [Less]
Posted over 9 years ago
Jaroslav Tulach has now integrated several references to NetBeans Platform for Beginners into the NetBeans javadoc: He's also written some very nice things about it here in his API Design blog, a version of which is part of Update 5 of NetBeans Platform for Beginners.
Posted over 9 years ago
In NetBeans IDE 8.0, you're able to debug JavaScript unit tests via JS Test Driver. In the upcoming NetBeans IDE 8.0.1, JavaScript unit test debugging has been extended to include Karma, as well. Right-click an HTML5 project and, when you select ... [More] Karma in the JavaScript Testing tab, you can enable debugging, as shown below. (The new Karma Istanbul code coverage integration was discussed in this blog yesterday.)  As you can see below, the drop-down lets you choose on which device you want to debug your unit tests: Then, on the Karma node of your project, enable debugging and start Karma: Then you can follow the steps in "Debugging a JS Unit Test with JS Test Driver" in the NetBeans tutorial Debugging and Testing JavaScript in an HTML5 Application, with the result shown below, click to enlarge the image. [Less]
Posted over 9 years ago
Make sure you didn't miss anything with this list of the Best of the Week in the Enterprise Integration Zone (July 18 to July 25). Here they are, in order of popularity: Preview Text:  Make sure you didn't ... [More] miss anything with this list of the Best of the Week in the Enterprise Integration Zone (July 18 to July 25). This week's topics... [Less]
Posted over 9 years ago
Woodstock Dataprovider Entity ExampleHere is another example of using Project Woodstock along with JPA in an Enterprise Application. The project requires the sample database included in NetBeans.The project was updated using NetBeans 6.5.1.The code for the project can be found on Bitbucket here: WoodstockJPAApplication
Posted over 9 years ago
Nice job—all your tests are passing. However, it's pretty useful to at least know the percentage of code that's under test. No one's saying that all your code should be under test, just that it's hard to argue against being able to be aware that your ... [More] 100% test pass rate applies to 20% of your code. In the JavaScript world, a popular solution in this area is Karma Coverage, which is based on Istanbul, and for which the upcoming NetBeans IDE 8.0.1 has handy integration: Look at the above screenshot—with one glance you can see the statement in my code that has not been tested. To get to the above screenshot, I read this article and then checked out this code on GitHub, and then simply opened it in NetBeans IDE, and clicked the menu items that you see above that appear magically on the project when opened into NetBeans IDE, while this is also handy. Here's the test spec for the above JavaScript file, notice that one test method is commented out. If it were not commented out, the above code coverage would pass 100%. describe("sqrt", function() {//  it("should compute the square root of 4 as 2", function() {//    expect(My.sqrt(4)).toEqual(2);//  });  it("should throw an exception if given a negative number", function() {    expect(function(){ My.sqrt(-1); }).toThrow(new Error("sqrt can't work on negative number"));  });}); For a fullblown NetBeans IDE tutorial on debugging and testing HTML5/JavaScript applications, see this document, though note that it doesn't include code coverage yet, since that's not in the current release of NetBeans IDE: https://netbeans.org/kb/docs/webclient/html5-js-support.html [Less]
Posted over 9 years ago
Grunt tasks are to JavaScript what Ant targets and Maven goals are to Java. You can "grunt" on the command line, but also directly in NetBeans IDE. Here I'd like to take a look at where the feature set in NetBeans IDE is going with Grunt. ... [More] Let's say we've got hold of the AngularJS Seed template. Doing this is simple in NetBeans IDE via the New HTML5 Project wizard, which gives you an option to let NetBeans IDE download the AngularJS Seed template as the basis of the new application. Once you have your application, hop over to the New File dialog and create your Grunt file: Next, here's a handy Grunt definition that creates three tasks, for copying to a 'build' directory, for cleaning that directory, and for combining the two tasks, thanks to this article: module.exports = function (grunt) {    grunt.initConfig({        pkg: grunt.file.readJSON('package.json'),        copy:{            build:{                cwd:'app',                src:['**'],                dest:'build',                expand:true            }        },        clean:{            build:{                src:'build'            }        }    });    grunt.loadNpmTasks('grunt-contrib-copy');    grunt.loadNpmTasks('grunt-contrib-clean');    grunt.registerTask(        'build',        'Compiles all the assets and copies the files to the build directory.',        [ 'clean', 'copy' ]    );}; Copy the above into your Grunt file. The above means that in the 'package.json' file that is already part of the AngularJS Seed template, you need to add two new dependencies, shown in bold below: "devDependencies": {"karma": "~0.10","protractor": "~0.20.1","http-server": "^0.6.1","bower": "^1.3.1","shelljs": "^0.2.6","karma-junit-reporter": "^0.2.2","grunt-contrib-copy":"0.4.x","grunt-contrib-clean":"0.4.x"}, Then right-click on the project and choose "Npm install", which is new in the upcoming NetBeans IDE 8.0.1, though the development builds are already available: Then, also new in NetBeans IDE 8.0.1, right-click on the project and notice that you have access to the tasks via the new "Grunt Tasks" menu item: Also, again new in NetBeans IDE 8.0.1, you can map your Grunt tasks to project commands: Now, when you right-click your project and choose "Build", "Clean", and "Clean and Build", you automatically delegate the handling of the action to the underlying Grunt task. The icing on the cake is that the project commands "Build", "Clean", and "Clean and Build" can be mapped to keyboard shortcuts. For example, map "Build" to a keyboard shortcut and then, when it is pressed, the related Grunt task of the currently active project will be invoked. Grunt could almost not be integrated more snugly into NetBeans IDE. Maybe an enhancement could be to provide some predefined templates as examples of what can be done with Grunt, to really get you up and running quickly. Related reading: http://java.dzone.com/articles/using-grunt-angularjs-front http://24ways.org/2013/grunt-is-not-weird-and-hard http://www.sitepoint.com/writing-awesome-build-script-grunt http://chrislarson.me/blog/angularjs-yeoman-grunt-and-bower [Less]
Posted over 9 years ago
Multiple Selection TableThis is another example of a Project Woodstock project that was converted from Project Rave and Sun Studio Creator 2. This example details a multiple selection table, and was originally created by Winston Prakash.I have ... [More] updated the project using NetBeans 6.5.1 and tested on GlassFish 2.1.1.The updated project can be found on BitBucket here: MultipleSelectionTable [Less]
Posted over 9 years ago
Single Selection TableHere is another example Project Rave/Woodstock project originally written by Winston Prakash for Sun Studio Creator 2. It has been updated using NetBeans 6.5.1 and tested on Glassfish 2.1.1.The project can be found on BitBucket here: SingleSelectionTable