How to extract Java Android sources and integrate in another project - java

We are developing a java based framework, running on Linux OS
that will provide an infrastructure for developed Applications (Java)
which is very similar to Android OS architecture.
Our framework consists of services and data providers running as different processes and providing
data to the applications running also in the system.
We want to use frameworks/base sources from the Android OS and use it in our framework
after some modifications, without building the entire Android OS.
Is this task possible to achieve in a reasonable amount of time?
If so, can you please point us where to start?
Thanks

If you want to modify a portion without needing to rebuild everything i think you could trying using AOP and compile time weaving, that is AspectJ in your case. Have a look here.

Related

Applet/JNLP on Java 11 migration

I have an application that runs under Java/JNLP applet and I would like to migrate to Java 11.
As you know the applets and JNLP will disappear from Java 11.
The goal is to keep my old code and remove the packages that contain the applets, is it possible to do this migration without switching to a new technology?
Finally, I chose Swing with Getdown which resembles JNLP.
A migration to a JEE/Spring solution would have completely modified the operation of my application and still take a lot of time. Tip: try it for yourself Getdown.
Yes and No.
Yes you can keep your java business logic and data handling code (presumed you did a clean separation of your application layers). E.g. just convert to a standalone java app and you're fine.
No, if you look for something to run in the webbrowser then you have to migrate to JavaScript/HTML/JSF/GWT... on the frontend and your java code running on the backend (JEE or Servlets ...).
Regarding the "No", it depends on what kind of application you have. A web application or a standalone application?
(1) For a web application you have to recreate the front end part (UI, communication with the server) but you can reuse parts of your logic.
(2) For a standalone application (using Swing/AWT/JavaFX ...) you can keep your code, just create a standalone app out of it. For distribution e.g. JavaFX offers an application packaging mechanism.
PS: The quickest way could be the conversion to the webstart technology however it was also deprecated and will be also be removed in future. So I would not use it.
One solution might be the WebStart replacement that Karakun is currently working on: https://dev.karakun.com/webstart/
Currently it is not clear when and how this will come since it is based on a kind of crowd-founding but since everyone can get involved (even with low cost) this is a very good possibility.

How to get overview of shared library dependencies

We have several hundred microservices running on many tomcat servers. Common for all these tomcat servers and microservices is the use of a common library containing shared business logic.
When we change logic in the shared library, we sometimes break some microservices, even though we ensure backwards-compatible changes. We lack overview of which service is using which shared class.
The question is not about regression testing, but more about give the developer overview of impact of changing shared logic.
What is the best way to get this overview ?
We are using Eclipse, Java 8, RTC (jazz.net), Tomcat, Windows, Cygwin, Ant.
We could use Eclipse reference search, however this requires us to check out all microservices into the workspace and then let Eclipse resolve all references (which will take 10+ minutes)
It would be a preference to have a tool within Eclipse to avoid using external tools to get this overview.
I am not sure if it has to be a real-time search or if we find it sufficient to use documentation generated by a job ran in scheduled intervals.
What would you suggest ?
PS My need is part of the static program analysis practice.

How to convert an Eclipse GAE Standard Environment Application to Flexible Environment?

I'm making my GAE app using Eclipse. All the plugins, and other functionalities involved support development for the Standard Environment. Is there a way to convert my current project to the Flexible Environment? Barring that, once uploaded to GAE, can this change be done online?
The Flexible environment is an almost entirely different beast than the Standard environment.
Support for various pieces of infra differs. You need to check each piece of infra you use in the Migrating Services from the Standard Environment to the Flexible Environment guide for an equivalent, if there is one. Effectively you'd be re-writing the app.
Note the service in above article title - the environment choice is done at the app service/module level, one can mix services with both environments inside the same app.
And no - the change can not be done online, you need to explicitly deploy the re-written app service to switch its environment.

Android application development: java vs. jquery mobile

I'd like to build an android application for a school project but I'm a bit confused, I saw that i can build an application using Java or using Jquery mobile.
Do they have the same capabilities?
If i build an application using Jquery , can i pack it and have it installed like a java application (as apk) or is it only used for building websites?
If so, what tool do i use to pack it?
jQuery Mobile needs an intermediary framework that communicates between JavaScript and Java. PhoneGap is a popular one of these frameworks.
PhoneGap is also actively maintained and they roll out new versions almost every month.
The main reason to use PhoneGap/jQuery Mobile is that it makes development easy if you already know HTML/JS/CSS. Another great reason to use PhoneGap is that you can use your existing website as the base for native applications, yeah, plural, not just Android but also iOS, Blackberry, etc. It also gives you a pre-built UI with some widgets so you don't have to roll your own.
The jQuery Mobile documentation talks about some of the caveats to creating a native application with PhoneGap and jQuery Mobile.
I don't know what you have already tried or what your skill set is (based on your stackoverflow history you may know more about java than I do), but you would be best off just using the Android SDK. I was able to design and complete a custom business project and learn java while doing it. I can't comment much on jQuery since I've never used it. jQuery seems like it might be a nice for the reasons Jasper listed but might add layers of complexity you don't need to deal with if you don't need to run your app on other platforms.
Jquery Mobile Framework provides the way how you web application looks on different hand held devices simply but this can not use the native device capabilities like picking up an contact from the contact book/application. while native application has the capabilities to handle all the system generated events or broadcasts.

How to make a browser based IDE to code in the cloud?

I have read a bit about cloud and browser based IDE's.
I am planning to make a Java based bare bones IDE by integrating a compiler to code in the cloud. This is for educational purpose as I am just determined to learn to develop cloud based IDE.
I want it to be something like eclipse Orion but i want it to allow for coding in java. It should allow users to code, compile and run java programs by directly writing .java files and not by converting the .js files into java files.
Can someone please suggest me an existing cloud that I should use for this. And also, I am just a beginner and I have no clue about how to proceed and the articles that I am required to read.
Please do let me know what I should begin with and the cloud that suits my needs the best.
Thank you very much in advance.
You should look at projects like Mozilla SkyWriter, which implement the bare bones editing functionality
(There have been a lot of change lately. There seems to have been migrated to Ace)
You can use Codenvy and put your code on a Git repository. Then, you could build automatically once you have done the push using a CI tool like Jenkins. Now, I have an environment in which I use a Jenkins instance as a Service and also a runtime environment so I can get a continuous deployment pipeline. This video will show you, in a graphical way, what I am talking about.
Koding provides you with a full Ubuntu machine, with root, so it's able to run and do what you want, programming wise.
The reason i'm suggesting Koding though, is that they have a Framework to develop your IDE for the Koding VMs themselves.
The logic here, is that making IDEs is challenging, but the biggest challenges is ensuring security between your IDE users. Using another VM platform would mean that you don't have to manage the security of your VM, and focus entirely on your IDE.
Let me know what you think :)
For virtual/cloud hosting try one of the following:
Rackspace
VPS Farm
I like vpsfarm because it is cheap and pretty bare bones.
For the IDE itself, I would first create a webapp that can upload and compile and run arbitrary java code, without adding libraries or J2EE. That alone will be a good undertaking for one dev.

Categories