Sonarqube 5.5 and mariadb - sonarqube

We are trying to upgrade to lastest sonarqube 5.5. We have mariadb 10.1 (latest) and since now we had no problems with sonarqube.
Now, with the upgrade, sonarqube will not boot. It says:
Unsupported mysql version: 5.5. Minimal supported version is 5.6.
Is there any trick we can use to make "sonar think" we are using mysql 5.6?

You could change the MINIMAL_SUPPORTED_DB_VERSIONS member in the Sonarqube's class https://github.com/SonarSource/sonarqube/blob/master/sonar-db/src/main/java/org/sonar/db/DatabaseChecker.java
private static final Map<String, Version> MINIMAL_SUPPORTED_DB_VERSIONS = ImmutableMap.of(
// MsSQL 2008 is 10.x
// MsSQL 2012 is 11.x
// MsSQL 2014 is 12.x
// https://support.microsoft.com/en-us/kb/321185
MsSql.ID, Version.create(10, 0, 0),
MySql.ID, Version.create(5, 6, 0),
Oracle.ID, Version.create(11, 0, 0),
PostgreSql.ID, Version.create(8, 0, 0)
);
And build the project again, but If they have that requirement it's possible that after the change not everything is going to work fine.

here is a bsdiff file.
you can Patch it with:
bspatch sonar-db-5.6.jar sonar-db-5.6.jar.new sonar-db-5.6.jar.patch
Replace it and it works!
https://drive.google.com/file/d/0B1EExMdpLmiLR1JmVFQ3ZTVPTlU/view?usp=sharing

MariaDB is not supported by SonarQube - still in v7. Please see this here:
SonarQube Requirements
The Solution to run SonarQube in combination with XAMPP is to change the database from MariaDB to MySQL. Here you'll find the steps for changing it:
https://gist.github.com/odan/c799417460470c3776ffa8adce57eece

Related

How can I query contract info with the latest polkadot-js and substrate contracts node?

