You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@asterixdb.apache.org by Xikui Wang <xi...@uci.edu> on 2016/03/23 21:26:04 UTC
Head version on Github compile error.
Hi,
I met a problem when compiling the head version. I think it's because
certain method is missing in the Node.java. Here are the error message:
$PATH/incubator-asterixdb/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
> Error:(84, 32) java: cannot find symbol
> symbol: method getReplicationPort()
> location: variable node of type
> org.apache.asterix.event.schema.cluster.Node
> Error:(84, 68) java: cannot find symbol
> symbol: method getReplicationPort()
> location: variable node of type
> org.apache.asterix.event.schema.cluster.Node
Here are the git diffs I got with one of the previous version I have:
index cb7bcab..5d31d9a 100644
> ---
> a/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
> +++
> b/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
> @@ -77,10 +77,15 @@ public class AsterixReplicationProperties extends
> AbstractAsterixProperties {
> }
> public int getDataReplicationPort(String nodeId) {
> - if (cluster != null) {
> - return
> cluster.getDataReplication().getReplicationPort().intValue();
> + if (cluster != null && cluster.getDataReplication() != null) {
> + for (int i = 0; i < cluster.getNode().size(); i++) {
> + Node node = cluster.getNode().get(i);
> + if (getRealCluserNodeID(node.getId()).equals(nodeId)) {
> + return node.getReplicationPort() != null ?
> node.getReplicationPort().intValue()
> + :
> cluster.getDataReplication().getReplicationPort().intValue();
> + }
> + }
> }
> -
> return REPLICATION_DATAPORT_DEFAULT;
> }
Thank you.
Best,
Xikui
Re: Head version on Github compile error.
Posted by Xikui Wang <xi...@uci.edu>.
Hi Murtadha,
Thanks for your help. 'mvn clean install' did solve my problem. :)
Best,
Xikui
On Wed, Mar 23, 2016 at 2:11 PM, Murtadha Hubail <hu...@gmail.com>
wrote:
> Hi Xikui,
>
> The error is happening because Node.java is an auto-generated class and it
> appears that you have an old version in your local maven repository.
>
> If you checkout a clean HEAD version and do ‘mvn clean install’, it should
> work.
>
> Cheers,
> Murtadha
>
> On Mar 23, 2016, at 1:26 PM, Xikui Wang <xi...@uci.edu> wrote:
>
> Hi,
>
> I met a problem when compiling the head version. I think it's because
> certain method is missing in the Node.java. Here are the error message:
>
>
> $PATH/incubator-asterixdb/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
>
> Error:(84, 32) java: cannot find symbol
> symbol: method getReplicationPort()
> location: variable node of type
> org.apache.asterix.event.schema.cluster.Node
> Error:(84, 68) java: cannot find symbol
> symbol: method getReplicationPort()
> location: variable node of type
> org.apache.asterix.event.schema.cluster.Node
>
>
>
> Here are the git diffs I got with one of the previous version I have:
>
> index cb7bcab..5d31d9a 100644
>
> ---
>
> a/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
> +++
>
> b/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
> @@ -77,10 +77,15 @@ public class AsterixReplicationProperties extends
> AbstractAsterixProperties {
> }
> public int getDataReplicationPort(String nodeId) {
> - if (cluster != null) {
> - return
> cluster.getDataReplication().getReplicationPort().intValue();
> + if (cluster != null && cluster.getDataReplication() != null) {
> + for (int i = 0; i < cluster.getNode().size(); i++) {
> + Node node = cluster.getNode().get(i);
> + if (getRealCluserNodeID(node.getId()).equals(nodeId)) {
> + return node.getReplicationPort() != null ?
> node.getReplicationPort().intValue()
> + :
> cluster.getDataReplication().getReplicationPort().intValue();
> + }
> + }
> }
> -
> return REPLICATION_DATAPORT_DEFAULT;
> }
>
>
>
> Thank you.
>
> Best,
> Xikui
>
>
>
Re: Head version on Github compile error.
Posted by Murtadha Hubail <hu...@gmail.com>.
Hi Xikui,
The error is happening because Node.java is an auto-generated class and it appears that you have an old version in your local maven repository.
If you checkout a clean HEAD version and do ‘mvn clean install’, it should work.
Cheers,
Murtadha
> On Mar 23, 2016, at 1:26 PM, Xikui Wang <xi...@uci.edu> wrote:
>
> Hi,
>
> I met a problem when compiling the head version. I think it's because
> certain method is missing in the Node.java. Here are the error message:
>
> $PATH/incubator-asterixdb/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
>> Error:(84, 32) java: cannot find symbol
>> symbol: method getReplicationPort()
>> location: variable node of type
>> org.apache.asterix.event.schema.cluster.Node
>> Error:(84, 68) java: cannot find symbol
>> symbol: method getReplicationPort()
>> location: variable node of type
>> org.apache.asterix.event.schema.cluster.Node
>
>
> Here are the git diffs I got with one of the previous version I have:
>
> index cb7bcab..5d31d9a 100644
>> ---
>> a/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
>> +++
>> b/asterix-common/src/main/java/org/apache/asterix/common/config/AsterixReplicationProperties.java
>> @@ -77,10 +77,15 @@ public class AsterixReplicationProperties extends
>> AbstractAsterixProperties {
>> }
>> public int getDataReplicationPort(String nodeId) {
>> - if (cluster != null) {
>> - return
>> cluster.getDataReplication().getReplicationPort().intValue();
>> + if (cluster != null && cluster.getDataReplication() != null) {
>> + for (int i = 0; i < cluster.getNode().size(); i++) {
>> + Node node = cluster.getNode().get(i);
>> + if (getRealCluserNodeID(node.getId()).equals(nodeId)) {
>> + return node.getReplicationPort() != null ?
>> node.getReplicationPort().intValue()
>> + :
>> cluster.getDataReplication().getReplicationPort().intValue();
>> + }
>> + }
>> }
>> -
>> return REPLICATION_DATAPORT_DEFAULT;
>> }
>
>
> Thank you.
>
> Best,
> Xikui