Quantcast
Channel: JetBrains Developer Community : Thread List - IntelliJ IDEA Users
Viewing all 5661 articles
Browse latest View live

BUG - Evaluate Expression Won't Auto Fill

$
0
0

IJ Ultimate 14.0.3

 

In debug mode with the Debug window floating, if I highlight some code for evaluation and click "Evaluate", the expression field won't auto fill with my highlighted code fragment. If I dock the Debug window, it works again.

 

This normally isn't a big deal but now that I have two monitors, I have undocked most of my windows and that bug is becoming an annoyance.


IBM Curam in Intellij

$
0
0

Hi all

 

I'm currently working on a project where we customize Curam, an IBM package.  That piece of software has a lot of folders and a massive amount of files that are imported in the IDE.  (By massive I mean 300k+).  These files are contained in quite an impressive list of folders, of which I included most.  I only included a handful, to make sure that indexing the whole bunch doesn't crash my Intellij every time I do a new build.   These are not modules that are deployed on a Tomcat or so.  The client files are generated by an Ant script and Tomcat is configured locally, so it points to the folder where the generated files are being kept.  So basically, I configured Tomcat as an External Tool and I run that, instead of deploying a Module to it.

 

The project was generated based on .classpath files from Eclipse.  Now, long story short, performance is ridiculously slow.  I have an SSD with 8 GB of Ram and it takes me _ages_ to run the application.  Going 3 steps further sometimes takes me more than 20-25 minutes, which is unacceptable.  I already checked memory usage, but it's about 1 GB of RAM, which is not that much imo.  CPU usage is rather low.

 

For example, I'm running the application now and Memory Usage is about +- 5 GB, of which Intellij takes 1GB and Java 900MB. 

 

Is there a way of tweaking memory usage?  I modified idea.exe.vmoptions to these settings:

 

-server

-Xms1024m

-Xmx2048m

-XX:MaxPermSize=1024m

-XX:ReservedCodeCacheSize=900m

-ea

-Dsun.io.useCanonCaches=false

-Djava.net.preferIPv4Stack=true

-Djsse.enableSNIExtension=false

-XX:+UseConcMarkSweepGC

-XX:SoftRefLRUPolicyMSPerMB=50

 

Unfortunately, that didn't do much.  I also disabled a couple of plugins, but now my Intellij doesn't start anymore :rolleyes. 

 

Any ideas what else I can tweak or what I can do to improve memory usage?  What's also pretty annoying, this is a company laptop, so we have that magnificent piece of software, called Sophos, installed, to make sure everything is secure (and incredibly slow).

Migrating an Eclipse AspectJ project

$
0
0

Hi *,

 

at my company, we are currently working with Eclipse for our Java projects.

As me and some other coworkers would rather use IntelliJ, we took a crack at migrating our projects and failed at getting AspectJ to work.

 

Here are the steps we took:

 

  1. import the project and dependencies into IntelliJ
  2. download and install AspectJ
  3. Under Settings -> Java Compiler: Use ajc compiler, delegate to javac (path to aspectjtools.jar is correct as the test button indicates)
  4. Add AspectJ libs to Global Libraries (aspectjrt.jar, aspectjtools.jar, aspectjweaver.jar, and org.aspectj.matcher.jar)
  5. Create AspectJ facet for the one module that is using AspectJ, leave all settings as is (no aspect path defined)
  6. Add aspectjrt to project libraries
  7. rebuild, make etc.

 

On make I get the following errors:

Error:(38, 0) ajc: The type LoggingDirectory must implement the inherited abstract method LogContext.isDebugEnabled()

 

LogContext is just an empty interface. Classes that want a logger appended implement this interface.

 

This method is injected with AspectJ. Unfortunately I am not an expert with this and guy who implemented it already left, so I am stuck.

 

In order to check general functionality, we implemented a tiny project from scratch with just three classes with the same settings as above:

 

publicinterface LogContext {}   

 

public aspect LogContextAspect {    publicvoid LogContext.log() {        System.out.println("Log!");    } } 

 

publicclass Aspect implements LogContext {     publicstaticvoid main(String[] args) {        Aspect aspect = new Aspect();        aspect.log();    } } 

 

The code actually executes fine and prints out the "Log!" message, but on make I get the following error:

Error:(4, 0) ajc: The type Aspect must implement the inherited abstract method LogContext.log()

 

What are we missing here? In order to migrate our projects, we need AspectJ to work.

The whole system is built with Java 6 compatibility but runs on Java 7.

 

Thanks for your help!

 

- Sascha

How to use jars from jboss jboss-deployment-structure.xml?

$
0
0

Hi,

I need to use in IDEA 14 some modules taken from JBOSS

jboss-deployment-structure.xml file.
In development phase we need to use those same libraries defined in jboss-eap6.3 configuration.

Is there a way to reach this goal?
Some suggestions, please?

