Migrating from jdeveloper to Intellij
So hello everybody, I'm a junior programmer and I'm at the brink of taking my tiny brain out of my cranium putting it on a table and smashing it with my forhead. Now that we have established the level of my pure despiration allow me to riddle you with a question.
How do I move a project from Jdeveloper 12c to IntelliJ and make it work?
Or rather how can i deploy a javaEE application in intelliJ? Using Oracle WeblogicServer on jdk 8. Now the hard part is, I am a newbie and i know squat about for example how to create an artifact with aplication description, how to generate a web.xlm (even tho i have a functioning web.xml that Jdeveloper uses just fine but it is not viable in IntelliJ for some reason) i basicaly cannot understand how to create a deployable web app. (just a small notice: i've spent over 3 month with this problem and most of what i read on the internet either is not usefull or spiraled down to 30 links one following another deeper into the underbelly of the compiler that i'am either to stoopit to understand or it'll take me 14 hours to learn and i cannot afford the workhours i'm trying to migrate between tasks... So i intentionaly ask for a professional help)
Ok What have i done:
- I've succesfully created a local WLS domain that is now connected to IntelliJ RUN.
- I have exported code from Jdeveloper, so I can technicaly work with it as is and use Jdeveloper to run the thing.
TWIST:
I am not allowed to even screencapture a singe segment of code legaly, nor to show a structure of a project because... well strict non disclosure politics. I'am in dire need of help. and I ask you good people to help me to basically beat an 8'th-grader cause thats how old is the techstack. PLEASE SEND HELP, CONTACT ME HERE... or via Email hamatamna_479@mail.ru there are so many questions it;d take an entire a1 sheet to fit them all into one thing
Please sign in to leave a comment.
Hi. Sorry to hear that you're struggling. Hopefully, I will be able to help.
Going to need additional info from you:
Have you checked the official help articles on how to setup web projects and configure artifacts?
If you have, what are the obstacles that you've bumped into? Were there any particular errors or unexpected kinds of behavior?
Okay so that i actually can answer. There are no external libraries that are not included with jdeveloper, however not all of them are used, i 've narrowed it down to 4 being: wbelogic.server.merged ; monfox.dnsmp; sun.xml.ws.jaxws and oracle.css.common.security.utils. For the Frameworks we use apache stripes for an MVC intappolation and that is IT other than that it's more or less vanilla java with no addons. However i should specify that for the build of an app we do not use neither maven, ant or gradle (since they were not invented at the time...) and THAT is the part that actually makes it hard, there is no info for whatever the method of building the standart JDeveloper has... And most of the things that are there use maven or gradle even ant and suddenly it's completely useless to my case... more on that... weirdly enough certain modules of the project seem to implement both pom.xml with maven element descriptions (that are by the way only use the very same libraries that are in the libraries)... and Ant descriptors that include an ant specific elements! Weither or not jdeveloper uses them in the most convoluted way to prebuild specific parts of the application is not even traceble it may be maven build or anyting else included into a JPR. DO YOU SEE THIS? This is psychotic, like what can i even think to start with this time. I may be a junior but it's not an incompetence problem, it's just that i have to work with an ages old tech that pre-dates wide community support and nothing that is on the web is comprehensible at all. It requires you to be a pro already to get it so for a newbie it inpenetrable.
Oh yeah i've read and tried all of those. They were like first once i've tried actually
And more on that. I CANNOT use jakarta EE since rpoduction server cannot be transfered to it since more than one app runs on it meaning it could cause errors that are to long and to expensive to fix in process
OK... I can see that it is a painful endeavor that you are undertaking. So sorry about that.
Why don't you try to break the task down into smaller ones? Like, strip a copy of the project down to bare essentials - maybe even less than that, e.g. only the Ant part - and see if you can build that one part of the project using contemporary methods provided by the IDE. If problems arise, they can be addressed one by one with our help until there are no more.
Then forget about the Ant part, get rid of all of the extra dependencies and switch your attention to Maven. Try to get the pom.xml to the bare minimum for the project to be building without errors, and then add dependencies and other fancy stuff to it gradually. I'm fairly certain the pain will intensify at this point since the project is old, but we can tackle it one error at a time too - if you post the error messages here that is.
Then you can combine the two and get new errors, tada! But at least you would know what you'd done right so far.
Otherwise, without having something substantial to grab onto, I don't think I would be able to help you efficiently. Your guesses would be as good as mine.
Hey, senior (15+ years) of experience in this stack.
1. What is the app framework, Struts 1/2 or Spring? Did they make their own framework?
2. You prob have very old session beans and ejb's in the project. Normally I would recode depending on how many objects there are. If you don't have the resources or the time, and they are working, they should continue to work without any issues. You don't need any of the intelli J plugins either, weblogic will handle them.
3. Don't worry about the libs right now.
4. Educate yourself on the weblogic console. It's not hard, you already created the datasource. The console will help you later with dependencies.
5. Remember that weblogic is from oracle and well... they like to include libs in their projects that can cause conflicts. You can tell weblogic not to use any included libs in weblogic.xml
My methodology to handle this:
1. Start a new web project in intelli J so the structure is correct.
2. Move the web stuff over first, get web.xml, struts/spring config stuff, resources, etc all setup correctly. The new project should create a resources folder/web content (ccs/js/etc).
3. Once the web module is moved over and the project runs with a simple Java file and html file (Basically get the hello web app working with your datasource).
4. Install the Mavin/Gradle plugins for Intelli J,
5. If you're using GIT do the same and install the plugins
6. This is the hard part, you'll need to identify each lib in the project and pull the correct ones from Gradle/Maven. You're going to have lib conflicts depending on the size of the project.
7. Move over the Java code. Do not bring over the hard set libs, use the maven repo.
8. Because the prj is old and prob has tons of outdated CVE laden libs, your going to have to use weblogic console to find conflicts and get the libs to all work together. This can really be a huge pain depending on how old the libs are. Most of the very old ones you won't even find in Maven and will have to track down the new lib the devs are using. Then you're going to have conflicts between libs.
Libs that conflict: I would look to see what the lib was being used for, then re-write the code with the latest lib and most modern design.
Depending on the size of the project this will take awhile. You can modularize the java and take a bit at a time, that may be a decent approach.
To create artifacts, etc in weblogic is pretty simple. CTRL+SHFT+ALT+S will open the project settings where you can define and modify these. You also configure the debug and run modules here.
Best of luck.
Eric