Fixed s3 mode problems and added urlCompatMode