Thank you in advance,

Best regards,
Nicola

How to hide all tool windows with shortcut key

$
0
0

The default key I think is CTRL+SHIFT+F12.

 

I have also tried to remap to other key combinations that are working for other actions.

 

I am using the latest EAP 14.0.x on Linux Mint 17.

 

The action works while using the mouse.

 

How do I bring this action back? thanks

How do i get IntelliJ to recognise Angular directives

$
0
0

Hi, I'm using IntelliJ IDEA 14.0.3.

 

I want the IDE to recognise angular directives in my HTML files, with click through. Is this possible?

 

I have a project with a web module and a java application module. The directives are in the web module.

 

Regards,

Gilbert

WebLogic server not found

$
0
0

I am running idea-IU-139.224.1 (14) and WebLogic 12.1.3.0.0.

 

I have local install of WLS that works from the command line, and a remote install at slc08uyu that runs fine and is accessible on my network.

 

When I try to run a remote session (or try to test the connection) I get this error.

 

Error running slc08uyu: Unable to connect to the slc08uyu:7003, reason: Server not found

 

Thanks for the help,

Glenn

Intellij run config set input file

$
0
0

Is there anyway to set up an IntelliJ run config for a Java program, so that it runs as if I ran this in terminal:

java Uguu< file

How would I tell IntelliJ to put the < file part?


Intellij 14 factory default 'code style' always imposed.

$
0
0


I'm running Intellij 14.0.3 (unix 64).  Every time I open an existing
project (Java) the factory default 'code style' is applied to every file
open in the edit window even though I have set my preferences for project using the
settings wizard.  Also my preferences are not set if I select a region in
a file and click 'Code | Reformate code ..."  however if I reformat
the whole file the rules are applied.  Also if I set the "start comment
designator '/**'" in front of code my format preferences are applied automatically.

 

How to resolve this behavior?

 

Steps to reproduce

 

1.) To a java file in an existing project add stmt,
   public HasValue<String> getFirstName() { return firstName; }

 

2.) set preference to the "Project"
     Editor | Code Style | Wrapping and Brackes | 'if()' statement | force braces "always"
     click Apply and then OK.

 

3.) Select the stmt in step 1 and try to reformat ..
      click  'Code | Reformate code ..."
      (no change)

 

4.) Now above the stmt type the "start comment designator '/**'"
      (code is reformated)
      save this change

 

5.) Exit the Intellij window for this project and then reopen this project.
    The stmt will look like stmt in step 1.  The preferred formatting is lost.

Having a good time configuring servers to run Java EE

$
0
0

I've been working some days to make Intellij work with my Tomcat.

 

First I've tried to run an aplication made in Eclipse, it did'nt even load properly. Then I tried to create a new project and copy file by file, but the configuration files seems to be wrong or something, I can start the Tomcat server within the IDE, but can't preview or see it at all.

 

The preview get me to the wrong place, but configuring web.xml it won't find the file, even with absolute path on the browser.

 

I'm new to this plataform, can someone help me?

how do I format code? indent? align curly braces?

$
0
0

Pardon, I googled but just couldn't figure out how to format Java code.  In Netbeans, it's right click, refactor, format and there's a shortcut key.  How do I just fix indents, simple things like that, please?

C++ autocompletion issue

$
0
0

For the past year I have been using pycharm as my python writing IDE and I love it.

 

I wanted to start learning C++ to add to my programming languages and I thought I would stick with the intellij platform. But of course pycharm doesn't support C++. I figured I could do away with having multiple IDEs by using idea instead, and using the python and C++ plugins, seeing that CLion is in its infancy.

 

Idea and the python plugin works well.

 

I can not for the life of me get C++ running properly. I can get a project going and get the script to compile and the standard hello world output.

 

HOWEVER, there is no autocomplete options and the software doesn't seem to make suggetions or give me any errors during inspection regardless of what I type (e.g. kkjhagkjha).

 

I am running mac OSX yosemite.

 

 

What I have done:

Installed xcode and updated the settings for the standard gcc links. --> compiling the generic hellow world works

 

Installed via macports the gdb-apple and certified it, and updated the links in the preference.

http://ntraft.com/installing-gdb-on-os-x-mavericks/

--> if I run the debug option it doesn't give any errors.

 

 

Perhaps I have it wrong and the gdb and gcc has nothing to do with autocompletion. Then what am I doing wrong? Also the C/C++ plugin is installed. I had initially thought this would provide me with auto completion and suggetions, but it didn't which is why I went throught and installed what I mentioned above.

 

I would appretiate any help I can get, since I do not look forward to the more complicated xcode direction. And Clion works a little buggy for now for my taste. I would like to get the environment set up so I can continue learning.

groovy grape GrabAnnotationTransformation case sensitivity causing bogus global transform warning

$
0
0

does this bug:

 