I've been unable to query my existing contract recently due to Unable to create Enum via index 128, in Alive, Tombstone when using api.query.contracts.contractInfoOf. I get this error both on the command line and in the polkadot-js apps explorer.
These are the steps I took:
Deploy a contract with a salt
Retrieve the contract deployedAddress
Use contractInfoOf
const contractInfo = await api.query.contracts.contractInfoOf(deployedAddress);
I've tried downgrading ink! to 3.0-rc5, 3.0-rc4, 3.0-rc3 and then compiling but it doesn't seem to make any difference. Whenever my contract is built it references rc6 at the top:
{"metadataVersion":"0.1.0","source":{"hash":"0x...","language":"ink! 3.0.0-rc6","compiler":"rustc 1.58.0-nightly",
Which suggests its ignoring my .toml and using rc6 to compile the contract.
I changed my cargo-contract version to 0.14 but that causes polkadot-js to fail at reading the contract abi.
I've tried using the substrate-contracts-node using the latest commit from master and also using the v0.1.0 release. Same error in both cases.
> rustup info
stable-x86_64-unknown-linux-gnu (default)
rustc 1.56.1 (59eed8a2a 2021-11-01)
There are more details in an issue on polkadot-js.
Any pointers on how to get a working setup would be very helpful!
The problem here was substrate-contracts-node using an old version of the metadata.
I was able to check out the repo before the metadata merge was reverted and build locally (cargo build).
So checkout 8d91b8e to get the node to work with versions 7.7.1 and 6.6.1 of polkadot-js packages.
> git checkout 8d91b8e578065a7c06433cbd41ac059bf478a0bd
> cargo build
> ./target/debug/substrate-contracts-node --dev --tmp --version
substrate-contracts-node 0.1.0-8d91b8e-x86_64-linux-gnu

MvvmCross upgrade from 6.4.2 to 8.0.1

I recently upgraded MvvmCross from 6.4.2 to 8.0.1 version.
Both Xamarin.Android and Core projects have same nuget packages versions.
After upgrading in ViewModel in line: IMvxMessenger mvxMessenger = Mvx.IoCProvider.Resolve<IMvxMessenger>();
I get an error Failed to resolve type MvvmCross.Plugin.Messenger.IMvxMessenger
Has anyone already faced such a problem?
I have never used the 6.4.2 version but u can try to add this on initialize/setup
Mvx.IoCProvider.RegisterSingleton<IMvxMessenger>(() => new MvxMessengerHub());
This works on the 7.1.2 version
It is related to this issue documented on GitHub.
https://github.com/MvvmCross/MvvmCross/issues/4286
onurhazar commented on Oct 8:
We are having the same issue when we try to load MvxMessenger plugin.
It throws an exception at app launch (device only)(iOS). As a
workaround, you can override LoadPlugins method in Setup.cs like
below;
public override void LoadPlugins(IMvxPluginManager pluginManager)
{
base.LoadPlugins(pluginManager);
pluginManager.EnsurePluginLoaded<MvvmCross.Plugin.Messenger.Plugin>();
}

Test Case failures with a java.lang.ArrayIndexOutOfBoundsException: 28526 with JDK 8 and terracotta 3.4.0

I currently moved maven java code from jdk7 to jdk8 which uses terracotta and was working properly but after changing it to jdk8 , my test cases are getting failed. I am getting following error and I didn't get any clues through searching.
java.lang.ArrayIndexOutOfBoundsException: 28526
at com.tc.asm.ClassReader.readClass(ClassReader.java:2015)
at com.tc.asm.ClassReader.getClassName(ClassReader.java:229)
at com.tc.aspectwerkz.reflect.impl.asm.AsmClassInfo.getClassInfo(AsmClassInfo.java:305)
at com.tc.aspectwerkz.reflect.impl.asm.AsmClassInfo.createClassInfoFromStream(AsmClassInfo.java:717)
at com.tc.aspectwerkz.reflect.impl.asm.AsmClassInfo.getClassInfo(AsmClassInfo.java:256)
at com.tc.aspectwerkz.reflect.impl.asm.AsmClassInfo.getInterfaces(AsmClassInfo.java:558)
at com.tc.aspectwerkz.expression.regexp.TypePattern.matchInterfaces(TypePattern.java:147)
at com.tc.aspectwerkz.expression.regexp.TypePattern.matchInterfaces(TypePattern.java:147)
at com.tc.aspectwerkz.expression.regexp.TypePattern.matchSuperClasses(TypePattern.java:120)
at com.tc.aspectwerkz.expression.regexp.TypePattern.matchType(TypePattern.java:92)
at com.tc.aspectwerkz.expression.ExpressionVisitor.visit(ExpressionVisitor.java:437)
at com.tc.aspectwerkz.expression.ast.ASTClassPattern.jjtAccept(ASTClassPattern.java:24)
at com.tc.aspectwerkz.expression.ExpressionVisitor.visitAnnotatedNode(ExpressionVisitor.java:1016)
at com.tc.aspectwerkz.expression.ExpressionVisitor.visit(ExpressionVisitor.java:237)
at com.tc.aspectwerkz.expression.ast.ASTWithin.jjtAccept(ASTWithin.java:22)
at com.tc.aspectwerkz.expression.ExpressionVisitor.visit(ExpressionVisitor.java:100)
at com.tc.aspectwerkz.expression.ast.ASTExpression.jjtAccept(ASTExpression.java:22)
at com.tc.aspectwerkz.expression.ExpressionVisitor.visit(ExpressionVisitor.java:88)
at com.tc.aspectwerkz.expression.ExpressionVisitor.match(ExpressionVisitor.java:74)
at com.tc.object.config.ClassExpressionMatcherImpl.match(ClassExpressionMatcherImpl.java:24)
at com.tc.object.config.CompoundExpressionMatcher.match(CompoundExpressionMatcher.java:18)
at com.tc.object.config.StandardDSOClientConfigHelperImpl.shouldBeAdapted(StandardDSOClientConfigHelperImpl.java:1242)
at com.tc.object.bytecode.hook.impl.DefaultWeavingStrategy.transformInternal(DefaultWeavingStrategy.java:184)
at com.tc.object.bytecode.hook.impl.DefaultWeavingStrategy.transform(DefaultWeavingStrategy.java:134)
at com.tc.object.bytecode.hook.impl.DSOContextImpl.preProcess(DSOContextImpl.java:288)
at com.tc.object.bytecode.hook.impl.DSOContextImpl.transform(DSOContextImpl.java:392)
at org.terracotta.express.ClusteredStateLoader.transform(ClusteredStateLoader.java:124)
at org.terracotta.express.ClusteredStateLoader.loadClass(ClusteredStateLoader.java:83)
at org.terracotta.modules.ehcache.store.TerracottaClusteredInstanceFactory$1.call(TerracottaClusteredInstanceFactory.java:319)
at org.terracotta.modules.ehcache.store.TerracottaClusteredInstanceFactory$1.call(TerracottaClusteredInstanceFactory.java:317)
at org.terracotta.api.Terracotta.lookupOrCreateRoot(Terracotta.java:47)
at org.terracotta.modules.ehcache.store.TerracottaClusteredInstanceFactory.getStoreRoot(TerracottaClusteredInstanceFactory.java:316)
at org.terracotta.modules.ehcache.store.TerracottaClusteredInstanceFactory.getStoreMapForCacheManager(TerracottaClusteredInstanceFactory.java:77)
at org.terracotta.modules.ehcache.store.TerracottaClusteredInstanceFactory.getOrCreateStore(TerracottaClusteredInstanceFactory.java:68)
at org.terracotta.modules.ehcache.store.TerracottaClusteredInstanceFactory.createStore(TerracottaClusteredInstanceFactory.java:64)
at net.sf.ehcache.terracotta.StandaloneTerracottaClusteredInstanceFactory.createStore(StandaloneTerracottaClusteredInstanceFactory.java:40)
Thank you
As stated in one of the comments, Terracotta 3.4.0 is not Java 8 compatible and given the way the old Terracotta version worked, this is not a surprise.
You will have to update to a later version if you must have Java 8 support.
The exact version will depend on the usage you are making of Terracotta - if you need DSO support, you have to stick with the 3.7.x line.
For Ehcache support, it is recommended to upgraded to the latest version in the 4.3.x line.

Missing some spoon steps (plugins) at runtime (KarafLifecycleListener Error)

I am using open-source Pentaho distribution from github.com (version 6.1-SNAPSHOT).
In Spoon there are some step missing (e.g. There is no Mongodb input/output step listed) and I cant add dataservice to step (There are no errors, this option just isn't on the list).
I have reinstalled everything (removed .kettle and .pentaho directories as well as whole source and distribution) but it didn't help.
This is what I get at spoon startup:
16:05:50,304 INFO [KarafInstance]
* Karaf Instance Number: 1 at ~/pentaho-kettle/d
ist/./system/karaf//data1
Karaf Port:8801
OSGI Service Port:9050 *
Dec 23, 2015 4:05:51 PM org.apache.karaf.main.Main$KarafLockCallback
lockAquired
INFO: Lock acquired. Setting startlevel to 100
2015/12/23 16:05:53 - cfgbuilder - Warning: The configuration
parameter [org] is not supported by the default configuration builder
for scheme: sftp
Dec 23, 2015 4:05:58 PM
org.pentaho.caching.impl.PentahoCacheManagerFactory$RegistrationHandler$1
onSuccess INFO: New Caching Service registered
16:06:04,009 ERROR [KarafLifecycleListener] The Kettle Karaf Lifycycle
Listener failed to execute properly. Releasing lifecycle hold, but
some services may be unavailable.
I suspect that
ERROR [KarafLifecycleListener] The Kettle Karaf Lifycycle Listener
failed to execute properly. Releasing lifecycle hold, but some
services may be unavailable.
has something to do with it as missing plugins reside somewhere under karaf/ directory.
It was working just fine week ago.
I am using Ubuntu 15.04.
I will be grateful for any hints.
Greetings.
you are using a non stable release. this is the place where you can download the latest stable release http://sourceforge.net/projects/pentaho/
Agreed with jipipayo, For Pentaho CE version, download it from http://community.pentaho.com/ official instead of github. It is highly possible that the codes in github might be in unstable condition.
Also in case you have a missing plugin, try using the Pentaho Marketplace and download the required plugins.
Hope this helps :)

Apache Extras Cassandra-JDBC: Invalid method name: 'prepare_cql_query'

I'm using the Apache Extras project cassandra-jdbc ( http://code.google.com/a/apache-extras.org/p/cassandra-jdbc/ ) on version 1.1.1 along with the cassandra-thrift and cassandra-clientutil dependencies on version 1.1.1.
My Cassandra version is 1.0.10 though. I had to use the cassandra-jdbc on version 1.1.1 because the PreparedStatements were not available in earlier versions.
The problem I'm getting is:
org.apache.thrift.TApplicationException: Invalid method name: 'prepare_cql_query'
at org.apache.thrift.TApplicationException.read(TApplicationException.java:108)
at org.apache.thrift.TServiceClient.receiveBase(TServiceClient.java:71)
at org.apache.cassandra.thrift.Cassandra$Client.recv_prepare_cql_query(Cassandra.java:1438)
I read somewhere else ( https://wso2.org/jira/browse/CARBON-13577 ) this might be solved by upgrading Cassandra to 1.1.0, but I'm using DataStax so I'm not sure I can upgrade it. Is there another way to get past this?
That is for the simple reason that prepared statements are not supported until Cassandra 1.1: https://issues.apache.org/jira/browse/CASSANDRA-2475

Resources