Uploaded image for project: 'E-commerce'
  1. E-commerce
  2. ECOMMERCE-510

Commercetools: getShippingMethods throws RestExceptionMapper error

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Neutral
    • 1.3.2
    • 1.3.2
    • connector
    • None

    Description

      • getShippingMethods throws InvalidDefinitionException
      2022-03-22 17:38:38,553 ERROR info.magnolia.rest.RestExceptionMapper            : Exception thrown executing REST endpoint, returning 500com.fasterxml.jackson.databind.exc.InvalidDefinitionException: Java 8 date/time type `java.time.ZonedDateTime` not supported by default: add Module "com.fasterxml.jackson.datatype:jackson-datatype-jsr310" to enable handling (through reference chain: java.util.ArrayList[0]->com.commercetools.api.models.shipping_method.ShippingMethodImpl["createdAt"])	at com.fasterxml.jackson.databind.exc.InvalidDefinitionException.from(InvalidDefinitionException.java:77) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.SerializerProvider.reportBadDefinition(SerializerProvider.java:1276) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.impl.UnsupportedTypeSerializer.serialize(UnsupportedTypeSerializer.java:35) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:728) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.std.BeanSerializerBase.serializeFields(BeanSerializerBase.java:770) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.BeanSerializer.serialize(BeanSerializer.java:178) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.impl.IndexedListSerializer.serializeContents(IndexedListSerializer.java:119) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.impl.IndexedListSerializer.serialize(IndexedListSerializer.java:79) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.impl.IndexedListSerializer.serialize(IndexedListSerializer.java:18) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.DefaultSerializerProvider._serialize(DefaultSerializerProvider.java:480) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ser.DefaultSerializerProvider.serializeValue(DefaultSerializerProvider.java:319) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ObjectWriter$Prefetch.serialize(ObjectWriter.java:1514) ~[jackson-databind-2.12.3.jar:2.12.3]	at com.fasterxml.jackson.databind.ObjectWriter.writeValue(ObjectWriter.java:1006) ~[jackson-databind-2.12.3.jar:2.12.3]	at org.jboss.resteasy.plugins.providers.jackson.ResteasyJackson2Provider.writeTo(ResteasyJackson2Provider.java:347) ~[resteasy-jackson2-provider-4.6.1.Final.jar:4.6.1.Final] 

      You can use this request for testing with the appropriate values

      curl --location --request GET 'https://author-addons.beta.de.magnolia-cloud.com/.rest/ecommerce/v2/carts/0a604e64-8b29-40ac-8583-183aa68bc4d0/shippingmethods?connectionName=connection&definitionName=commercetools' \--header 'Authorization: Basic c3VwZXJ1c2VyOnN1cGVyYWRkb24='

      Checklists

        Acceptance criteria

        Attachments

          Issue Links

            Activity

              People

                jalonso Jesus Alonso
                jalonso Jesus Alonso
                Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  Checklists

                    Bug DoR
                    Task DoD

                    Time Tracking

                      Estimated:
                      Original Estimate - Not Specified
                      Not Specified
                      Remaining:
                      Remaining Estimate - Not Specified
                      Not Specified
                      Logged:
                      Time Spent - 5m
                      5m

                      Jenkins

                        No builds found.