Information:09/03/15 3:56 AM - Compilation completed successfully with 1 warning in 58 sec
Warning:Groovyc: The global transform for class groovy.grape.GrabAnnotationTransformation is defined in both jar:file:/home/thufir/.gvm/groovy/current/lib/groovy-2.4.1.jar!/META-INF/services/org.codehaus.groovy.transform.ASTTransformation and jar:file:/home/thufir/.groovy/grapes/org.codehaus.groovy/groovy/jars/groovy-1.6-RC-3.jar!/META-INF/services/org.codehaus.groovy.transform.ASTTransformation - the former definition will be used and the latter ignored.

 

 

https://jira.codehaus.org/browse/GROOVY-3497

 

 

effect everyone?

 

Or, is it possible that I don't have my environment configured correctly?

Multiple-display workflow

$
0
0

As I love IDEA and generally working on multiple monitors, they don't seem to like each other. I was searching for solutions for this problem and the only thing that I can find is floating mode. But let's be honest - floating mode sucks on multiple displays. Simply because of lack of any form of edge snapping. I can't precisely position my panels and I have to re-size them to take advantage of additional space.

 

I'd love to have separate panels that acts as native (MS Windows) system window, which snaps to display sides. Also it'd great to have simply floating tool window (tool group) with Eclipse-style docking / splitting layout.

 

I want to know if it is possible in current version of IDEA and if it's not (which is very likely), where can I submit feature request or something similar? Do JetBrains developers read any suggestions?

hibernate.dialect must be set when no Connection available?

$
0
0

I'm trying to use the HQL console and keep getting: "hibernate.dialect must be set when no Connection available" from all queries.

 

How do I set the hibernate.dialect for the configured datasources? We normally configure this in an external properties file, the hibernate.cfg.xml file does not hold these values as we use different DB vendors in dev, test and prod. So when I'm looking at a particular dataSource how to I map this dialect value and where?

 

The persistence tool menus only appears to let me configure naming strategies and datasources. The datasource has not dialect - but this would be the wrong level. The hibernate facet also appears not to have any dialect mappings (which would change with datasource anyway) ? what am I missing?

 

I'm also wondering why I need to set it when the datasource knows what the DB vendor is, and via that the version. Hibernate should be able to make a pretty good guess at the dialect (is this not automatic?) - what is making us define it?


How to add a stylesheet to IntelliJ?

$
0
0

Hi, I'm new in IntelliJ and I'm trying to add a simple css file to my web project, but it's not detected nor rendered.

 

What can I do to solve it?

Grails inplace plugin that references another plugin

$
0
0

Is there a way to configure IntelliJ to recognize references between inplace plugins? For example:

 

     Main App references MyPlugin1 which references MyPlugin2

 

When I use "grails run-app" everything works fine, however, IntelliJ cannot see the link between the inplace plugins and highlights the reference to MyPlugin2 from MyPlugin1 as an error.

 

Am I doing this right? Is there another way to link inplace plugins?

 

I've created a sample application on GitHub:

 

https://github.com/mikedehaan/inplaceDepend

 

This is using Grails 2.4.4 and Intellij14 with JDK 1.8.

How to configure the maximum views of "Back/Forward" in navigate menu in IDEA?

$
0
0

  The Back/Forward commands are real very useful, but it seems that the maximum views I can go back or forward is 20. This maximum is not enough for me, and I can not find where to configure this value.

  Could anyone help me? Thanks for your attention.

Maven archetype repository

$
0
0

When you create a new Maven project it will show a list of archetypes.

Is there a way to configure the repository where this list is retrieved from?

I want to set the archetype catalog.

Problems creating artifact(jar) resources not included in jar.

$
0
0

I'm trying to build an artifact using gradle and I am receiving an error "MANIFEST.MF already exists in VFS"  Also, when I can build the jar, it does not include the spring resources directory. It is related to "IDEA-132963No spring resources after building artifact in IDEA 14"  and it was said it would be resolved in IDEA 14.1.  Do you have any clue, workaround to build executable jars, please?

 

INFO: Loading XML bean definitions from class path resource [spring/config/context.xml]

Exception in thread "main" org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [spring/config/context.xml]; nested exception is java.io.FileNotFoundException: class path resource [spring/config/context.xml] cannot be opened because it does not exist

        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:344)

        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:304)

        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:180)

        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:216)

        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:187)

        at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:251)

        at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:127)

        at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:93)

        at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:129)

        at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:540)

        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:454)

        at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:139)

        at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:93)

        at edu.neu.AppAthletic.main(AppAthletic.java:22)

Caused by: java.io.FileNotFoundException: class path resource [spring/config/context.xml] cannot be opened because it does not exist

        at org.springframework.core.io.ClassPathResource.getInputStream(ClassPathResource.java:172)

        at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:330)

        ... 13 more

Viewing all 5661 articles
Browse latest View live


Latest Images