[JBoss JIRA] (FORGE-539) Connection refused: **ERROR** [forge install-plugin] Connection to ... behind a proxy
by Esteve Aviles (JIRA)
Esteve Aviles created FORGE-539:
-----------------------------------
Summary: Connection refused: **ERROR** [forge install-plugin] Connection to ... behind a proxy
Key: FORGE-539
URL: https://issues.jboss.org/browse/FORGE-539
Project: Forge
Issue Type: Bug
Components: Shell
Affects Versions: 1.0.2.Final
Environment: windows7 forge 1.0.2
Reporter: Esteve Aviles
Priority: Minor
Hi,
I am getting this error when using forge behind a proxy. I tried FORGE-421 Proxy support, but with no success.
[seam3-test] seam3-test $ forge install-plugin arquillian
Connecting to remote repository [https://raw.github.com/forge/plugin-repository/master/repository.yaml]... ***ERROR*** [forge install-plugin] Connection to https://raw.github.com refused
org.jboss.forge.shell.exceptions.CommandExecutionException: Connection to https://raw.github.com refused
at org.jboss.forge.shell.command.Execution.perform(Execution.java:153)
at org.jboss.forge.shell.command.fshparser.FSHRuntime.run(FSHRuntime.java:125)
at org.jboss.forge.shell.command.fshparser.FSHRuntime.run(FSHRuntime.java:63)
at org.jboss.forge.shell.ShellImpl$ExecutorThread.run(ShellImpl.java:829)
at org.jboss.forge.shell.ShellImpl.execute(ShellImpl.java:852)
at org.jboss.forge.shell.ShellImpl.doShell(ShellImpl.java:642)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.jboss.weld.bean.proxy.AbstractBeanInstance.invoke(AbstractBeanInstance.java:48)
at org.jboss.weld.bean.proxy.ProxyMethodHandler.invoke(ProxyMethodHandler.java:125)
at org.jboss.forge.shell.ShellImpl$Proxy$_$$_WeldClientProxy.doShell(ShellImpl$Proxy$_$$_WeldClientProxy.java)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.jboss.weld.util.reflection.SecureReflections$13.work(SecureReflections.java:305)
at org.jboss.weld.util.reflection.SecureReflectionAccess.run(SecureReflectionAccess.java:54)
at org.jboss.weld.util.reflection.SecureReflectionAccess.runAsInvocation(SecureReflectionAccess.java:163)
at org.jboss.weld.util.reflection.SecureReflections.invoke(SecureReflections.java:299)
at org.jboss.weld.introspector.jlr.WeldMethodImpl.invokeOnInstance(WeldMethodImpl.java:188)
at org.jboss.weld.introspector.ForwardingWeldMethod.invokeOnInstance(ForwardingWeldMethod.java:59)
at org.jboss.weld.injection.MethodInjectionPoint.invokeOnInstanceWithSpecialValue(MethodInjectionPoint.java:198)
at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:282)
at org.jboss.weld.event.ObserverMethodImpl.sendEvent(ObserverMethodImpl.java:265)
at org.jboss.weld.event.ObserverMethodImpl.notify(ObserverMethodImpl.java:234)
at org.jboss.weld.manager.BeanManagerImpl.notifyObservers(BeanManagerImpl.java:635)
at org.jboss.weld.manager.BeanManagerImpl.fireEvent(BeanManagerImpl.java:622)
at org.jboss.weld.manager.BeanManagerImpl.fireEvent(BeanManagerImpl.java:616)
at org.jboss.forge.shell.Bootstrap$1.run(Bootstrap.java:139)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.jboss.forge.shell.command.Execution.perform(Execution.java:149)
... 31 more
Caused by: org.apache.http.conn.HttpHostConnectException: Connection to https://raw.github.com refused
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:127)
at org.apache.http.impl.conn.AbstractPoolEntry.open(AbstractPoolEntry.java:147)
at org.apache.http.impl.conn.AbstractPooledConnAdapter.open(AbstractPooledConnAdapter.java:108)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:415)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:641)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:576)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:554)
at org.jboss.forge.shell.util.PluginUtil.findPlugin(PluginUtil.java:88)
at org.jboss.forge.shell.plugins.builtin.ForgePlugin.installFromIndex(ForgePlugin.java:236)
... 36 more
Caused by: java.net.ConnectException: Connection timed out: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(Unknown Source)
at org.apache.http.conn.ssl.SSLSocketFactory.connectSocket(SSLSocketFactory.java:333)
at org.apache.http.impl.conn.DefaultClientConnectionOperator.openConnection(DefaultClientConnectionOperator.java:123)
... 44 more
Thanks in advance
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 5 months
[JBoss JIRA] (FORGE-700) Annotation processor 'org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor' not found
by George Gastaldi (JIRA)
George Gastaldi created FORGE-700:
-------------------------------------
Summary: Annotation processor 'org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor' not found
Key: FORGE-700
URL: https://issues.jboss.org/browse/FORGE-700
Project: Forge
Issue Type: Bug
Reporter: George Gastaldi
When choosing a JPA Model gen (Hibernate) the following error occurs:
{code}
[INFO] javac option: -proc:only
[INFO] javac option: -processor
[INFO] javac option: org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor
[INFO] javac option: -d
[INFO] javac option: /Downloads/workspace/forge-core/dist/target/forge-distribution-1.1.2-SNAPSHOT/bin/my3rdForgeApp/target/classes
[INFO] javac option: -s
[INFO] javac option: /Downloads/workspace/forge-core/dist/target/forge-distribution-1.1.2-SNAPSHOT/bin/my3rdForgeApp/target/generated-sources/apt
[INFO] diagnostic error: Annotation processor 'org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor' not found
[ERROR] error on execute: error during compilation
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 5 months
[JBoss JIRA] (FORGE-563) Create a class lookup index
by Jason Porter (JIRA)
Jason Porter created FORGE-563:
----------------------------------
Summary: Create a class lookup index
Key: FORGE-563
URL: https://issues.jboss.org/browse/FORGE-563
Project: Forge
Issue Type: Enhancement
Components: Maven Integration
Affects Versions: 1.0.4.Final
Reporter: Jason Porter
We need to support an index of classes and dependencies which contain them.
This would allow us to do wildcard expansion, and also allow facets to depend on a class, not a specific dependency. I believe Lincoln has the information about wildcard support, for the facet dependency idea my thoughts are an index like this would allow a facet to declare a class, or collection of classes, which it requires to function. For example the faces facet could depend on FacesContext, or PhaseListener or some other class. When a facet checks to see if a project has the dependencies it could match multiple jars instead one specific jar. Again in the faces example it could match Mojarra, MyFaces, JBoss spec jars, Geromino spec jars, etc.
We could keep a local cache and add to it, we could also have an online cache available which users could push to and also merge into their local cache.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 6 months
[JBoss JIRA] (FORGE-424) JavaParser does not understand wildcard imports like "javax.persistence.*"
by Lincoln Baxter III (Created) (JIRA)
JavaParser does not understand wildcard imports like "javax.persistence.*"
--------------------------------------------------------------------------
Key: FORGE-424
URL: https://issues.jboss.org/browse/FORGE-424
Project: Forge
Issue Type: Bug
Components: Parsers / File Manipulation
Affects Versions: 1.0.0.Beta5
Reporter: Lincoln Baxter III
Fix For: 1.0.0.Final
The JavaParser Annotation.getQualifiedName() will return "Column" instead of "javax.persistence.Column" for the following example class scenario. It should be able to understand the wildcard, given the proper metadata:
{code}package demo.entities;
import javax.persistence.*;
@Entity
public class Contact implements java.io.Serializable {
@Id
private @GeneratedValue(strategy = GenerationType.AUTO)
@Column(name = "id", updatable = false, nullable = false)
Long id = null;
@Version
private @Column(name = "version")
int version = 0;
public Long getId() {
return this.id;
}
public void setId(final Long id) {
this.id = id;
}
public int getVersion() {
return this.version;
}
public void setVersion(final int version) {
this.version = version;
}
@Override
public boolean equals(Object that) {
if (this == that) {
return true;
}
if (that == null) {
return false;
}
if (getClass() != that.getClass()) {
return false;
}
if (id != null) {
return id.equals(((Contact) that).id);
}
return super.equals(that);
}
@Override
public int hashCode() {
if (id != null) {
return id.hashCode();
}
return super.hashCode();
}
private String name;
public String getName() {
return this.name;
}
public void setName(final String name) {
this.name = name;
}
public String toString() {
return "" + name;
}
}{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 6 months
[JBoss JIRA] (FORGE-698) Forge must try to box identifiers when they are primitives
by Marius Bogoevici (JIRA)
Marius Bogoevici created FORGE-698:
--------------------------------------
Summary: Forge must try to box identifiers when they are primitives
Key: FORGE-698
URL: https://issues.jboss.org/browse/FORGE-698
Project: Forge
Issue Type: Bug
Components: Scaffold
Affects Versions: 1.1.1.Final
Reporter: Marius Bogoevici
With TicketMonster (https://github.com/jboss-jdf/ticket-monster, tag 2.0.1.Final), when running the admin_layer.fsh script (without applying the patches), the class org.jboss.jdf.examples.view.SectionAllocationBean will contain the following uncompilable code
{code}
return ejbProxy.findById(long.valueOf(value));
{code}
(note the use of lowercase l in long)
This is caused by the id field in the entity class being primitive rather than object. While this can be worked around easily (using a class is better than the primitive anyway), this still remains a bug.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 6 months
[JBoss JIRA] (FORGE-430) Fix MavenCoreFacetImpl getPom()
by Max Schwaab (JIRA)
Max Schwaab created FORGE-430:
---------------------------------
Summary: Fix MavenCoreFacetImpl getPom()
Key: FORGE-430
URL: https://issues.jboss.org/browse/FORGE-430
Project: Forge
Issue Type: Bug
Affects Versions: 1.0.0.Beta5
Environment: Windows 7, Desktop PC
Reporter: Max Schwaab
Priority: Minor
Fix For: Future
Please have a look at org.jboss.forge.maven.facets.MavenCoreFacetImpl in the forge-project-model-maven project.
The getPom() method reads the pom directly from the file resource. This results in a warning when using maven properties for dependency versions, e.g. when you try to install a plugin via the source-plugin command (***WARNING*** Could not resolve dependency [org.some:dependency:jar::${some.version}])
The plugin works after installation and I don't know if its important to resolve this issue, but in the code is a "//FIXME"-remark too. The same may be relevant for setPOM(final Model pom) too.
{code:title=MavenCoreFacetImpl getPom()}
@Override
public Model getPOM()
{
try
{
Model result = new Model();
// FIXME this should/can-not use the Maven Native file writer if we are going to abstract file APIs
MavenXpp3Reader reader = new MavenXpp3Reader();
FileInputStream stream = new FileInputStream(getPOMFile().getUnderlyingResourceObject());
if (stream.available() > 0)
{
result = reader.read(stream);
}
stream.close();
result.setPomFile(getPOMFile().getUnderlyingResourceObject());
return result;
}
catch (IOException e)
{
throw new ProjectModelException("Could not open POM file: " + getPOMFile(), e);
}
catch (XmlPullParserException e)
{
throw new ProjectModelException("Could not parse POM file: " + getPOMFile(), e);
}
}
{code}
Example for my plugins pom.xml
{code:xml}
<?xml version="1.0" encoding="UTF-8"?>
<project
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
.
.
.
<properties>
<some.version>1.0</some.version>
</properties>
<dependencies>
.
.
.
<dependency>
<groupId>org.some</groupId>
<artifactId>dependency</artifactId>
<version>${some.version}</version>
</dependency>
.
.
.
</dependencies>
<repositories>
.
.
.
<repository>
<id>repository.some</id>
<name>Some Repository for Maven</name>
<url>http://some.repo.url</url>
</repository>
.
.
.
</repositories>
.
.
.
</project>
{code}
Best regards
Max
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 6 months
[JBoss JIRA] (FORGE-674) JavaPlugin: add new command 'new-interface'
by fiorenzo pizza (JIRA)
fiorenzo pizza created FORGE-674:
------------------------------------
Summary: JavaPlugin: add new command 'new-interface'
Key: FORGE-674
URL: https://issues.jboss.org/browse/FORGE-674
Project: Forge
Issue Type: Enhancement
Components: Builtin Plugins
Reporter: fiorenzo pizza
Assignee: fiorenzo pizza
javaplugin lacks an useful method to create java interfaces.
very similar to 'new-class', this is my implementation:
@Command("new-interface")
public void newInterface(
@PipeIn final InputStream in,
@Option(required = false, help = "the package in which to build this Interface", description = "source package", type = PromptType.JAVA_PACKAGE, name = "package") final String pckg,
@Option(required = false, help = "the interface definition: surround with quotes", description = "interface definition") final String... def)
throws FileNotFoundException {
JavaSourceFacet java = project.getFacet(JavaSourceFacet.class);
JavaInterface jc = null;
if (def != null) {
String classDef = Strings.join(Arrays.asList(def), " ");
jc = JavaParser.parse(JavaInterface.class, classDef);
} else if (in != null) {
jc = JavaParser.parse(JavaInterface.class, in);
} else {
throw new RuntimeException("arguments required");
}
if (pckg != null) {
jc.setPackage(pckg);
}
if (!jc.hasSyntaxErrors()) {
java.saveJavaSource(jc);
} else {
writer.println(ShellColor.RED, "Syntax Errors:");
for (SyntaxError error : jc.getSyntaxErrors()) {
writer.println(error.toString());
}
writer.println();
if (prompt.promptBoolean(
"Your class has syntax errors, create anyway?", true)) {
java.saveJavaSource(jc);
}
}
pickUp.fire(new PickupResource(java.getJavaResource(jc)));
}
i tested this and also the command 'new-method' works nicely:
@Test
public void testCreateJavaInterface() throws Exception {
getShell()
.execute(
"java new-interface --package org.jboss.forge.test.interfaces \"public interface TestingInterfaceCreation {}\"");
getShell().execute("build");
JavaInterface javaClass = (JavaInterface) getProject()
.getFacet(JavaSourceFacet.class)
.getJavaResource(
Packages.toFileSyntax("org.jboss.forge.test.interfaces.TestingInterfaceCreation"))
.getJavaSource();
assertNotNull(javaClass);
}
and
@Test
public void testCreateJavaMethodOnInterface() throws Exception {
getShell()
.execute(
"java new-interface --package org.jboss.forge.test.interfaces \"public interface TestingInterfaceCreation {}\"");
getShell().execute("java new-method \"public void testing();\"");
getShell().execute("ls");
getShell().execute("build");
JavaInterface javaClass = (JavaInterface) getProject()
.getFacet(JavaSourceFacet.class)
.getJavaResource(
Packages.toFileSyntax("org.jboss.forge.test.interfaces.TestingInterfaceCreation"))
.getJavaSource();
Method<JavaInterface> method = javaClass.getMethod("testing");
assertNotNull(method);
}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 6 months