• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

HotelsDotCom / waggle-dance / #318

pending completion
#318

push

web-flow
Feature/upgrade springboot (#268)

* update springboot to 2.1.18

* update springboot to 2.2.13

* Upgrade to srping boot 2.7.11

* Update changelog

* Update changelog

* fix version

3 of 3 new or added lines in 2 files covered. (100.0%)

132 of 3058 relevant lines covered (4.32%)

0.04 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/waggle-dance-core/src/main/java/com/hotels/bdp/waggledance/mapping/model/PrefixMapping.java
1
/**
2
 * Copyright (C) 2016-2020 Expedia, Inc.
3
 *
4
 * Licensed under the Apache License, Version 2.0 (the "License");
5
 * you may not use this file except in compliance with the License.
6
 * You may obtain a copy of the License at
7
 *
8
 * http://www.apache.org/licenses/LICENSE-2.0
9
 *
10
 * Unless required by applicable law or agreed to in writing, software
11
 * distributed under the License is distributed on an "AS IS" BASIS,
12
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
 * See the License for the specific language governing permissions and
14
 * limitations under the License.
15
 */
16
package com.hotels.bdp.waggledance.mapping.model;
17

18
import java.util.ArrayList;
19
import java.util.List;
20

21
public class PrefixMapping extends MetaStoreMappingDecorator {
22

23
  public PrefixMapping(MetaStoreMapping metaStoreMapping) {
24
    super(metaStoreMapping);
×
25
  }
×
26

27
  @Override
28
  public String transformOutboundDatabaseName(String databaseName) {
29
    return getDatabasePrefix() + super.transformOutboundDatabaseName(databaseName);
×
30
  }
31

32
  @Override
33
  public List<String> transformOutboundDatabaseNameMultiple(String databaseName) {
34
    List<String> outbound = super.transformOutboundDatabaseNameMultiple(databaseName);
×
35
    List<String> result = new ArrayList<>(outbound.size());
×
36
    for (String outboundDatabase : outbound) {
×
37
      result.add(getDatabasePrefix() + outboundDatabase);
×
38
    }
39
    return result;
×
40
  }
41

42
  @Override
43
  public String transformInboundDatabaseName(String databaseName) {
44
    String result = super.transformInboundDatabaseName(databaseName);
×
45
    if (result.startsWith(getDatabasePrefix())) {
×
46
      return result.substring(getDatabasePrefix().length());
×
47
    }
48
    return result;
×
49
  }
50

51
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc