[JBoss JIRA] (ISPN-8073) ConfigurationConverterTest.testConversionAndSerializationFrom60 test failure
by Ryan Emerson (JIRA)
[ https://issues.jboss.org/browse/ISPN-8073?page=com.atlassian.jira.plugin.... ]
Ryan Emerson reassigned ISPN-8073:
----------------------------------
Assignee: Ryan Emerson (was: Tristan Tarrant)
> ConfigurationConverterTest.testConversionAndSerializationFrom60 test failure
> -----------------------------------------------------------------------------
>
> Key: ISPN-8073
> URL: https://issues.jboss.org/browse/ISPN-8073
> Project: Infinispan
> Issue Type: Bug
> Components: Test Suite - Core
> Affects Versions: 9.1.0.Final
> Reporter: Tristan Tarrant
> Assignee: Ryan Emerson
> Fix For: 9.1.1.Final
>
>
> java.lang.AssertionError: expected:<50> but was:<0>
> at org.infinispan.tools.ConfigurationConverterTest.assertPersistenceConverted(ConfigurationConverterTest.java:770)
> at org.infinispan.tools.ConfigurationConverterTest.access$1500(ConfigurationConverterTest.java:50)
> at org.infinispan.tools.ConfigurationConverterTest$1.call(ConfigurationConverterTest.java:88)
> at org.infinispan.test.TestingUtil.withCacheManager(TestingUtil.java:1433)
> at org.infinispan.tools.ConfigurationConverterTest.testConversionAndSerializationFrom60(ConfigurationConverterTest.java:69)
> at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:748)
> ... Removed 21 stack frames
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
8 years, 8 months
[JBoss JIRA] (ISPN-8073) ConfigurationConverterTest.testConversionAndSerializationFrom60 test failure
by Ryan Emerson (JIRA)
[ https://issues.jboss.org/browse/ISPN-8073?page=com.atlassian.jira.plugin.... ]
Ryan Emerson updated ISPN-8073:
-------------------------------
Component/s: Loaders and Stores
> ConfigurationConverterTest.testConversionAndSerializationFrom60 test failure
> -----------------------------------------------------------------------------
>
> Key: ISPN-8073
> URL: https://issues.jboss.org/browse/ISPN-8073
> Project: Infinispan
> Issue Type: Bug
> Components: Loaders and Stores, Test Suite - Core
> Affects Versions: 9.1.0.Final
> Reporter: Tristan Tarrant
> Assignee: Ryan Emerson
> Fix For: 9.1.1.Final
>
>
> java.lang.AssertionError: expected:<50> but was:<0>
> at org.infinispan.tools.ConfigurationConverterTest.assertPersistenceConverted(ConfigurationConverterTest.java:770)
> at org.infinispan.tools.ConfigurationConverterTest.access$1500(ConfigurationConverterTest.java:50)
> at org.infinispan.tools.ConfigurationConverterTest$1.call(ConfigurationConverterTest.java:88)
> at org.infinispan.test.TestingUtil.withCacheManager(TestingUtil.java:1433)
> at org.infinispan.tools.ConfigurationConverterTest.testConversionAndSerializationFrom60(ConfigurationConverterTest.java:69)
> at java.util.concurrent.FutureTask.run(FutureTask.java:266)
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
> at java.lang.Thread.run(Thread.java:748)
> ... Removed 21 stack frames
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
8 years, 8 months
[JBoss JIRA] (IPROTO-33) ClassCastException with Array of Enums
by Adrian Nistor (JIRA)
[ https://issues.jboss.org/browse/IPROTO-33?page=com.atlassian.jira.plugin.... ]
Adrian Nistor updated IPROTO-33:
--------------------------------
Status: Open (was: New)
> ClassCastException with Array of Enums
> --------------------------------------
>
> Key: IPROTO-33
> URL: https://issues.jboss.org/browse/IPROTO-33
> Project: Infinispan ProtoStream
> Issue Type: Bug
> Affects Versions: 4.0.0.Alpha5
> Reporter: Gustavo Fernandes
>
> The entity is defined as:
> {code:java}
> public class Account extends BaseMessage {
> public enum Currency {
> EUR, GBP, USD, BRL
> }
> ...
> private Currency[] currencies;
> ...
> }
> {code}
> Protofile:
> {code}
> message Account {
> ...
> /* @TypeId(43) */
> enum Currency {
> EUR = 0;
> GBP = 1;
> ...
> }
> repeated Currency currencies = 6;
> ...
> }
> {code}
> Marshaller:
> {code:java}
> public class AccountMarshaller implements MessageMarshaller<Account> {
> ...
> @Override
> public Account readFrom(ProtoStreamReader reader) throws IOException {
> ...
> Account.Currency[] currencies = reader.readArray("currencies", Account.Currency.class);
> Account account = new Account();
> ...
> account.setCurrencies(currencies);
> return account;
> }
> @Override
> public void writeTo(ProtoStreamWriter writer, Account account) throws IOException {
> ...
> writer.writeArray("currencies", account.getCurrencies(), Account.Currency.class);
> }
> }
> {code}
> When trying to marshal and unmarshall a message:
> {code:java}
> Account account = ...
> SerializationContext context = ...
> byte[] bytes = ProtobufUtil.toWrappedByteArray(context, account);
> // Throws CCE
> Account acc = ProtobufUtil.fromWrappedByteArray(context, bytes);
> {code}
> {noformat}
> java.lang.ClassCastException: java.lang.Long cannot be cast to [B
> at org.infinispan.protostream.impl.ProtoStreamReaderImpl.readCollection(ProtoStreamReaderImpl.java:374)
> at org.infinispan.protostream.impl.ProtoStreamReaderImpl.readArray(ProtoStreamReaderImpl.java:470)
> at org.infinispan.protostream.domain.marshallers.AccountMarshaller.readFrom(AccountMarshaller.java:33)
> at org.infinispan.protostream.domain.marshallers.AccountMarshaller.readFrom(AccountMarshaller.java:14)
> at org.infinispan.protostream.impl.MessageMarshallerDelegate.unmarshall(MessageMarshallerDelegate.java:113)
> at org.infinispan.protostream.WrappedMessage.readMessage(WrappedMessage.java:306)
> at org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:154)
> at org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:149)
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
8 years, 8 months
[JBoss JIRA] (IPROTO-33) ClassCastException with Array of Enums
by Gustavo Fernandes (JIRA)
[ https://issues.jboss.org/browse/IPROTO-33?page=com.atlassian.jira.plugin.... ]
Gustavo Fernandes commented on IPROTO-33:
-----------------------------------------
Hey [~anistor], the IPROTO project is not in sync with the released versions of protostream, so I cannot report issues against the correct version
> ClassCastException with Array of Enums
> --------------------------------------
>
> Key: IPROTO-33
> URL: https://issues.jboss.org/browse/IPROTO-33
> Project: Infinispan ProtoStream
> Issue Type: Bug
> Affects Versions: 4.0.0.Alpha5
> Reporter: Gustavo Fernandes
>
> The entity is defined as:
> {code:java}
> public class Account extends BaseMessage {
> public enum Currency {
> EUR, GBP, USD, BRL
> }
> ...
> private Currency[] currencies;
> ...
> }
> {code}
> Protofile:
> {code}
> message Account {
> ...
> /* @TypeId(43) */
> enum Currency {
> EUR = 0;
> GBP = 1;
> ...
> }
> repeated Currency currencies = 6;
> ...
> }
> {code}
> Marshaller:
> {code:java}
> public class AccountMarshaller implements MessageMarshaller<Account> {
> ...
> @Override
> public Account readFrom(ProtoStreamReader reader) throws IOException {
> ...
> Account.Currency[] currencies = reader.readArray("currencies", Account.Currency.class);
> Account account = new Account();
> ...
> account.setCurrencies(currencies);
> return account;
> }
> @Override
> public void writeTo(ProtoStreamWriter writer, Account account) throws IOException {
> ...
> writer.writeArray("currencies", account.getCurrencies(), Account.Currency.class);
> }
> }
> {code}
> When trying to marshal and unmarshall a message:
> {code:java}
> Account account = ...
> SerializationContext context = ...
> byte[] bytes = ProtobufUtil.toWrappedByteArray(context, account);
> // Throws CCE
> Account acc = ProtobufUtil.fromWrappedByteArray(context, bytes);
> {code}
> {noformat}
> java.lang.ClassCastException: java.lang.Long cannot be cast to [B
> at org.infinispan.protostream.impl.ProtoStreamReaderImpl.readCollection(ProtoStreamReaderImpl.java:374)
> at org.infinispan.protostream.impl.ProtoStreamReaderImpl.readArray(ProtoStreamReaderImpl.java:470)
> at org.infinispan.protostream.domain.marshallers.AccountMarshaller.readFrom(AccountMarshaller.java:33)
> at org.infinispan.protostream.domain.marshallers.AccountMarshaller.readFrom(AccountMarshaller.java:14)
> at org.infinispan.protostream.impl.MessageMarshallerDelegate.unmarshall(MessageMarshallerDelegate.java:113)
> at org.infinispan.protostream.WrappedMessage.readMessage(WrappedMessage.java:306)
> at org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:154)
> at org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:149)
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
8 years, 8 months
[JBoss JIRA] (IPROTO-33) ClassCastException with Array of Enums
by Gustavo Fernandes (JIRA)
Gustavo Fernandes created IPROTO-33:
---------------------------------------
Summary: ClassCastException with Array of Enums
Key: IPROTO-33
URL: https://issues.jboss.org/browse/IPROTO-33
Project: Infinispan ProtoStream
Issue Type: Bug
Affects Versions: 4.0.0.Alpha5
Reporter: Gustavo Fernandes
The entity is defined as:
{code:java}
public class Account extends BaseMessage {
public enum Currency {
EUR, GBP, USD, BRL
}
...
private Currency[] currencies;
...
}
{code}
Protofile:
{code}
message Account {
...
/* @TypeId(43) */
enum Currency {
EUR = 0;
GBP = 1;
...
}
repeated Currency currencies = 6;
...
}
{code}
Marshaller:
{code:java}
public class AccountMarshaller implements MessageMarshaller<Account> {
...
@Override
public Account readFrom(ProtoStreamReader reader) throws IOException {
...
Account.Currency[] currencies = reader.readArray("currencies", Account.Currency.class);
Account account = new Account();
...
account.setCurrencies(currencies);
return account;
}
@Override
public void writeTo(ProtoStreamWriter writer, Account account) throws IOException {
...
writer.writeArray("currencies", account.getCurrencies(), Account.Currency.class);
}
}
{code}
When trying to marshal and unmarshall a message:
{code:java}
Account account = ...
SerializationContext context = ...
byte[] bytes = ProtobufUtil.toWrappedByteArray(context, account);
// Throws CCE
Account acc = ProtobufUtil.fromWrappedByteArray(context, bytes);
{code}
{noformat}
java.lang.ClassCastException: java.lang.Long cannot be cast to [B
at org.infinispan.protostream.impl.ProtoStreamReaderImpl.readCollection(ProtoStreamReaderImpl.java:374)
at org.infinispan.protostream.impl.ProtoStreamReaderImpl.readArray(ProtoStreamReaderImpl.java:470)
at org.infinispan.protostream.domain.marshallers.AccountMarshaller.readFrom(AccountMarshaller.java:33)
at org.infinispan.protostream.domain.marshallers.AccountMarshaller.readFrom(AccountMarshaller.java:14)
at org.infinispan.protostream.impl.MessageMarshallerDelegate.unmarshall(MessageMarshallerDelegate.java:113)
at org.infinispan.protostream.WrappedMessage.readMessage(WrappedMessage.java:306)
at org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:154)
at org.infinispan.protostream.ProtobufUtil.fromWrappedByteArray(ProtobufUtil.java:149)
{noformat}
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
8 years, 8 months
[JBoss JIRA] (ISPN-7988) ScatteredSyncFuncTest>DistSyncFuncTest.testComputeIfAbsentFromNonOwner fails with trace logging enabled
by Dan Berindei (JIRA)
[ https://issues.jboss.org/browse/ISPN-7988?page=com.atlassian.jira.plugin.... ]
Dan Berindei commented on ISPN-7988:
------------------------------------
>From Radim: The thing that went wrong was that the compute command was successful even if it did not match the criteria (absent/present). Also, compute command has to send the whole new value from primary to originator and store it (if successful) because originator does not know the previous value - it cannot generate it in order to store that for backup.
> ScatteredSyncFuncTest>DistSyncFuncTest.testComputeIfAbsentFromNonOwner fails with trace logging enabled
> -------------------------------------------------------------------------------------------------------
>
> Key: ISPN-7988
> URL: https://issues.jboss.org/browse/ISPN-7988
> Project: Infinispan
> Issue Type: Bug
> Components: Test Suite - Core
> Reporter: Dan Berindei
> Assignee: Radim Vansa
> Priority: Critical
> Labels: testsuite_stability
>
> Every time I run the test I get this failure twice, with the same test parameters:
> {noformat}
> testComputeIfAbsentFromNonOwner[SCATTERED_SYNC, tx=false, numOwners=1, l1=false](org.infinispan.scattered.ScatteredSyncFuncTest) Time elapsed: 0.159 sec <<< FAILURE!
> java.lang.AssertionError: expected [1] but found [0]
> at org.testng.Assert.fail(Assert.java:94)
> at org.testng.Assert.failNotEquals(Assert.java:494)
> at org.testng.Assert.assertEquals(Assert.java:123)
> at org.testng.Assert.assertEquals(Assert.java:370)
> at org.testng.Assert.assertEquals(Assert.java:380)
> at org.infinispan.scattered.Utils.assertOwnershipAndNonOwnership(Utils.java:49)
> at org.infinispan.scattered.ScatteredSyncFuncTest.assertOwnershipAndNonOwnership(ScatteredSyncFuncTest.java:20)
> at org.infinispan.distribution.BaseDistFunctionalTest.assertOnAllCachesAndOwnership(BaseDistFunctionalTest.java:162)
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)
8 years, 8 months