Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [lyo-dev] Version clash? OslcCoreMissingSetMethodException

Good morning 

 

And, the latest Lyo Designer 4.0.0-SNAPSHOT will need to be downloaded from the Edge update site http://download.eclipse.org/lyo/p2/edge/

 

I also realise that the instructions on how to setup an oslc4j project are no longer up to date for 4.0.0-snapshot. 

(as presented on http://oslc.github.io/developing-oslc-applications/eclipse_lyo/setup-an-oslc-provider-consumer-application.html)

 

I will update this page early this week. In the meantime, you can look at the sample projects in this repo (https://github.com/OSLC/lyo-adaptor-sample-modelling/tree/4.0.0-snapshot) for tips, in particular the pom.xml file.

 

 

 Regards

Jad 

 

 

 



On 17 May 2019, at 18:06, Andrii Berezovskyi <andriib@xxxxxx> wrote:

Lyo 4.0.0-SNAPSHOT is available from maven. I have updated the core README: https://github.com/eclipse/lyo.core/blob/master/README.md#getting-started


--
–Andrew.

2019-05-17  kl. 17:45 skrev Jan-Patrick Osterloh <osterloh@xxxxxxxx>:

Dear Jad,


Ok, I digged a little bit into this, and the problem is that the generated code for my DomainModel looks like this:

...
public HashSet<Link> getStars();
public void setStars(final Set<Link> stars );
...

Because the JenaModelHelper looks in the "createPropertyDefinitionToSetMethods" method for the set Method of this Feature like this:

final Method setMethod = beanClass.getMethod(setMethodName, getMethodReturnType);  

Since "getMethodReturnType" is "HashSet<Link>", but the method is "Set<Link>" it fails. After I manually changed the HashSet<Link> from the get Methods to Set<Link>, everything works again. Of course this is only a temporary hack...

I really would like to use Maven for dependency management, and I was so happy to lyo there! Will this be supported in feature?


Best regards
JPO





Am 17.05.2019 um 14:44 schrieb Jad El-Khoury:
Hi Jan-Patrick,

before I dig into this problem, any chance you want to work with Lyo 4.0.0-SNAPSHOT instead? Both for LyoDesigner, and the Lyo SDK. 

The biggest difference to consider first though is the fact that Lyo 4.0.0-SNAPSHOT uses JAX-RS2.0 (hence you need to adopt an implementation such as Jersey), while 2.4.0 still uses JAX-RS1.0 (and specifically WINK).

regards
______________________________
Jad El-khoury, PhD
KTH Royal Institute of Technology
School of Industrial Engineering and Management, Mechatronics Division
Brinellvägen 83, SE-100 44 Stockholm, Sweden
Phone: +46(0)8 790 6877 Mobile: +46(0)70 773 93 45
jad@xxxxxx, https://www.kth.se/profile/jad 

-----Original Message-----
From: lyo-dev-bounces@xxxxxxxxxxx <lyo-dev-bounces@xxxxxxxxxxx> On Behalf Of Jan-Patrick Osterloh
Sent: Friday, 17 May 2019 13:50
To: lyo-dev@xxxxxxxxxxx
Subject: [lyo-dev] Version clash? OslcCoreMissingSetMethodException

Dear all,

I recently switched to LYO designer 2.4.0. When I access the generated webapp with my client, I get some OslcCoreMissingSetMethodExceptions
(which are somehow hidden and not printed in stacktrace....). I guess that my client does not "understand" the new get Methods. I already found https://github.com/eclipse/lyo.designer/issues/61

To what "client" version do I need to switch? My current maven setup is:
        <dependency>
            <groupId>org.eclipse.lyo.oslc4j.core</groupId>
            <artifactId>oslc4j-jena-provider</artifactId>
            <version>${lyo.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>org.slf4j</groupId>
                    <artifactId>slf4j-api</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>org.slf4j</groupId>
                    <artifactId>slf4j-log4j12</artifactId>
                </exclusion>
                <exclusion>
                    <groupId>xml-apis</groupId>
                    <artifactId>xml-apis</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        <dependency>
            <groupId>org.eclipse.lyo.oslc4j.core</groupId>
            <artifactId>oslc4j-json4j-provider</artifactId>
            <version>${lyo.version}</version>
        </dependency>
        <dependency>
            <groupId>org.eclipse.lyo.oslc4j.core</groupId>
            <artifactId>oslc4j-wink</artifactId>
            <version>${lyo.version}</version>
            <exclusions>
                <exclusion>
                    <groupId>org.slf4j</groupId>
                    <artifactId>slf4j-api</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

(with lyo.version set to 2.4.0, and I also tested 2.2.0).
Both are from the Eclipse Releases repository (https://repo.eclipse.org/content/groups/releases/).


Best regards
Jan-Patrick

--
Dipl. Inform. Jan-Patrick Osterloh
Senior Research Engineer
Human Centered Design Group

OFFIS e.V. - Institut für Informatik | Institute for Information Technology
             FuE Bereich Verkehr     | R&D Division Transportation
             Escherweg 2, 26121 Oldenburg - Germany
Room:        D107
Phone/Fax:   +49 441 97 22-524 / -502
E-Mail:      osterloh@xxxxxxxx
URL:         http://www.offis.de 

Registergericht: Amtsgericht Oldenburg VR 1956
Vorstand: Prof. Dr.-Ing. Wolfgang H. Nebel (Vorsitzender),
          Prof. Dr. techn. Susanne Boll-Westermann,
          Prof. Dr.-Ing. Axel Hahn,
          Prof. Dr.-Ing. Andreas Hein,
          Prof. Dr. Sebastian Lehnhoff 

_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/lyo-dev
_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/lyo-dev

-- 
Dipl. Inform. Jan-Patrick Osterloh
Senior Research Engineer
Human Centered Design Group

OFFIS e.V. - Institut für Informatik | Institute for Information Technology
             FuE Bereich Verkehr     | R&D Division Transportation
             Escherweg 2, 26121 Oldenburg - Germany
Room:        D107
Phone/Fax:   +49 441 97 22-524 / -502
E-Mail:      osterloh@xxxxxxxx
URL:         http://www.offis.de 

Registergericht: Amtsgericht Oldenburg VR 1956
Vorstand: Prof. Dr.-Ing. Wolfgang H. Nebel (Vorsitzender),
          Prof. Dr. techn. Susanne Boll-Westermann,
          Prof. Dr.-Ing. Axel Hahn,
          Prof. Dr.-Ing. Andreas Hein,
          Prof. Dr. Sebastian Lehnhoff 

_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/lyo-dev

_______________________________________________
lyo-dev mailing list
lyo-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/lyo-dev

Back to the top